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

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

Issue 983023002: [Chromoting] Use compact notation for javascript @private types (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 9 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 * Full-screen implementation for apps v1, using webkitRequestFullscreen. 7 * Full-screen implementation for apps v1, using webkitRequestFullscreen.
8 */ 8 */
9 9
10 'use strict'; 10 'use strict';
11 11
12 /** @suppress {duplicate} */ 12 /** @suppress {duplicate} */
13 var remoting = remoting || {}; 13 var remoting = remoting || {};
14 14
15 /** 15 /**
16 * @constructor 16 * @constructor
17 * @implements {remoting.Fullscreen} 17 * @implements {remoting.Fullscreen}
18 */ 18 */
19 remoting.FullscreenAppsV1 = function() { 19 remoting.FullscreenAppsV1 = function() {
20 /** 20 /** @private {string} Internal 'full-screen changed' event name */
21 * @type {string} Internal 'full-screen changed' event name
22 * @private
23 */
24 this.kEventName_ = '_fullscreenchanged'; 21 this.kEventName_ = '_fullscreenchanged';
25 22
26 /** 23 /** @private {base.EventSourceImpl} */
27 * @type {base.EventSourceImpl}
28 * @private
29 */
30 this.eventSource_ = new base.EventSourceImpl(); 24 this.eventSource_ = new base.EventSourceImpl();
31 this.eventSource_.defineEvents([this.kEventName_]); 25 this.eventSource_.defineEvents([this.kEventName_]);
32 26
33 document.addEventListener( 27 document.addEventListener(
34 'webkitfullscreenchange', 28 'webkitfullscreenchange',
35 this.onFullscreenChanged_.bind(this), 29 this.onFullscreenChanged_.bind(this),
36 false); 30 false);
37 }; 31 };
38 32
39 remoting.FullscreenAppsV1.prototype.activate = function( 33 remoting.FullscreenAppsV1.prototype.activate = function(
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
99 this.eventSource_.raiseEvent(this.kEventName_, this.isActive()); 93 this.eventSource_.raiseEvent(this.kEventName_, this.isActive());
100 }; 94 };
101 95
102 // Querying full-screen immediately after the webkitfullscreenchange 96 // Querying full-screen immediately after the webkitfullscreenchange
103 // event fires sometimes gives the wrong answer on Mac, perhaps due to 97 // event fires sometimes gives the wrong answer on Mac, perhaps due to
104 // the time taken to animate presentation mode. Since I haven't been able 98 // the time taken to animate presentation mode. Since I haven't been able
105 // to isolate the exact repro steps, and we're not planning on using this 99 // to isolate the exact repro steps, and we're not planning on using this
106 // API for much longer, this hack will suffice for now. 100 // API for much longer, this hack will suffice for now.
107 window.setTimeout(checkIsActive.bind(this), 500); 101 window.setTimeout(checkIsActive.bind(this), 500);
108 }; 102 };
OLDNEW
« no previous file with comments | « remoting/webapp/crd/js/fallback_signal_strategy.js ('k') | remoting/webapp/crd/js/fullscreen_v2.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698