Packagepotomac.ui
Classpublic class TemplateEvent
InheritanceTemplateEvent Inheritance flash.events.Event

TemplateEvents are the communication mechanism between templates and Potomac. In response to a these events, a template is expected to modify the UI as appropriate.



Public Properties
 PropertyDefined By
  descriptor : PageDescriptor
[read-only] The page's descriptor.
TemplateEvent
  input : PageInput
[read-only] The page's input.
TemplateEvent
  options : PageOptions
[read-only] The page options.
TemplateEvent
  page : Page
[read-only] The page to show or close.
TemplateEvent
  parameters : Object
[read-only] The parameters associated with this template, as specified in the application's appManifest.xml.
TemplateEvent
  setFocus : Boolean
[read-only] True if the page should be made visible and focused.
TemplateEvent
Public Methods
 MethodDefined By
  
TemplateEvent(type:String, parameters:Object, pageDesc:PageDescriptor, pageInput:PageInput, pageOptions:PageOptions, page:Page, setFocus:Boolean)
Callers should not construct TemplateEvent instances.
TemplateEvent
  
clone():Event
[override]
TemplateEvent
Public Constants
 ConstantDefined By
  CLOSE_PAGE : String = templateClosePage
[static] The TemplateEvent.CLOSE_PAGE constant defines the value of the type property of the event object for a templateClosePage event.
TemplateEvent
  INITIALIZE : String = templateInitialize
[static] The TemplateEvent.INITIALIZE constant defines the value of the type property of the event object for a templateInitialize event.
TemplateEvent
  OPEN_PAGE : String = templateOpenPage
[static] The TemplateEvent.OPEN_PAGE constant defines the value of the type property of the event object for a templateOpenPage event.
TemplateEvent
  PAGE_DIRTY_CHANGE : String = templatePageDirtyChange
[static] The TemplateEvent.PAGE_DIRTY_CHANGE constant defines the value of the type property of the event object for a templatePageDirtyChange event.
TemplateEvent
  SHOW_PAGE : String = templateShowPage
[static] The TemplateEvent.SHOW_PAGE constant defines the value of the type property of the event object for a templateShowPage event.
TemplateEvent
Property Detail
descriptorproperty
descriptor:PageDescriptor  [read-only]

The page's descriptor.


Implementation
    public function get descriptor():PageDescriptor
inputproperty 
input:PageInput  [read-only]

The page's input.


Implementation
    public function get input():PageInput
optionsproperty 
options:PageOptions  [read-only]

The page options.


Implementation
    public function get options():PageOptions
pageproperty 
page:Page  [read-only]

The page to show or close.


Implementation
    public function get page():Page
parametersproperty 
parameters:Object  [read-only]

The parameters associated with this template, as specified in the application's appManifest.xml.


Implementation
    public function get parameters():Object
setFocusproperty 
setFocus:Boolean  [read-only]

True if the page should be made visible and focused.


Implementation
    public function get setFocus():Boolean
Constructor Detail
TemplateEvent()Constructor
public function TemplateEvent(type:String, parameters:Object, pageDesc:PageDescriptor, pageInput:PageInput, pageOptions:PageOptions, page:Page, setFocus:Boolean)

Callers should not construct TemplateEvent instances.

Parameters
type:String
 
parameters:Object
 
pageDesc:PageDescriptor
 
pageInput:PageInput
 
pageOptions:PageOptions
 
page:Page
 
setFocus:Boolean
Method Detail
clone()method
override public function clone():Event

Returns
Event
Constant Detail
CLOSE_PAGEConstant
public static const CLOSE_PAGE:String = templateClosePage

The TemplateEvent.CLOSE_PAGE constant defines the value of the type property of the event object for a templateClosePage event.

The properties of the event object have the following values:

PropertyValue
bubblesfalse
cancelablefalse
currentTargetThe Object that defines the event listener that handles the event. For example, if you use myButton.addEventListener() to register an event listener, myButton is the value of the currentTarget.
parametersnull
pageDescriptornull
pageInputnull
pageOptionsnull
pageThe page to close.
setFocusnull

INITIALIZEConstant 
public static const INITIALIZE:String = templateInitialize

The TemplateEvent.INITIALIZE constant defines the value of the type property of the event object for a templateInitialize event.

The properties of the event object have the following values:

PropertyValue
bubblesfalse
cancelablefalse
currentTargetThe Object that defines the event listener that handles the event. For example, if you use myButton.addEventListener() to register an event listener, myButton is the value of the currentTarget.
parametersA dynamic object containing the parameters specified in the appManifest.xml
pageDescriptornull
pageInputnull
pageOptionsnull
pagenull
setFocusnull

OPEN_PAGEConstant 
public static const OPEN_PAGE:String = templateOpenPage

The TemplateEvent.OPEN_PAGE constant defines the value of the type property of the event object for a templateOpenPage event.

The properties of the event object have the following values:

PropertyValue
bubblesfalse
cancelablefalse
currentTargetThe Object that defines the event listener that handles the event. For example, if you use myButton.addEventListener() to register an event listener, myButton is the value of the currentTarget.
parametersnull
pageDescriptorThe page descriptor.
pageInputthe page's input
pageOptionsthe page options
pagethe page
setFocustrue if the page should be made visible

PAGE_DIRTY_CHANGEConstant 
public static const PAGE_DIRTY_CHANGE:String = templatePageDirtyChange

The TemplateEvent.PAGE_DIRTY_CHANGE constant defines the value of the type property of the event object for a templatePageDirtyChange event.

The properties of the event object have the following values:

PropertyValue
bubblesfalse
cancelablefalse
currentTargetThe Object that defines the event listener that handles the event. For example, if you use myButton.addEventListener() to register an event listener, myButton is the value of the currentTarget.
parametersnull
pageDescriptornull
pageInputnull
pageOptionsnull
pageThe page whose dirty state changed.
setFocusnull

SHOW_PAGEConstant 
public static const SHOW_PAGE:String = templateShowPage

The TemplateEvent.SHOW_PAGE constant defines the value of the type property of the event object for a templateShowPage event.

The properties of the event object have the following values:

PropertyValue
bubblesfalse
cancelablefalse
currentTargetThe Object that defines the event listener that handles the event. For example, if you use myButton.addEventListener() to register an event listener, myButton is the value of the currentTarget.
parametersnull
pageDescriptornull
pageInputnull
pageOptionsnull
pageThe page to show.
setFocusnull