User Guide

98 Chapter 6: Components Dictionary
5.
Repeat steps 2-4 to create a screen named checkoutForm.
6.
Create a new screen named accordionForm.
7.
Drag an Accordion component from the Components panel to the accordionForm form, and
name it myAccordion.
8.
With myAccordion selected, in the Property inspector, do the following:
For the childSymbols property, enter addressForm, addressForm, and checkoutForm.
These strings specify the names of the screens used to create the accordions children.
Note: The first two children are instances of the same screen, because the shipping address
form and the billing address form are identical.
For the childNames property, enter shippingAddress, billingAddress, and checkout.
These strings are the ActionScript names of the accordions children.
For the childLabels property, enter Shipping Address, Billing Address, and Checkout.
These strings are the text labels on the accordion headers.
9.
Select Control > Test Movie.
To add an Accordion component to an application:
1.
Select File > New and create a new Flash document.
2.
Select Insert > New Symbol and name it AddressForm.
3.
In the Create New Symbol dialog box, click the Advanced button and select Export for
ActionScript. In the AS 2.0 Class field, enter mx.core.View.
To maintain tabbing order in an accordions children, the children must also be instances of the
View class.
4.
Drag components such as Label and TextInput from the Components panel onto the Stage to
create a mock address form; arrange them, and set their properties in the Parameters tab of the
Component inspector.
Position the form elements in relation to 0,0 (the middle) on the Stage. The 0,0 coordinate of
the movie clip is placed in the upper left corner of the accordion.
5.
Select Edit > Edit Document to return to the main Timeline.
6.
Repeat steps 2-5 to create a movie clip named CheckoutForm.
7.
Drag an Accordion component from the Components panel to add it to the Stage on the
main Timeline.
8.
In the Property inspector, do the following:
Enter the instance name myAccordion.
For the childSymbols property, enter AddressForm, AddressForm, and CheckoutForm.
These strings specify the names of the movie clips used to create the accordions children.
Note: The first two children are instances of the same movie clip, because the shipping address
form and the billing address form are identical.