[flexcoders] Re: Which event is dispatched when the view is shown by a stage change?

2008-06-27 Thread Tim Hoff
Hi João, This is kind of a hack, but you could try: mx:State name=editing onEnter=localeEditor.myTextBox.setFocus() If you used this, you would want to execute the setFocus code on creationComplete of the editor; for the first time that the editor is shown. Instead of useing states for

[flexcoders] Re: Which event is dispatched when the view is shown by a stage change?

2008-06-27 Thread Tim Hoff
Yep, my bad. As Jonathan points out, this should be enterState instead of onEnter (grr). mx:State name=editing enterState=localeEditor.myTextBox.setFocus() -TH --- In flexcoders@yahoogroups.com, Tim Hoff [EMAIL PROTECTED] wrote: Hi João, This is kind of a hack, but you could try:

[flexcoders] Re: Which event is dispatched when the view is shown by a stage change?

2008-06-27 Thread João
Hi Jonathan, thanks for your great post! About the two solutions, I don't like both, but having to choose I would go with the first one. In the way I see it, the component should never know where he's in. The component should only know now I'm visible... now I'm not, and react to that. Both