Packagesekati.display
Classpublic final class StageDisplay
InheritanceStageDisplay Inheritance flash.events.EventDispatcher

StageDisplay provides an interface to the swf application Stage instance allowing display and non-displayObjects to interact with and control the stage.

Note: Fullscreen requires Flash Player >= 9.0.28, however, 9.0.115 is recommended for deferred rendering via Canvas.stage.invalidate().

See also

sekati.events.StageEvent
sekati.display.Canvas
http://livedocs.adobe.com/flash/9.0/ActionScriptLangRefV3/flash/display/Stage.html


Public Properties
 PropertyDefined by
  $ : StageDisplay
[static][read-only] Shorthand singleton accessor getter
StageDisplay
  align : String
Stage alignment
StageDisplay
  center : Point
[read-only] Stage center point.
StageDisplay
  centerX : Number
[read-only] Stage horizontal center.
StageDisplay
  centerY : Number
[read-only] Stage vertical center.
StageDisplay
  contentHeight : Number
[read-only] The height, in pixels, of the Stage contents.
StageDisplay
  contentWidth : Number
[read-only] The width, in pixels, of the Stage contents.
StageDisplay
  focusRect : Boolean
Specifies whether or not objects display a glowing border when they have focus.
StageDisplay
  frameRate : int
The frame rate of the stage.
StageDisplay
  fullscreen : Boolean
Indicates the players fullscreen status.
StageDisplay
  idle : Boolean
[read-only] Boolean status of stage idle.
StageDisplay
  idleTime : uint
Amount of mouse idle time (in milliseconds) before the StageEvent.IDLE event fires [Default: 10000].
StageDisplay
  leaveCompleteTime : uint
Amount of post stage leave time (in milliseconds) before the StageEvent.LEAVE_COMPLETE event fires [Default: 500].
StageDisplay
  proportion : Number
[read-only] Stage proportion.
StageDisplay
  quality : String
Movie quality setting.
StageDisplay
  resizeCompleteTime : uint
Amount of post stage resize time (in milliseconds) before the StageEvent.RESIZE_COMPLETE event fires [Default: 500].
StageDisplay
  scaleMode : String
A value from the StageScaleMode class that specifies which scale mode to use.
StageDisplay
  showDefaultContextMenu : Boolean
Returns value of property
StageDisplay
  size : Rectangle
[read-only] The current size of the stage.
StageDisplay
Public Methods
 MethodDefined by
  
StageDisplay($:SingletonEnforcer = null)
StageDisplay Singleton Constructor
StageDisplay
  
destroy():void
Cleanup the StageDisplay singleton instance.
StageDisplay
  
[static] Singleton Accessor
StageDisplay
  
hasFocus(o:DisplayObject):Boolean
Test if a DisplayObject has focus within the stage.
StageDisplay
  
init(framerate:int = 31, align:String = "TL", scale:String = "noScale", quality:String = "HIGH", focusRect:Boolean = false):void
Parameterized Stage initialization.
StageDisplay
  
invalidate():void
Alert DisplayObject's on the next opportunity to render the display list.
StageDisplay
  
Toggles the player between NORMAL and FULL_SCREEN.
StageDisplay
Protected Methods
 MethodDefined by
  
activateHandler(e:Event):void
Dispatches StageEvent>ACTIVATE when application regains focus.
StageDisplay
  
deactivateHandler(e:Event):void
Dispatches StageEvent.DEACTIVATE when application loses focus.
StageDisplay
  
fullscreenHandler(e:Event):void
Dispatches StageEvent.FULLSCREEN when the application toggles fullscreen mode.
StageDisplay
  
idleHandler():void
Dispatches StageEvent.MOUSE_IDLE after MOUSE_IDLE_MS expires.
StageDisplay
  
Dispatches StageEvent.LEAVE_COMPLETE when LEAVE_COMPLETE_MS expires.
StageDisplay
  
leaveHandler(e:Event):void
Dispatches StageEvent.LEAVE when mouse leaves the application stage.
StageDisplay
  
moveHandler(e:MouseEvent = null):void
Dispatches StageEvent.MOUSE_RESUME if the mouse activity resumes from idleness.
StageDisplay
  
Dispatches StageEvent.RESIZE_COMPLETE when RESIZE_COMPLETE_MS expires.
StageDisplay
  
resizeHandler(e:Event):void
Dispatches StageEvent.RESIZE when the application stage is resized.
StageDisplay
Property detail
$property
$:StageDisplay  [read-only]

Shorthand singleton accessor getter

Implementation
    public static function get $():StageDisplay
alignproperty 
align:String  [read-write]

Stage alignment

Implementation
    public function get align():String
    public function set align(value:String):void

See also

flash.display.StageAlign
centerproperty 
center:Point  [read-only]

Stage center point.

Implementation
    public function get center():Point
centerXproperty 
centerX:Number  [read-only]

Stage horizontal center.

Implementation
    public function get centerX():Number
centerYproperty 
centerY:Number  [read-only]

Stage vertical center.

Implementation
    public function get centerY():Number
contentHeightproperty 
contentHeight:Number  [read-only]

The height, in pixels, of the Stage contents.

Equivalent to: Canvas.stage.height

Implementation
    public function get contentHeight():Number
contentWidthproperty 
contentWidth:Number  [read-only]

The width, in pixels, of the Stage contents.

Equivalent to: Canvas.stage.width

Implementation
    public function get contentWidth():Number
