diff options
author | jamiewalch@google.com <jamiewalch@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-11-15 21:13:51 +0000 |
---|---|---|
committer | jamiewalch@google.com <jamiewalch@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-11-15 21:13:51 +0000 |
commit | 0a329924468db98a7f97577bcc6996c25b5f0673 (patch) | |
tree | 0dd44af58466926839e5aac0427604f7733d561d /remoting/webapp | |
parent | 5980ca4f6fae1ba2da65c997a66b5447ade367b6 (diff) | |
download | chromium_src-0a329924468db98a7f97577bcc6996c25b5f0673.zip chromium_src-0a329924468db98a7f97577bcc6996c25b5f0673.tar.gz chromium_src-0a329924468db98a7f97577bcc6996c25b5f0673.tar.bz2 |
Remove remoting.cancelConnect, since it doesn't update the URL correctly.
BUG=141699
Review URL: https://codereview.chromium.org/11275115
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@168033 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'remoting/webapp')
-rw-r--r-- | remoting/webapp/client_screen.js | 7 | ||||
-rw-r--r-- | remoting/webapp/event_handlers.js | 10 |
2 files changed, 12 insertions, 5 deletions
diff --git a/remoting/webapp/client_screen.js b/remoting/webapp/client_screen.js index f534e72..3ffb0f8 100644 --- a/remoting/webapp/client_screen.js +++ b/remoting/webapp/client_screen.js @@ -77,8 +77,12 @@ remoting.connectIt2Me = function() { /** * Cancel an incomplete connect operation. * + * Note that this function is not currently used. It is here for reference + * because we'll need to reinstate something very like it when we transition + * to Apps v2 where we can no longer change the URL (which is what we do in + * lieu of calling this function to ensure correct Reload behaviour). + * * @return {void} Nothing. - */ remoting.cancelConnect = function() { if (remoting.supportHostsXhr_) { remoting.supportHostsXhr_.abort(); @@ -95,6 +99,7 @@ remoting.cancelConnect = function() { document.getElementById('access-code-entry').value = ''; } }; +*/ /** * Toggle the scale-to-fit feature for the current client session. diff --git a/remoting/webapp/event_handlers.js b/remoting/webapp/event_handlers.js index f29728e..324fb79 100644 --- a/remoting/webapp/event_handlers.js +++ b/remoting/webapp/event_handlers.js @@ -50,6 +50,10 @@ function onLoad() { remoting.hostSetupDialog.showForStop(); event.stopPropagation(); }; + var cancelAccessCode = function() { + remoting.setMode(remoting.AppMode.HOME); + document.getElementById('access-code-entry').value = ''; + }; /** @type {Array.<{event: string, id: string, fn: function(Event):void}>} */ var actions = [ { event: 'click', id: 'sign-out', fn: remoting.signOut }, @@ -69,10 +73,8 @@ function onLoad() { { event: 'click', id: 'client-finished-me2me-button', fn: restartWebapp }, { event: 'click', id: 'cancel-pin-entry-button', fn: restartWebapp }, { event: 'click', id: 'client-reconnect-button', fn: reload }, - { event: 'click', id: 'cancel-access-code-button', - fn: remoting.cancelConnect }, - { event: 'click', id: 'cancel-connect-button', - fn: remoting.cancelConnect }, + { event: 'click', id: 'cancel-access-code-button', fn: cancelAccessCode}, + { event: 'click', id: 'cancel-connect-button', fn: restartWebapp }, { event: 'click', id: 'toolbar-stub', fn: function() { remoting.toolbar.toggle(); } }, { event: 'click', id: 'start-daemon', |