Class Index | File Index

Classes


Namespace OWF.Launcher


Defined in: Widget.js.

Namespace Summary
Constructor Attributes Constructor Name and Description
 
This object is used launch other widgets.
Method Summary
Method Attributes Method Name and Description
<static>  
OWF.Launcher.getLaunchData()
Retrieves initial launch data for this widget if it is opened by another widget.
<static>  
OWF.Launcher.launch(config, callback)
Launches a Widget based on the config.
Namespace Detail
OWF.Launcher
This object is used launch other widgets.
Method Detail
<static> {Object} OWF.Launcher.getLaunchData()
Retrieves initial launch data for this widget if it is opened by another widget.
var launchData = OWF.Launcher.getLaunchData();
if (launchData != null) {
	var data = Ozone.util.parseJson(launchData);  //in this example the data object has two fields: channel and message
	if (data != null) {
		//do something with the data
		OWF.Eventing.subscribe(data.channel, function() {});
	}
}
Returns:
{Object} data object which contains initial launch data for the widget

<static> OWF.Launcher.launch(config, callback)
Launches a Widget based on the config.
OWF.Launcher.launch({
	guid: 'guid_of_widget_to_launch',
	launchOnlyIfClosed: true,	//if true will only launch the widget if it is not already opened.
								//if it is opened then the widget will be brought to focus
	data: dataString			//initial launch data to be passed to a widget only if the widget is opened. This must be a string.
}, callback);
Parameters:
{Object} config
object see example for structure
{Function} callback
a function to be called once after the launchWidget is executed

Documentation generated by JsDoc Toolkit 2.3.2 on Fri Oct 05 2012 16:51:04 GMT-0400 (EDT)