Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(686)

Unified Diff: remoting/webapp/crd/js/crd_connect.js

Issue 984793003: [Webapp Refactor] Remove It2Me connection code from SessionConnectorImpl. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: remoting/webapp/crd/js/crd_connect.js
diff --git a/remoting/webapp/crd/js/crd_connect.js b/remoting/webapp/crd/js/crd_connect.js
index ea4f7a83f1315de22ee7429707daadcac9149fc7..c21fd2cc6786981fb1436375d0a40b4d55f8b031 100644
--- a/remoting/webapp/crd/js/crd_connect.js
+++ b/remoting/webapp/crd/js/crd_connect.js
@@ -19,7 +19,12 @@ remoting.connectIT2Me = function() {
var connector = remoting.app.getSessionConnector();
var accessCode = document.getElementById('access-code-entry').value;
remoting.setMode(remoting.AppMode.CLIENT_CONNECTING);
- connector.connectIT2Me(accessCode);
+ remoting.It2MeConnectFlow.start(connector, accessCode).catch(
+ function(reason){
garykac 2015/03/06 22:27:27 formatting nit: What do you think about starting t
kelvinp 2015/03/06 23:33:51 Done.
+ var errorDiv = document.getElementById('connect-error-message');
+ l10n.localizeElementFromTag(errorDiv, /** @type {string} */ (reason));
+ remoting.setMode(remoting.AppMode.CLIENT_CONNECT_FAILED_IT2ME);
+ });
};
/**

Powered by Google App Engine
This is Rietveld 408576698