mirror of
https://github.com/shaka-project/shaka-player.git
synced 2026-06-23 17:27:16 +03:00
51c3717305
This updates the fullscreen externs to: - Add a newer definition for requestFullscreen which includes options for the method - Remove prefixed methods which are now built into the compiler and are no longer necessary - Drop document.webkitSupportsFullscreen method, which does not seem to exist as defined, even on iOS (confusion with similar property on video element: https://apple.co/39TLC5I) This enables PR #2325 to resolve issue #2324 Change-Id: Ie7bea7e7d4fd59d6d801431e2ba996649e185dc1
37 lines
1.0 KiB
JavaScript
37 lines
1.0 KiB
JavaScript
/** @license
|
|
* Copyright 2016 Google LLC
|
|
* SPDX-License-Identifier: Apache-2.0
|
|
*/
|
|
|
|
/**
|
|
* @fileoverview Externs for fullscreen methods ahead of new compiler release.
|
|
* @externs
|
|
*
|
|
* The old compiler we're using already has an incompatible definition for
|
|
* requestFullscreen on Element. Since we can't replace it on Element, we add
|
|
* ours on HTMLElement, one subclass down. This is still low-level enough to
|
|
* apply to all reasonable usage of the fullscreen API.
|
|
*
|
|
* The latest compiler version has the updated definition on Element.
|
|
*
|
|
* TODO: Remove once the compiler is upgraded.
|
|
*/
|
|
|
|
/**
|
|
* @record
|
|
* @see https://fullscreen.spec.whatwg.org/#dictdef-fullscreenoptions
|
|
*/
|
|
function FullscreenOptions() {}
|
|
|
|
/** @type {string} */
|
|
FullscreenOptions.prototype.navigationUI;
|
|
|
|
/**
|
|
* @see https://fullscreen.spec.whatwg.org/#dom-element-requestfullscreen
|
|
* @param {!FullscreenOptions=} options
|
|
* @return {!Promise}
|
|
* @override
|
|
* @suppress {checkTypes}
|
|
*/
|
|
HTMLElement.prototype.requestFullscreen = function(options) {};
|