[Chromoting] Move app-specific code out of remoting.js
commita59c430f5028228e62f780b2e129e93a4cb72843
authorgarykac <garykac@chromium.org>
Fri, 20 Mar 2015 02:31:39 +0000 (19 19:31 -0700)
committerCommit bot <commit-bot@chromium.org>
Fri, 20 Mar 2015 02:32:19 +0000 (20 02:32 +0000)
tree9235d8487ef18b9f2dc319b13ff6698702737666
parentf1df20df06365f2c8e41872c567e4801a8cf9392
[Chromoting] Move app-specific code out of remoting.js

After this cl, the last remaining reference to remoting.AppMode in AppRemoting is in app_remoting.js. That will be addressed in a followup cl.

Move the following out of remoting.js and into app-specific locations:
* remoting.signOut (into crd_event_handlers.js)
* remoting.showErrorMessage (into desktop_remoting.js)
* isWindowed_ (into desktop_remoting.js)
* remoting.promptClose (into desktop_remoting.js)
* remoting.isMe2MeInstallable (into local_host_section.js)

Rename Delegate.signInFailed -> Delegate.handleAuthError
Add Application.onAuthError to call Delegate.handleAuthError

Change references to global remoting.showErrorMessage to remoting.app.onAuthError

BUG=

Review URL: https://codereview.chromium.org/1020743002

Cr-Commit-Position: refs/heads/master@{#321502}
remoting/webapp/crd/js/crd_event_handlers.js
remoting/webapp/crd/js/crd_main.js
remoting/webapp/crd/js/desktop_remoting.js
remoting/webapp/crd/js/host_list.js
remoting/webapp/crd/js/host_setup_dialog.js
remoting/webapp/crd/js/local_host_section.js
remoting/webapp/crd/js/remoting.js