focusRectproperty 
focusRect:Boolean  [read-write]

Specifies whether or not objects display a glowing border when they have focus.

Implementation
    public function get focusRect():Boolean
    public function set focusRect(value:Boolean):void
frameRateproperty 
frameRate:int  [read-write]

The frame rate of the stage.

Implementation
    public function get frameRate():int
    public function set frameRate(value:int):void
fullscreenproperty 
fullscreen:Boolean  [read-write]

Indicates the players fullscreen status.

Implementation
    public function get fullscreen():Boolean
    public function set fullscreen(value:Boolean):void
idleproperty 
idle:Boolean  [read-only]

Boolean status of stage idle.

Implementation
    public function get idle():Boolean
idleTimeproperty 
idleTime:uint  [read-write]

Amount of mouse idle time (in milliseconds) before the StageEvent.IDLE event fires [Default: 10000].

Implementation
    public function get idleTime():uint
    public function set idleTime(value:uint):void
leaveCompleteTimeproperty 
leaveCompleteTime:uint  [read-write]

Amount of post stage leave time (in milliseconds) before the StageEvent.LEAVE_COMPLETE event fires [Default: 500].

Implementation
    public function get leaveCompleteTime():uint
    public function set leaveCompleteTime(value:uint):void
proportionproperty 
proportion:Number  [read-only]

Stage proportion.

Implementation
    public function get proportion():Number
qualityproperty 
quality:String  [read-write]

Movie quality setting.

Implementation
    public function get quality():String
    public function set quality(value:String):void

See also

flash.display.StageQuality
resizeCompleteTimeproperty 
resizeCompleteTime:uint  [read-write]

Amount of post stage resize time (in milliseconds) before the StageEvent.RESIZE_COMPLETE event fires [Default: 500].

Implementation
    public function get resizeCompleteTime():uint
    public function set resizeCompleteTime(value:uint):void
scaleModeproperty 
scaleMode:String  [read-write]

A value from the StageScaleMode class that specifies which scale mode to use.

Implementation
    public function get scaleMode():String
    public function set scaleMode(value:String):void

See also

flash.display.StageScaleMode
showDefaultContextMenuproperty 
showDefaultContextMenu:Boolean  [read-write]

Returns value of property

Implementation
    public function get showDefaultContextMenu():Boolean
    public function set showDefaultContextMenu(value:Boolean):void
sizeproperty 
size:Rectangle  [read-only]

The current size of the stage.

Implementation
    public function get size():Rectangle
Constructor detail
StageDisplay()constructor
public function StageDisplay($:SingletonEnforcer = null)

StageDisplay Singleton Constructor

Parameters
$:SingletonEnforcer (default = null) — SingletonEnforcer internal to the AS file; this param prevents external instantiation without error.
Method detail
activateHandler()method
protected function activateHandler(e:Event):void

Dispatches StageEvent>ACTIVATE when application regains focus.

Parameters
e:Event
deactivateHandler()method 
protected function deactivateHandler(e:Event):void

Dispatches StageEvent.DEACTIVATE when application loses focus.

Parameters
e:Event
destroy()method 
public function destroy():void

Cleanup the StageDisplay singleton instance.

fullscreenHandler()method 
protected function fullscreenHandler(e:Event):void

Dispatches StageEvent.FULLSCREEN when the application toggles fullscreen mode.

Parameters
e:Event
getInstance()method 
public static function getInstance():StageDisplay

Singleton Accessor

Returns
StageDisplay — StageDisplay
hasFocus()method 
public function hasFocus(o:DisplayObject):Boolean

Test if a DisplayObject has focus within the stage.

Parameters
o:DisplayObject

Returns
Boolean

Example
   var textFocus : Boolean = StageDisplay.$.hasFocus( myTextField );
   

idleHandler()method 
protected function idleHandler():void

Dispatches StageEvent.MOUSE_IDLE after MOUSE_IDLE_MS expires.

init()method 
public function init(framerate:int = 31, align:String = "TL", scale:String = "noScale", quality:String = "HIGH", focusRect:Boolean = false):void

Parameterized Stage initialization.

Parameters
framerate:int (default = 31) — movie framerate
 
align:String (default = "TL") — stage alignment
 
scale:String (default = "noScale") — stage scaleMode.
 
quality:String (default = "HIGH") — movie quality
 
focusRect:Boolean (default = false) — add object border focus
invalidate()method 
public function invalidate():void

Alert DisplayObject's on the next opportunity to render the display list.

leaveCompleteHandler()method 
protected function leaveCompleteHandler():void

Dispatches StageEvent.LEAVE_COMPLETE when LEAVE_COMPLETE_MS expires.

leaveHandler()method 
protected function leaveHandler(e:Event):void

Dispatches StageEvent.LEAVE when mouse leaves the application stage.

Parameters
e:Event
moveHandler()method 
protected function moveHandler(e:MouseEvent = null):void

Dispatches StageEvent.MOUSE_RESUME if the mouse activity resumes from idleness.

Parameters
e:MouseEvent (default = null)
resizeCompleteHandler()method 
protected function resizeCompleteHandler():void

Dispatches StageEvent.RESIZE_COMPLETE when RESIZE_COMPLETE_MS expires.

resizeHandler()method 
protected function resizeHandler(e:Event):void

Dispatches StageEvent.RESIZE when the application stage is resized.

Parameters
e:Event
toggleFullscreen()method 
public function toggleFullscreen():void

Toggles the player between NORMAL and FULL_SCREEN.