get state before currentstate in flex -


There are flex in my five states and there is a random change between them.

How to obtain information about the previous state (active state before the current code in Flex)

Add a listener Save state and current state to a variable by changing the status of your object.

It may look like the following:

  & lt; Fx: Script & gt; & Lt ;! [CDATA [Private var previous state: string; Protected function when the creation is completed ($ event: FlexEvent): zero {yourObject.addEventListener (statConnect event.CURRENT_STATE_CHANGING, on ChinaiteState); } Chingstate ($ Event: State Change Event) on Protected Function: Zero {previousState = $ event.oldState; }    

Comments

Popular posts from this blog

Java - Error: no suitable method found for add(int, java.lang.String) -

java - JPA TypedQuery: Parameter value element did not match expected type -

c++ - static template member variable has internal linkage but is not defined -