Yay, Flash Player Beta 10 2 – My Favorite Feature “unloadAndStop”


Two days ago, Adobe released Beta 2 of Flash Player 10. With it came a number of enhancements, bug fixes and new features. Linux users got a much more even playing field. But the one that I think will have the most impact on my day to day Flash work with Flash Player 10:

unloadAndStop — This new ActionScript 3.0 API adds unload functionality similar to the unload behavior in ActionScript 2.0.  After calling unloadAndStop on loaded content it will be immediately removed stopping all audio, removing eventListeners, and becoming inaccessible through ActionScript.

This sounds to me like a fix for this massive bug/issue noted in this great post by Grant Skinner. That bug prevents clean unloading and garbage collection of unloaded/unused movieclips or sprites. Very excellent news for everyone who builds, buys or consumes Flash content. I am also excited to have limited fullscreen keyboard access, but fixing this major issue will definitely help me not need to put kludgey workarounds in or avoid AS3 based Flash content any longer.

Kudos, Adobe!

Posted on


4 comments

  1. schpinn Sep 9

    ..anyone knows how to use this ? ..i get ‘possibly undefined method’ when publishing the swf.. i presume you need to update flash cs3 somehow..

  2. Chad Sep 9

    You’ll need the latest build of Flex SDK from the labs for that!

  3. schpinn Sep 9

    @chad: thanks, downloaded it.. although i’m still lost, you can’t publish .fla files with flex, as much as i can understand.. it wouldn’t be a problem to create a .as class file and put all the code from the .fla file there, but what about the stuff on the stage and in the library ?

  4. Chad Sep 9

    schpinn, nope, sorry, you’ll need to use Flex Builder and compile using that. Right now you can’t compile Flash Player 10 SWF files from Flash. Who knows, maybe come Sept 23rd things will change with the CS4 event.

Leave a reply