Main application class responsible for startup, shutdown and stage resize events. It holds global application constants.
|muSprite||Main application class responsible for startup, shutdown and stage resize events. |
|muSprite||Create an instance of the application.|
|loadScript||Load a script from an external source.|
|dispose||Dispose of all resources held by the application.|
|public function muSprite()|
Create an instance of the application.
If the application is started from a preloader then it waits for the loader to finish so the preloader can choose a theme color otherwise a random color is chosen. A delayed function call is used to ensure that the stage is initialized before resizing the application to fully utilize the available stage area. If the application is not started in any of these ways then it is loaded by the AIR frontend and started directly.
Control is then handed over to the Controller object and this class only handles stage resize events in the rest of the applications lifetime.
|public function loadScript(||script:|| String||):void|
Load a script from an external source.
|public function dispose():void|
Dispose of all resources held by the application.