Packagesekati.display
Classpublic class DocumentPreloader
InheritanceDocumentPreloader Inheritance flash.display.Sprite
SubclassesSekatiPreloader

The DocumentPreloader class is an API independent shell designed to load Sekati API Document driven SWF applications. In other words; the DocumentPreloader should be extended and used as the Main Document Class for any preloader SWF use to load an API driven SWF.

Main methods which may be overridden and customized:

Secondary methods which may be overriden and customized:

Note: that the API Application SWF Bootstrap sequence will begin once the loaded API swf is added to the stage via initApplication().

See also

sekati.display.Document


Public Properties
 PropertyDefined by
  APPLICATION_URI : String
[static] The API Application SWF URI to be loaded (ascertained from the config.xml).
DocumentPreloader
  bytesLoaded : Number
[read-only] The number of loaded bytes of the Application SWF.
DocumentPreloader
  bytesTotal : Number
[read-only] The number of total bytes of the Application SWF.
DocumentPreloader
  CONF_URI : String
[static] The config.xml location used by the DocumentPreloader and Document passed via FlashVars or defaulting to xml/config.xml.
DocumentPreloader
  percent : Number
[read-only] The percentage (0 - 1 scale) of the Application SWF currently loaded.
DocumentPreloader
Protected Properties
 PropertyDefined by
  introComplete : Boolean
Property set by initUIIntro() when the intro sequence completes.
DocumentPreloader
  outroComplete : Boolean
Property set by initUIOutro() when the outro sequence completes.
DocumentPreloader
Public Methods
 MethodDefined by
  
DocumentPreloader Constructor
DocumentPreloader
Protected Methods
 MethodDefined by
  
applicationHandler(e:Event):void
The API Appliction SWF has been loaded; wait for notification from initUIOutro to set outroComplete.
DocumentPreloader
  
configHandler(e:Event):void
The config.xml has loaded; wait for notification from initUIIntro to set introComplete.
DocumentPreloader
  
Initialize the loaded API Application SWF.
DocumentPreloader
  
Load the API Application SWF.
DocumentPreloader
  
initDocumentPreloader(e:Event = null):void
Initializes the preloader and movie properties when the stage becomes available.
DocumentPreloader
  
Initializes SWF movie properties.
DocumentPreloader
  
initPreloader(e:Event = null):void
Initialize the Document Preloader UI & load the config.xml (invoked when the preloader SWF itself is done loading).
DocumentPreloader
  
initUIIntro():void
Initialize the preloader UI intro and set introComplete = true; when UI has completed build up.
DocumentPreloader
  
initUIOutro():void
Initialize the preloader UI outro and set outroComplete = true; when UI has completed tear down.
DocumentPreloader
  
progress(e:ProgressEvent):void
API Application SWF progress handler.
DocumentPreloader
  
resize(e:Event = null):void
Stub function to invoke upon a stage resize.
DocumentPreloader
Property detail
APPLICATION_URIproperty
public static var APPLICATION_URI:String

The API Application SWF URI to be loaded (ascertained from the config.xml).

bytesLoadedproperty 
bytesLoaded:Number  [read-only]

The number of loaded bytes of the Application SWF.

Implementation
    public function get bytesLoaded():Number
bytesTotalproperty 
bytesTotal:Number  [read-only]

The number of total bytes of the Application SWF.

Implementation
    public function get bytesTotal():Number
CONF_URIproperty 
public static var CONF_URI:String

The config.xml location used by the DocumentPreloader and Document passed via FlashVars or defaulting to xml/config.xml.

introCompleteproperty 
protected var introComplete:Boolean

Property set by initUIIntro() when the intro sequence completes.

outroCompleteproperty 
protected var outroComplete:Boolean

Property set by initUIOutro() when the outro sequence completes.

percentproperty 
percent:Number  [read-only]

The percentage (0 - 1 scale) of the Application SWF currently loaded.

Implementation
    public function get percent():Number
Constructor detail
DocumentPreloader()constructor
public function DocumentPreloader()

DocumentPreloader Constructor

Method detail
applicationHandler()method
protected function applicationHandler(e:Event):void

The API Appliction SWF has been loaded; wait for notification from initUIOutro to set outroComplete.

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

The config.xml has loaded; wait for notification from initUIIntro to set introComplete.

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

Initialize the loaded API Application SWF.

Customization: Override this method to delay API SWF initialization, and execute any visual preloader 'outro' sequence before application initializes. If this method is not overridden, the API SWF will initialize as soon as its load completes.

initApplicationLoader()method 
protected function initApplicationLoader():void

Load the API Application SWF.

initDocumentPreloader()method 
protected function initDocumentPreloader(e:Event = null):void

Initializes the preloader and movie properties when the stage becomes available.

Parameters
e:Event (default = null)
initMovieProperties()method 
protected function initMovieProperties():void

Initializes SWF movie properties.

Customization: Override this method & adjust to fit your application specification.

initPreloader()method 
protected function initPreloader(e:Event = null):void

Initialize the Document Preloader UI & load the config.xml (invoked when the preloader SWF itself is done loading).

Parameters
e:Event (default = null)
initUIIntro()method 
protected function initUIIntro():void

Initialize the preloader UI intro and set introComplete = true; when UI has completed build up.

Customization: Override this method to execute any custom intro code for a the visual preloader.

initUIOutro()method 
protected function initUIOutro():void

Initialize the preloader UI outro and set outroComplete = true; when UI has completed tear down.

Customization: Override this method to execute any custom outro code for a visual preloader.

progress()method 
protected function progress(e:ProgressEvent):void

API Application SWF progress handler.

Customization: Override this method to execute any custom code to visualize progress in your preloader.

Parameters
e:ProgressEvent
resize()method 
protected function resize(e:Event = null):void

Stub function to invoke upon a stage resize.

Customization: Override this method to execute any custom resize logic as the API has yet to initialize.

Parameters
e:Event (default = null)