CHAPTER 54
UIObject class
Inheritance
MovieClip > UIObject
ActionScript Class Name
UIObject is the base class for all version 2 of the Macromedia Component Architecture
components; it is not a visual component. The UIObject class wraps the ActionScript
MovieClip object and contains functions and properties that allow version 2 components to
share some common behavior. Wrapping the MovieClip class allows Macromedia to add new
events and extend functionality in the future without breaking content. Wrapping the
MovieClip class also allows users who aren't familiar with the traditional Flash concepts of
"movie" and "frame" to use properties, methods, and events to create component-based
applications without learning those concepts.
The UIObject class implements the following:
Styles
Events
Resize by scaling
To use the methods and properties of the UIObject class, you call them directly from
whichever component you are using. For example, to call the
from the RadioButton component, you would write the following code:
myRadioButton.setSize(30, 30);
You only need to create an instance of UIObject if you are using version 2 of the Macromedia
Component Architecture to create a new component. Even in that case, UIObject is often
created implicitly by other subclasses like Button. If you do need to create an instance of
UIObject, use the following code:
class MyComponent extends UIObject;
mx.core.UIObject
method
UIObject.setSize()
54
1359
Need help?
Do you have a question about the FLASH 8-COMPONENTS LANGUAGE and is the answer not in the manual?