Package | feathers.motion.transitions |
Class | public class ScreenSlidingStackTransitionManager |
Inheritance | ScreenSlidingStackTransitionManager ![]() |
ScreenNavigator
that slides out the old
screen and slides in the new screen at the same time. The slide starts
from the right or left, depending on if the manager determines that the
transition is a push or a pop.
Whether a screen change is supposed to be a push or a pop is
determined automatically. The manager generates an identifier from the
fully-qualified class name of the screen, and if present, the
screenID
defined by IScreen
instances. If the
generated identifier is present on the stack, a screen change is
considered a pop. If the token is not present, it's a push. Screen IDs
should be tailored to this behavior to avoid false positives.
If your navigation structure requires explicit pushing and popping, a custom transition manager is probably better.
See also
Property | Defined By | ||
---|---|---|---|
delay : Number
A delay before the transition starts, measured in seconds. | ScreenSlidingStackTransitionManager | ||
duration : Number
The duration of the transition, measured in seconds. | ScreenSlidingStackTransitionManager | ||
ease : Object
The easing function to use. | ScreenSlidingStackTransitionManager | ||
skipNextTransition : Boolean = false
Determines if the next transition should be skipped. | ScreenSlidingStackTransitionManager |
Property | Defined By | ||
---|---|---|---|
navigator : ScreenNavigator
The ScreenNavigator being managed. | ScreenSlidingStackTransitionManager |
Method | Defined By | ||
---|---|---|---|
ScreenSlidingStackTransitionManager(navigator:ScreenNavigator, quickStackScreenClass:Class = null, quickStackScreenID:String = null)
Constructor. | ScreenSlidingStackTransitionManager | ||
clearStack():void
Removes all saved classes from the stack that are used to determine
which side of the ScreenNavigator the new screen will
slide in from. | ScreenSlidingStackTransitionManager |
Method | Defined By | ||
---|---|---|---|
onTransition(oldScreen:DisplayObject, newScreen:DisplayObject, onComplete:Function):void
The function passed to the transition property of the
ScreenNavigator. | ScreenSlidingStackTransitionManager |
delay | property |
delay:Number
A delay before the transition starts, measured in seconds. This may be required on low-end systems that will slow down for a short time after heavy texture uploads.
The default value is 0.1
.
public function get delay():Number
public function set delay(value:Number):void
duration | property |
duration:Number
The duration of the transition, measured in seconds.
The default value is 0.25
.
public function get duration():Number
public function set duration(value:Number):void
ease | property |
ease:Object
The easing function to use.
The default value is starling.animation.Transitions.EASE_OUT
.
public function get ease():Object
public function set ease(value:Object):void
navigator | property |
protected var navigator:ScreenNavigator
The ScreenNavigator
being managed.
skipNextTransition | property |
public var skipNextTransition:Boolean = false
Determines if the next transition should be skipped. After the
transition, this value returns to false
.
The default value is false
.
ScreenSlidingStackTransitionManager | () | Constructor |
public function ScreenSlidingStackTransitionManager(navigator:ScreenNavigator, quickStackScreenClass:Class = null, quickStackScreenID:String = null)
Constructor.
Parametersnavigator:ScreenNavigator | |
quickStackScreenClass:Class (default = null )
| |
quickStackScreenID:String (default = null )
|
clearStack | () | method |
public function clearStack():void
Removes all saved classes from the stack that are used to determine
which side of the ScreenNavigator
the new screen will
slide in from.
onTransition | () | method |
protected function onTransition(oldScreen:DisplayObject, newScreen:DisplayObject, onComplete:Function):void
The function passed to the transition
property of the
ScreenNavigator
.
Parameters
oldScreen:DisplayObject | |
newScreen:DisplayObject | |
onComplete:Function |