I need some help on how to use the define a tab loop and making it work correctly in Flash AS3 CS4 FP9. Greatly appreciate any hinting or clue on how to solve this mind bogging issue. Thanks!!
If you do not wish to read the details, my short question is: How do I use FocusManager? I did the following code, which does not work as intended. What is missing?
// TheForm is a MovieClip on the swf. // TheForm has fl.controls.TextInput // and other UI componenets as child // all UI components have tabIndex defined using // windows > other panels > accessibility // everything is on first frame var fm:FocusManager = new FocusManager(TheForm); fm.activate();
I have several fl.controls.TextInput and other UI components (ComboBox and Button) in an form.swf that is supposed to make up a contact form.
I have set the tabIndex using the windows>other panels>accessibility panel (and also tried using AS3) for each of the fl.controls.
In operation, form.swf is not the stage, and the heirarchy is as follows: index.swf > main.swf > form.swf
- index.swf: contains background and a flash.display.Loader to load main.swf. Purpose is to calculate screen size and coords for gradient and centering.
- main.swf: contains consistent UI such as main navigation, header, footer and logo. also contains flash.display.Loader to load the "pages", one of which is form.swf
- form.swf: contains the form UI components
Since main.swf and the form.swf both contains tabEnabled items such as navigation buttons on main.swf and form UI on form.swf, I have set the tabIndex in a way that no two items have same tabIndex even across different swf.
1. when the tab is press, it does not cycle through the controls. It goes from the form controls, to other navigation buttons in the swf and then back to the form controls. i.e. a stage-wide tab loop
2. the first time i go into the page, the tab cycles in the correct order among the form UI components. But if i go to another "page" and come back to the form, the tab no longer cycle correctly among the form UI components. It seems totally random.
NOTE: a "page" is loaded by clicking a button in the main.swf which also contains a flash.display.Loader that will load the swf "page".