You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@flex.apache.org by chris_d_k <ck...@christiankiefer.de> on 2015/10/20 17:49:21 UTC

Event when all effect ended

Hi,

when I want to do something after an effect has ended for all targets..

fadeOutEffect.addEventListener(EffectEvent.EFFECT_END,
handleFadeOutEffectEnded);
fadeOutEffect.targets = [aLotOfTargets];
fadeOutEffect.play();

will it be reliable to check this in the handleFadeOutEffectEnded by
checking

fadeOutEffect.isPlaying == false

or do I have to count the targets and the number of times the
handleFadeOutEffectEnded was called?



--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/Event-when-all-effect-ended-tp11354.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

Re: Event when all effect ended

Posted by Alex Harui <ah...@adobe.com>.

On 10/20/15, 8:49 AM, "chris_d_k" <ck...@christiankiefer.de> wrote:

>Hi,
>
>when I want to do something after an effect has ended for all targets..
>
>fadeOutEffect.addEventListener(EffectEvent.EFFECT_END,
>handleFadeOutEffectEnded);
>fadeOutEffect.targets = [aLotOfTargets];
>fadeOutEffect.play();
>
>will it be reliable to check this in the handleFadeOutEffectEnded by
>checking
>
>fadeOutEffect.isPlaying == false

I don’t know the effects system that well, but the code looks like that
would work.


-Alex


Re: Event when all effect ended

Posted by chris_d_k <ck...@christiankiefer.de>.
It is working... just was wondering what is the *correct *way as I found
nothing about this in the web (handling effects of all targets ended...)



--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/Event-when-all-effect-ended-tp11354p11357.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

Re: Event when all effect ended

Posted by jude <fl...@gmail.com>.
The number of targets shouldn't matter except possibly in list based
effects.

Can you post the MXML? Is it not working?

On Tuesday, October 20, 2015, chris_d_k <ck...@christiankiefer.de> wrote:

> Hi,
>
> when I want to do something after an effect has ended for all targets..
>
> fadeOutEffect.addEventListener(EffectEvent.EFFECT_END,
> handleFadeOutEffectEnded);
> fadeOutEffect.targets = [aLotOfTargets];
> fadeOutEffect.play();
>
> will it be reliable to check this in the handleFadeOutEffectEnded by
> checking
>
> fadeOutEffect.isPlaying == false
>
> or do I have to count the targets and the number of times the
> handleFadeOutEffectEnded was called?
>
>
>
> --
> View this message in context:
> http://apache-flex-users.2333346.n4.nabble.com/Event-when-all-effect-ended-tp11354.html
> Sent from the Apache Flex Users mailing list archive at Nabble.com.
>