Selecting A Parent Class - MACROMEDIA FLASH MX 2004-USING COMPONENTS Use Manual

Using components
Hide thumbs Also See for FLASH MX 2004-USING COMPONENTS:
Table of Contents

Advertisement

To export the Dial component:
In the Dial.fla file, choose the Dial component in the library and select Export to SWC from
1.
the Library options menu.
Choose a location to save the SWC file.
2.
If you save it to the Components folder in the user-level configuration folder, you can reload
the Components panel without restarting Flash and the component appears in the panel.
Note: For information about folder locations, see "Configuration folders installed with Flash" in
Using Flash.
The completed Dial component

Selecting a parent class

The first thing to decide when creating a component is whether to extend one of the version 2
classes. If you choose to extend a version 2 class, you can either extend a component class (for
example, Button, CheckBox, ComboBox, List, and so on) or one of the base classes, UIObject or
UIComponent. All the component classes, except the Media components, extend the base classes;
if you extend a component class, you automatically inherit from the base classes as well.
The two base classes supply common features for components. By extending these classes, your
component begins with a basic set of methods, properties, and events.
You don't have to subclass UIObject or UIComponent or any other classes in the version 2
framework. Even if your component classes inherit directly from the MovieClip class, you can use
many powerful component features: export to a SWC file or compiled clip, use built-in live
preview, view inspectable properties, and so on. However, if you want your components to work
with the Macromedia version 2 components, and use the manager classes, you need to extend
UIObject or UIComponent.
924
Chapter 7: Creating Components

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the FLASH MX 2004-USING COMPONENTS and is the answer not in the manual?

Questions and answers

This manual is also suitable for:

Flash mx

Table of Contents