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

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

Issue 1033913003: Touch Events capability negotiation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: change setter to public and add license header Created 5 years, 6 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
« no previous file with comments | « remoting/webapp/base/js/client_session.js ('k') | remoting/webapp/crd/js/mock_client_plugin.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 /** @suppress {duplicate} */ 5 /** @suppress {duplicate} */
6 var remoting = remoting || {}; 6 var remoting = remoting || {};
7 7
8 (function() { 8 (function() {
9 9
10 'use strict'; 10 'use strict';
11 11
12 /** 12 /**
13 * @param {Element} container parent element for the plugin to be created. 13 * @param {Element} container parent element for the plugin to be created.
14 * @param {Array<string>} capabilities capabilities required by this 14 * @param {Array<string>} capabilities capabilities required by this
15 * application. 15 * application.
16 * @constructor 16 * @constructor
17 */ 17 */
18 remoting.ClientSessionFactory = function(container, capabilities) { 18 remoting.ClientSessionFactory = function(container, capabilities) {
19 /** @private */ 19 /** @private */
20 this.container_ = /** @type {HTMLElement} */ (container); 20 this.container_ = /** @type {HTMLElement} */ (container);
21 21
22 /** @private {Array<string>} */ 22 /** @private {Array<string>} */
23 this.requiredCapabilities_ = [ 23 this.requiredCapabilities_ = [
24 remoting.ClientSession.Capability.SEND_INITIAL_RESOLUTION, 24 remoting.ClientSession.Capability.SEND_INITIAL_RESOLUTION,
25 remoting.ClientSession.Capability.RATE_LIMIT_RESIZE_REQUESTS, 25 remoting.ClientSession.Capability.RATE_LIMIT_RESIZE_REQUESTS,
26 remoting.ClientSession.Capability.VIDEO_RECORDER 26 remoting.ClientSession.Capability.VIDEO_RECORDER,
27 remoting.ClientSession.Capability.TOUCH_EVENTS
27 ]; 28 ];
28 29
29 // Append the app-specific capabilities. 30 // Append the app-specific capabilities.
30 this.requiredCapabilities_.push.apply(this.requiredCapabilities_, 31 this.requiredCapabilities_.push.apply(this.requiredCapabilities_,
31 capabilities); 32 capabilities);
32 }; 33 };
33 34
34 /** 35 /**
35 * Creates a session. 36 * Creates a session.
36 * 37 *
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 new remoting.Error(remoting.Error.Tag.BAD_PLUGIN_VERSION)); 126 new remoting.Error(remoting.Error.Tag.BAD_PLUGIN_VERSION));
126 return; 127 return;
127 } 128 }
128 deferred.resolve(plugin); 129 deferred.resolve(plugin);
129 } 130 }
130 plugin.initialize(onInitialized); 131 plugin.initialize(onInitialized);
131 return deferred.promise(); 132 return deferred.promise();
132 } 133 }
133 134
134 })(); 135 })();
OLDNEW
« no previous file with comments | « remoting/webapp/base/js/client_session.js ('k') | remoting/webapp/crd/js/mock_client_plugin.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698