Login Register

onEnd

Help with animation loop: onEnd function works, animation doesn't

Let me start off by saying that I am a Dojo noob (and rusty on my JS), so this is probably an easy fix that I am overlooking, but I have been searching the forums for the past two day, to no avail.

I am trying to get an array of nodes, take the first node in the array, fade it out, remove the node, and repeat with the next node until all nodes in the array are gone.

At first I tried using this:

while(arr.length > 0){
       myAnim.play()
    }

Chain Animation onEnd Event Firing

Hi All,

I have noticed the following behaviour when using the dojo.fx.chain animation and connecting to its onEnd event.

What I would like to do is have a couple of animations run one after the other, then when all have finished, call another function, below is my contrived example;

var anim1 = dojo.fx.wipeOut({node:'ele'});
var anim2 = dojo.fx.wipeIn({node:'ele'});
var c = dojo.fx.chain([anim1,anim2]);

dojo.connect(c,"onEnd",someFunc);

c.play();
Syndicate content