Skip navigation
Currently Being Moderated

How do I call a state change from within a view

Mar 21, 2010 5:49 PM

Hey guys,

I think I might understand how to do this, but I wanted to run it by the forums to see if I understand it correctly..


So I have a base view (base.mxml) which contains 3 separate 'state' view components - like thus...


        <s:State name="MinimisedState" />
        <s:State name="MaximisedState" />
        <s:State name="LoginState" />
<view:MinimisedView includeIn="MinimisedState" width="100%" height="100%" />

<view:MaximisedView includeIn="MaximisedState" width="100%" height="100%" />
<view:LoginPane includeIn="LoginState" width="100%" height="100%" />


Apologies if this sounds like a gumby question, but how do I get the LoginPane state/view (to dispatch an event) to tell the base view (container) to change states? Say to MinimisedState or MaxmisedState.


I'm sure this is something really simple, and I don't have a problem doing this when all the states are registered/contained within the same base MXML file - but when it comes to passing events up to the parent (from seperate external mxml views/components) i'm a little confused.


Any help appreciated


More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points