diff options
author | jamiewalch@google.com <jamiewalch@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-03-12 20:42:01 +0000 |
---|---|---|
committer | jamiewalch@google.com <jamiewalch@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-03-12 20:42:01 +0000 |
commit | ffc65676b8366e07bbb0bd4df0d2a2d8995069f3 (patch) | |
tree | 2d3e90d53b633a01a2b3c671efd8c0916bf55fb4 /remoting/webapp/remoting.js | |
parent | 3cd198a2911ac90e70e50b4c5e34ee3982ea9769 (diff) | |
download | chromium_src-ffc65676b8366e07bbb0bd4df0d2a2d8995069f3.zip chromium_src-ffc65676b8366e07bbb0bd4df0d2a2d8995069f3.tar.gz chromium_src-ffc65676b8366e07bbb0bd4df0d2a2d8995069f3.tar.bz2 |
Hide daemon UI initially.
BUG=117555
TEST=Manual
Review URL: https://chromiumcodereview.appspot.com/9664013
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@126208 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'remoting/webapp/remoting.js')
-rw-r--r-- | remoting/webapp/remoting.js | 21 |
1 files changed, 14 insertions, 7 deletions
diff --git a/remoting/webapp/remoting.js b/remoting/webapp/remoting.js index a8ca35e..15b0968 100644 --- a/remoting/webapp/remoting.js +++ b/remoting/webapp/remoting.js @@ -53,6 +53,14 @@ remoting.init = function() { window.addEventListener('blur', pluginLostFocus_, false); + if (isHostModeSupported_()) { + var noShare = document.getElementById('chrome-os-no-share'); + noShare.parentNode.removeChild(noShare); + } else { + var button = document.getElementById('share-button'); + button.disabled = true; + } + // Parse URL parameters. var urlParams = getUrlParameters_(); if ('mode' in urlParams) { @@ -64,17 +72,16 @@ remoting.init = function() { } // No valid URL parameters, start up normally. + remoting.initDaemonUi(); +}; + +// initDaemonUi is called if the app is not starting up in session mode, and +// also if the user cancels the connection in session mode. +remoting.initDaemonUi = function () { remoting.daemonPlugin = new remoting.DaemonPlugin(); remoting.daemonPlugin.updateDom(); remoting.setMode(getAppStartupMode_()); remoting.askPinDialog = new remoting.AskPinDialog(remoting.daemonPlugin); - if (isHostModeSupported_()) { - var noShare = document.getElementById('chrome-os-no-share'); - noShare.parentNode.removeChild(noShare); - } else { - var button = document.getElementById('share-button'); - button.disabled = true; - } }; /** |