summaryrefslogtreecommitdiffstats
path: root/remoting/webapp/base/js/application.js
diff options
context:
space:
mode:
Diffstat (limited to 'remoting/webapp/base/js/application.js')
-rw-r--r--remoting/webapp/base/js/application.js14
1 files changed, 12 insertions, 2 deletions
diff --git a/remoting/webapp/base/js/application.js b/remoting/webapp/base/js/application.js
index 82bef0f..29ffa88 100644
--- a/remoting/webapp/base/js/application.js
+++ b/remoting/webapp/base/js/application.js
@@ -44,7 +44,16 @@ remoting.Application.prototype.setDelegate = function(appDelegate) {
* @return {void} Nothing.
*/
remoting.Application.prototype.start = function() {
- this.delegate_.init();
+ // Create global objects.
+ remoting.ClientPlugin.factory = new remoting.DefaultClientPluginFactory();
+ remoting.SessionConnector.factory =
+ new remoting.DefaultSessionConnectorFactory();
+
+ // TODO(garykac): This should be owned properly rather than living in the
+ // global 'remoting' namespace.
+ remoting.settings = new remoting.Settings();
+
+ this.delegate_.init(this.getSessionConnector());
};
/**
@@ -155,9 +164,10 @@ remoting.Application.Delegate = function() {};
* Initialize the application and register all event handlers. After this
* is called, the app is running and waiting for user events.
*
+ * @param {remoting.SessionConnector} connector
* @return {void} Nothing.
*/
-remoting.Application.Delegate.prototype.init = function() {};
+remoting.Application.Delegate.prototype.init = function(connector) {};
/**
* @return {string} The default remap keys for the current platform.