O'Reilly logo

The ActionScript™ 3.0 Migration Guide: Making the Move from ActionScript 2.0 by Kris Hadlock

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 8. Buttons and MovieClips

Button AND MovieClip OBJECTS HAVE been completely overhauled in ActionScript 3. Both objects are now part of the display list, inheriting properties, methods, and events from all display classes in the inheritance chain. Buttons and MovieClips are both InteractiveObjects, but it’s important to keep in mind that only the MovieClip class is a DisplayObjectContainer. In AS3 a MovieClip is essentially a Sprite with a timeline, and the Button class has been renamed and replaced with the SimpleButton class.

In this chapter, you will learn the differences between AS2 and AS3 in how to handle mouse events, drag a movie clip, and work with depth in the new display-list architecture.

Mouse Events

Button and MovieClip symbol ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required