dispatchEvent

Roger Braunstein + Mims Wright = this blog



Aral Balkan, champion of open-source flash, just annouced a Flash / Flex extension to the Google App Engine called GAE SWF. He also announced that KitchenSync will be a part of it. I’m very excited to see what happens with both projects.

GAE SWF


A reader sent me this question. Thanks in advance to Michael:

i’m dispatching an event from a sprite after it fades in completely
dispatchEvent(new Event(Main.ENTER_SCREEN_COMPLETE));

i’m trying to listen for to this event but for some reason it doesn’t get picked up when the capturing parameter is set to false.. that is for bubbling and the target phase.

This works
container.addEventListener(Main.ENTER_SCREEN_COMPLETE, screenTweenComplete, true, 0, true);

This does NOT work
container.addEventListener(Main.ENTER_SCREEN_COMPLETE, screenTweenComplete, false, 0, true);

Where container, is an ancestor to everything on the screen. Essentially its the the stage.

Any clues why this is happening?

Answer after the jump.
Continue reading Reader Question: Why isn’t event bubbling working…



Woo! KitchenSync v1.1 is out! It now supports timecode, default values, new easing functions and juping to a specific time in a tween. Go check it out!

Changes in 1.1:

  • ADDED jumpToTime() method to Tween (this may be moved to AbstractSynchronizedAction in a later release)
  • ADDED getTimestampFromFrames() and getTimestampFromMilliseconds() to TimestampUtil
  • ADDED Timecode to TimeStringParser. Now “:ss”, “mm:ss;ff”, and “dd:hh:mm:ss;ff” are supported.
  • ADDED ActionDefaults class for storing default initialization values.
  • ADDED easeOutIn() to most of the easing functions (buggy. seems to overshoot target in some cases)
  • ADDED version check in Synchronizer.initialize()
  • CHANGED type of Numbers within Timestamp to int.
  • REFACTORED all actions to contain super() in the constructor.
  • REMOVED errors that are thrown when pause() and start() are called at the wrong times.
Next Page »