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

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

Issue 1082383002: [Webapp Refactor] Remove remoting.clientSession. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 8 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 /** 5 /**
6 * @fileoverview 6 * @fileoverview
7 * Class that wraps low-level details of interacting with the client plugin. 7 * Class that wraps low-level details of interacting with the client plugin.
8 * 8 *
9 * This abstracts a <embed> element and controls the plugin which does 9 * This abstracts a <embed> element and controls the plugin which does
10 * the actual remoting work. It also handles differences between 10 * the actual remoting work. It also handles differences between
(...skipping 293 matching lines...) Expand 10 before | Expand all | Expand 10 after
304 base.getNumberAttr(message.data, 'renderLatency'); 304 base.getNumberAttr(message.data, 'renderLatency');
305 base.getNumberAttr(message.data, 'roundtripLatency'); 305 base.getNumberAttr(message.data, 'roundtripLatency');
306 this.perfStats_ = 306 this.perfStats_ =
307 /** @type {remoting.ClientSession.PerfStats} */ (message.data); 307 /** @type {remoting.ClientSession.PerfStats} */ (message.data);
308 308
309 } else if (message.method == 'injectClipboardItem') { 309 } else if (message.method == 'injectClipboardItem') {
310 var mimetype = base.getStringAttr(message.data, 'mimeType'); 310 var mimetype = base.getStringAttr(message.data, 'mimeType');
311 var item = base.getStringAttr(message.data, 'item'); 311 var item = base.getStringAttr(message.data, 'item');
312 this.updateClipboardData_(mimetype, item); 312 this.updateClipboardData_(mimetype, item);
313 313
314 } else if (message.method == 'onFirstFrameReceived') {
kelvinp 2015/04/14 23:16:32 Removed as not used.
Jamie 2015/04/14 23:52:47 This will be used soon to log the amount of time b
kelvinp 2015/04/15 00:30:21 Good catch. Resurrected!
315 if (remoting.clientSession) {
316 remoting.clientSession.onFirstFrameReceived();
317 }
318
319 } else if (message.method == 'fetchPin') { 314 } else if (message.method == 'fetchPin') {
320 // The pairingSupported value in the dictionary indicates whether both 315 // The pairingSupported value in the dictionary indicates whether both
321 // client and host support pairing. If the client doesn't support pairing, 316 // client and host support pairing. If the client doesn't support pairing,
322 // then the value won't be there at all, so give it a default of false. 317 // then the value won't be there at all, so give it a default of false.
323 var pairingSupported = base.getBooleanAttr(message.data, 'pairingSupported', 318 var pairingSupported = base.getBooleanAttr(message.data, 'pairingSupported',
324 false); 319 false);
325 this.credentials_.getPIN(pairingSupported).then( 320 this.credentials_.getPIN(pairingSupported).then(
326 this.onPinFetched_.bind(this) 321 this.onPinFetched_.bind(this)
327 ); 322 );
328 323
(...skipping 542 matching lines...) Expand 10 before | Expand all | Expand 10 after
871 remoting.DefaultClientPluginFactory.prototype.preloadPlugin = function() { 866 remoting.DefaultClientPluginFactory.prototype.preloadPlugin = function() {
872 if (remoting.settings.CLIENT_PLUGIN_TYPE != 'pnacl') { 867 if (remoting.settings.CLIENT_PLUGIN_TYPE != 'pnacl') {
873 return; 868 return;
874 } 869 }
875 870
876 var plugin = remoting.ClientPluginImpl.createPluginElement_(); 871 var plugin = remoting.ClientPluginImpl.createPluginElement_();
877 plugin.addEventListener( 872 plugin.addEventListener(
878 'loadend', function() { document.body.removeChild(plugin); }, false); 873 'loadend', function() { document.body.removeChild(plugin); }, false);
879 document.body.appendChild(plugin); 874 document.body.appendChild(plugin);
880 }; 875 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698