mirror of
https://github.com/shaka-project/shaka-player.git
synced 2026-06-26 17:46:26 +03:00
970d7756ea
The goal is to simplify and abstract feature logic detection. Currently lots of places depend on various calls to `shaka.util.Platform` and mainteinance of this is hard & not easy to read. By introducing device API ideally rest of the player logic would look into device features instead of directly checking platform. Additionally we can more easily cache needed values, so we won't have to parse user agent several times anymore. --------- Co-authored-by: Álvaro Velad Galván <ladvan91@hotmail.com>
71 lines
1017 B
JavaScript
71 lines
1017 B
JavaScript
/*! @license
|
|
* Shaka Player
|
|
* Copyright 2016 Google LLC
|
|
* SPDX-License-Identifier: Apache-2.0
|
|
*/
|
|
|
|
/**
|
|
* @fileoverview Externs for Xbox
|
|
*
|
|
* @externs
|
|
*/
|
|
|
|
|
|
/** @const */
|
|
var Windows = {};
|
|
|
|
|
|
/** @const */
|
|
Windows.Media = {};
|
|
|
|
|
|
/** @const */
|
|
Windows.Media.Protection = {};
|
|
|
|
|
|
/** @const */
|
|
Windows.Media.Protection.ProtectionCapabilities = class {
|
|
/**
|
|
* @param {string} type
|
|
* @param {string} keySystem
|
|
* @return {!Windows.Media.Protection.ProtectionCapabilityResult}
|
|
*/
|
|
isTypeSupported(type, keySystem) {}
|
|
};
|
|
|
|
/**
|
|
* @enum {string}
|
|
*/
|
|
Windows.Media.Protection.ProtectionCapabilityResult = {
|
|
notSupported: 'NotSupported',
|
|
maybe: 'Maybe',
|
|
probably: 'Probably',
|
|
};
|
|
|
|
|
|
/** @const */
|
|
var chrome = {};
|
|
|
|
|
|
/** @const */
|
|
chrome.webview = {};
|
|
|
|
|
|
/** @const */
|
|
chrome.webview.hostObjects = {};
|
|
|
|
|
|
/** @const */
|
|
chrome.webview.hostObjects.sync = {};
|
|
|
|
|
|
/** @const */
|
|
chrome.webview.hostObjects.sync.Windows = Windows;
|
|
|
|
/**
|
|
* Typedef for the module interface.
|
|
*
|
|
* @typedef {typeof Windows}
|
|
*/
|
|
var WinRT;
|