Packagefeathers.extensions.tabbedApplication
Classpublic class ViewNavigator
InheritanceViewNavigator Inheritance feathers.extensions.tabbedApplication.StackScreenNavigator
Subclasses ViewNavigatorApplication

A "view stack"-like container that supports navigation between views (any display object) through events, based on StackScreenNavigator.

See also

How to use TabbedViewNavigatorApplication with mxml
How to use ViewNavigatorApplication with mxml
feathers.extensions.tabbedApplication.View
feathers.extensions.tabbedApplication.PanelView
feathers.controls.StackScreenNavigator


Public Properties
 PropertyDefined By
  keyCode : String
Keyboard key code to pop view [ViewNavigatorApplication-only].
ViewNavigator
  latencyToStartSwipe : uint
The latency in pixels to start swipe [ViewNavigatorApplication-only].
ViewNavigator
  length : uint
[read-only] Number of views in the navigation stack.
ViewNavigator
  owner : Object
The tabbed navigators that is currently displaying this navigator [TabbedViewNavigatorApplication-only].
ViewNavigator
  persistNavigatorState : Boolean
In-memory persistence saves navigators, views and data as the user navigates the application [ViewNavigatorApplication-only].
ViewNavigator
  position : uint
[read-only] Position in the navigation stack.
ViewNavigator
  speedBackReleaseSwipe : uint
Speed back in pixels when you release swipe [ViewNavigatorApplication-only].
ViewNavigator
  speedSwipe : Number
Swipe speed to change View [ViewNavigatorApplication-only].
ViewNavigator
  swipeView : Boolean
Swipe to change View [ViewNavigatorApplication-only].
ViewNavigator
  vnID : String
The navigator id that is currently displaying by the tabbed navigators [TabbedViewNavigatorApplication-only].
ViewNavigator
Public Methods
 MethodDefined By
  
ViewNavigator(screen:Object = null, data:Object = null, transition:Function = null, owner:Object = null, vnID:String = null, _history:Vector.<String> = null, _historyData:Vector.<Object> = null, position:uint = 0)
Constructor.
ViewNavigator
  
clear():void
Clear the persistence views and data [ViewNavigatorApplication-only].
ViewNavigator
  
exit(errorCode:int = 0):void
Exit to the application and clear the persistence navigators, views and data [ViewNavigatorApplication-only].
ViewNavigator
  
Update data in a view.
ViewNavigator
  
popView(transition:Function = null):DisplayObject
Pops the current view off the navigation stack.
ViewNavigator
  
pushView(screen:Object, data:Object = null, transition:Function = null):void
Pushes a new view to the top of the navigation stack.
ViewNavigator
  
save():void
Save views and data [ViewNavigatorApplication-only].
ViewNavigator
Protected Methods
 MethodDefined By
  
Override this method to perform other tasks before the application is displayed.
ViewNavigator
Property Detail
keyCodeproperty
keyCode:String

Keyboard key code to pop view [ViewNavigatorApplication-only].

Possible values are "back", "left" or key code (uint).

The default value is null.


Implementation
    public function get keyCode():String
    public function set keyCode(value:String):void
latencyToStartSwipeproperty 
latencyToStartSwipe:uint

The latency in pixels to start swipe [ViewNavigatorApplication-only].

The default value is 10.


Implementation
    public function get latencyToStartSwipe():uint
    public function set latencyToStartSwipe(value:uint):void
lengthproperty 
length:uint  [read-only]

Number of views in the navigation stack.


Implementation
    public function get length():uint
ownerproperty 
public var owner:Object

The tabbed navigators that is currently displaying this navigator [TabbedViewNavigatorApplication-only].

persistNavigatorStateproperty 
persistNavigatorState:Boolean

In-memory persistence saves navigators, views and data as the user navigates the application [ViewNavigatorApplication-only].

The default value is false.


Implementation
    public function get persistNavigatorState():Boolean
    public function set persistNavigatorState(value:Boolean):void
positionproperty 
position:uint  [read-only]

Position in the navigation stack.


Implementation
    public function get position():uint
speedBackReleaseSwipeproperty 
speedBackReleaseSwipe:uint

Speed back in pixels when you release swipe [ViewNavigatorApplication-only].

The default value is 10.


Implementation
    public function get speedBackReleaseSwipe():uint
    public function set speedBackReleaseSwipe(value:uint):void
speedSwipeproperty 
speedSwipe:Number

Swipe speed to change View [ViewNavigatorApplication-only].

The default value is 3.


Implementation
    public function get speedSwipe():Number
    public function set speedSwipe(value:Number):void
swipeViewproperty 
swipeView:Boolean

Swipe to change View [ViewNavigatorApplication-only].

The default value is false.


Implementation
    public function get swipeView():Boolean
    public function set swipeView(value:Boolean):void
vnIDproperty 
public var vnID:String

The navigator id that is currently displaying by the tabbed navigators [TabbedViewNavigatorApplication-only].

Constructor Detail
ViewNavigator()Constructor
public function ViewNavigator(screen:Object = null, data:Object = null, transition:Function = null, owner:Object = null, vnID:String = null, _history:Vector.<String> = null, _historyData:Vector.<Object> = null, position:uint = 0)

Constructor.

Parameters
screen:Object (default = null)
 
data:Object (default = null)
 
transition:Function (default = null)
 
owner:Object (default = null)
 
vnID:String (default = null)
 
_history:Vector.<String> (default = null)
 
_historyData:Vector.<Object> (default = null)
 
position:uint (default = 0)
Method Detail
clear()method
public function clear():void

Clear the persistence views and data [ViewNavigatorApplication-only].

exit()method 
public function exit(errorCode:int = 0):void

Exit to the application and clear the persistence navigators, views and data [ViewNavigatorApplication-only].

Parameters

errorCode:int (default = 0)

historyDataUpdate()method 
public function historyDataUpdate():void

Update data in a view.

popView()method 
public function popView(transition:Function = null):DisplayObject

Pops the current view off the navigation stack.

Parameters

transition:Function (default = null)

Returns
DisplayObject
preinitialize()method 
protected function preinitialize():void

Override this method to perform other tasks before the application is displayed.

override protected function preinitialize():void
{
    //perform other tasks here
    setTimeout(otherTasks, 5000);
}

private function otherTasks():void
{
    left = 100;
    super.preinitialize();
}

pushView()method 
public function pushView(screen:Object, data:Object = null, transition:Function = null):void

Pushes a new view to the top of the navigation stack.

Parameters

screen:Object — view class.
 
data:Object (default = null) — Properties saved in a view.
 
transition:Function (default = null)

save()method 
public function save():void

Save views and data [ViewNavigatorApplication-only].