User Guide
RadioButton component 625
To create movie clip symbols for RadioButton skins:
1.
Create a new FLA file.
2.
Select File > Import > Open External Library, and select the HaloTheme.fla file.
This file is located in the application-level configuration folder. For the exact location on your
operating system, see “About themes” on page 77.
3.
In the theme’s Library panel, expand the Flash UI Components 2/Themes/MMDefault folder
and drag the RadioButton Assets folder to the library for your document.
4.
Expand the RadioButton Assets/States folder in the library of your document.
5.
Open the symbols you want to customize for editing.
For example, open the RadioFalseDisabled symbol.
6.
Customize the symbol as desired.
For example, change the inner white circle to a light gray.
7.
Repeat steps 5-6 for all symbols you want to customize.
For example, repeat the color change for the inner circle of the RadioTrueDisabled symbol.
8.
Click the Back button to return to the main Timeline.
9.
Drag a RadioButton component to the Stage.
For this example, drag two instances to show the two new skin symbols.
10.
Set the RadioButton instance properties as desired.
For this example, set one RadioButton to selected, and use ActionScript to set both
RadioButton instances to disabled.
11.
Select Control > Test Movie.
RadioButton class
Inheritance MovieClip > UIObject class > UIComponent class > SimpleButton class > Button
component > RadioButton
ActionScript Package Name mx.controls.RadioButton
The properties of the RadioButton class allow you at runtime to create a text label and position it
in relation to the radio button. You can also assign data values to radio buttons, assign them to
groups, and select them based on data value or instance name.
Setting a property of the RadioButton class with ActionScript overrides the parameter of the same
name set in the Property inspector or Component inspector.
The RadioButton component uses the Focus Manager to override the default Flash Player focus
rectangle and draw a custom focus rectangle with rounded corners. For information about
creating focus navigation, see “Creating custom focus navigation” on page 50.
Each component class has a
version property, which is a class property. Class properties are
available only on the class itself. The
version property returns a string that indicates the version
of the component. To access this property, use the following code:
trace(mx.controls.RadioButton.version);