Locator and manager for Application look and Feel.
Broadcasts onChangeEVENT event type when theme change.
Example using AsWing Look'n Feel.
var at : ThemeLocator = ThemeLocator.getInstance(); at.register( "Office 2003", new Office2003LAF() ); at.register( "WinXP 2003", new WinXPLAF() ); at.addEventListener( ThemeLocator.onChangeEVENT, this, _onUIUpdate ); at.load( "WinXP 2003" );
Look and Feel is really apply using custom process.
Associates Command to
fever.events.FeverEventList.onApplyLookAndFeelEVENT event type.
A concrete command example is available in FvApplyLookAndFeel
static public onChangeEVENT:EventTypestatic public CONFIG_ID:String [Read Only]static public function getInstance():ThemeLocatorReturns unique FvThemeLocator instance.
public function register(lafName:String, lafInstance:Object, previewLink:String):Boolean
Registers a new available {code lafInstance} LookAndFeel instance with passed-in
lafName id.
registred Look'n Feel
| IllegalArgumentException | if lafName or lafInstance are
undefined or null
|
public function isRegistred(lafName:String):Boolean
Returns true if a theme is registred with passed-in lafName
ID.
public function unregister(lafName:String):Boolean
Unregisters passed-in lafName Look And Feel from theme map.
public function load(lafName:String):Boolean
Applies passed-in lafName Look'n Feel.
LAF must be registred before with register() method.
If a theme configuration is saved, loads saved theme.
Look and Feel is really apply using custom process.
Associated Command to
fever.events.FeverEventList.onApplyLookAndFeelEVENT event type
A concrete command example is available in FvApplyLookAndFeel
true if LAF is correctly applied.
public function getTheme(lafName:String):Theme
Returns Look'n Feel regitred with passed lafName id.
public function getCurrentTheme():ThemeReturns current application theme.
If laf is registred in map, returns Theme instance.
public function addEventListener(type:EventType, listener):Void
Adds passed-in listener for receiving passed-in type event type.