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

Side by Side Diff: remoting/webapp/remoting.js

Issue 552403004: Interfaceify ClientPlugin in preparation for mocking it. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Interfaceify more classes. Created 6 years, 3 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 'use strict'; 5 'use strict';
6 6
7 /** @suppress {duplicate} */ 7 /** @suppress {duplicate} */
8 var remoting = remoting || {}; 8 var remoting = remoting || {};
9 9
10 /** @type {remoting.HostSession} */ remoting.hostSession = null; 10 /** @type {remoting.HostSession} */ remoting.hostSession = null;
(...skipping 23 matching lines...) Expand all
34 authContinue(); 34 authContinue();
35 }; 35 };
36 dialog.hidden = false; 36 dialog.hidden = false;
37 button.addEventListener('click', consentGranted, false); 37 button.addEventListener('click', consentGranted, false);
38 } 38 }
39 39
40 /** 40 /**
41 * Entry point for app initialization. 41 * Entry point for app initialization.
42 */ 42 */
43 remoting.init = function() { 43 remoting.init = function() {
44
Sergey Ulanov 2014/09/16 02:02:51 remove this empty line?
Jamie 2014/09/16 16:23:21 Done.
44 if (base.isAppsV2()) { 45 if (base.isAppsV2()) {
45 var htmlNode = /** @type {HTMLElement} */ (document.body.parentNode); 46 var htmlNode = /** @type {HTMLElement} */ (document.body.parentNode);
46 htmlNode.classList.add('apps-v2'); 47 htmlNode.classList.add('apps-v2');
47 } else { 48 } else {
48 migrateLocalToChromeStorage_(); 49 migrateLocalToChromeStorage_();
49 } 50 }
50 51
51 console.log(remoting.getExtensionInfo()); 52 console.log(remoting.getExtensionInfo());
52 l10n.localize(); 53 l10n.localize();
53 54
(...skipping 530 matching lines...) Expand 10 before | Expand all | Expand 10 after
584 } 585 }
585 586
586 /** 587 /**
587 * Tests whether we are running on ChromeOS. 588 * Tests whether we are running on ChromeOS.
588 * 589 *
589 * @return {boolean} True if the platform is ChromeOS. 590 * @return {boolean} True if the platform is ChromeOS.
590 */ 591 */
591 remoting.platformIsChromeOS = function() { 592 remoting.platformIsChromeOS = function() {
592 return navigator.userAgent.match(/\bCrOS\b/) != null; 593 return navigator.userAgent.match(/\bCrOS\b/) != null;
593 } 594 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698