2018-09-13 23:04:55 +03:00
|
|
|
/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
2013-07-12 18:35:35 +04:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
|
|
|
|
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
|
|
|
*
|
|
|
|
* The origin of this IDL file is
|
|
|
|
* http://www.whatwg.org/specs/web-apps/current-work/#the-navigator-object
|
|
|
|
* http://www.w3.org/TR/tracking-dnt/
|
|
|
|
* http://www.w3.org/TR/geolocation-API/#geolocation_interface
|
|
|
|
* http://www.w3.org/TR/battery-status/#navigatorbattery-interface
|
|
|
|
* http://www.w3.org/TR/vibration/#vibration-interface
|
2013-07-12 18:35:44 +04:00
|
|
|
* http://www.w3.org/2012/sysapps/runtime/#extension-to-the-navigator-interface-1
|
2013-07-12 18:36:32 +04:00
|
|
|
* https://dvcs.w3.org/hg/gamepad/raw-file/default/gamepad.html#navigator-interface-extension
|
2014-03-06 19:51:23 +04:00
|
|
|
* http://www.w3.org/TR/beacon/#sec-beacon-method
|
2016-03-16 22:41:38 +03:00
|
|
|
* https://html.spec.whatwg.org/#navigatorconcurrenthardware
|
2016-12-16 10:50:23 +03:00
|
|
|
* http://wicg.github.io/netinfo/#extensions-to-the-navigator-interface
|
2018-01-17 05:11:44 +03:00
|
|
|
* https://w3c.github.io/webappsec-credential-management/#framework-credential-management
|
2018-01-27 22:42:17 +03:00
|
|
|
* https://w3c.github.io/webdriver/webdriver-spec.html#interface
|
2018-05-31 15:32:51 +03:00
|
|
|
* https://wicg.github.io/media-capabilities/#idl-index
|
2019-10-10 22:18:30 +03:00
|
|
|
* https://w3c.github.io/mediasession/#idl-index
|
2013-07-12 18:35:35 +04:00
|
|
|
*
|
|
|
|
* © Copyright 2004-2011 Apple Computer, Inc., Mozilla Foundation, and
|
|
|
|
* Opera Software ASA. You are granted a license to use, reproduce
|
|
|
|
* and create derivative works of this document.
|
|
|
|
*/
|
|
|
|
|
2018-12-13 16:47:39 +03:00
|
|
|
interface URI;
|
|
|
|
|
2013-07-12 18:35:35 +04:00
|
|
|
// http://www.whatwg.org/specs/web-apps/current-work/#the-navigator-object
|
2019-09-27 18:26:14 +03:00
|
|
|
[HeaderFile="Navigator.h",
|
|
|
|
Exposed=Window]
|
2013-07-12 18:35:35 +04:00
|
|
|
interface Navigator {
|
|
|
|
// objects implementing this interface also implement the interfaces given below
|
|
|
|
};
|
2019-09-24 18:22:26 +03:00
|
|
|
Navigator includes NavigatorID;
|
|
|
|
Navigator includes NavigatorLanguage;
|
|
|
|
Navigator includes NavigatorOnLine;
|
|
|
|
Navigator includes NavigatorContentUtils;
|
|
|
|
Navigator includes NavigatorStorageUtils;
|
|
|
|
Navigator includes NavigatorConcurrentHardware;
|
|
|
|
Navigator includes NavigatorStorage;
|
|
|
|
Navigator includes NavigatorAutomationInformation;
|
2019-10-02 19:46:03 +03:00
|
|
|
Navigator includes GPUProvider;
|
2019-09-24 18:22:26 +03:00
|
|
|
|
|
|
|
interface mixin NavigatorID {
|
2013-11-20 18:29:01 +04:00
|
|
|
// WebKit/Blink/Trident/Presto support this (hardcoded "Mozilla").
|
2018-01-22 20:59:15 +03:00
|
|
|
[Constant, Cached, Throws]
|
2013-11-20 18:29:01 +04:00
|
|
|
readonly attribute DOMString appCodeName; // constant "Mozilla"
|
2016-11-16 01:44:43 +03:00
|
|
|
[Constant, Cached, NeedsCallerType]
|
2013-07-12 18:35:35 +04:00
|
|
|
readonly attribute DOMString appName;
|
2016-11-16 01:44:43 +03:00
|
|
|
[Constant, Cached, Throws, NeedsCallerType]
|
2013-07-12 18:35:35 +04:00
|
|
|
readonly attribute DOMString appVersion;
|
2016-11-16 01:44:43 +03:00
|
|
|
[Constant, Cached, Throws, NeedsCallerType]
|
2013-07-12 18:35:35 +04:00
|
|
|
readonly attribute DOMString platform;
|
2016-11-16 01:44:43 +03:00
|
|
|
[Pure, Cached, Throws, NeedsCallerType]
|
2013-07-12 18:35:35 +04:00
|
|
|
readonly attribute DOMString userAgent;
|
2014-09-24 20:09:50 +04:00
|
|
|
[Constant, Cached]
|
2013-11-20 18:29:01 +04:00
|
|
|
readonly attribute DOMString product; // constant "Gecko"
|
2013-07-12 18:35:35 +04:00
|
|
|
|
2013-11-20 18:29:01 +04:00
|
|
|
// Everyone but WebKit/Blink supports this. See bug 679971.
|
2015-04-15 23:33:06 +03:00
|
|
|
[Exposed=Window]
|
2013-11-20 18:29:01 +04:00
|
|
|
boolean taintEnabled(); // constant false
|
2013-07-12 18:35:35 +04:00
|
|
|
};
|
|
|
|
|
2019-09-24 18:22:26 +03:00
|
|
|
interface mixin NavigatorLanguage {
|
2014-09-24 20:09:50 +04:00
|
|
|
|
2015-11-18 03:20:38 +03:00
|
|
|
// These two attributes are cached because this interface is also implemented
|
|
|
|
// by Workernavigator and this way we don't have to go back to the
|
|
|
|
// main-thread from the worker thread anytime we need to retrieve them. They
|
|
|
|
// are updated when pref intl.accept_languages is changed.
|
2014-09-24 20:09:50 +04:00
|
|
|
|
|
|
|
[Pure, Cached]
|
2013-07-12 18:35:35 +04:00
|
|
|
readonly attribute DOMString? language;
|
2014-08-05 06:20:34 +04:00
|
|
|
[Pure, Cached, Frozen]
|
|
|
|
readonly attribute sequence<DOMString> languages;
|
2013-07-12 18:35:35 +04:00
|
|
|
};
|
|
|
|
|
2019-09-24 18:22:26 +03:00
|
|
|
interface mixin NavigatorOnLine {
|
2013-07-12 18:35:35 +04:00
|
|
|
readonly attribute boolean onLine;
|
|
|
|
};
|
|
|
|
|
2019-09-24 18:22:26 +03:00
|
|
|
interface mixin NavigatorContentUtils {
|
2013-07-12 18:35:35 +04:00
|
|
|
// content handler registration
|
2018-12-13 16:47:39 +03:00
|
|
|
[Throws, ChromeOnly]
|
|
|
|
void checkProtocolHandlerAllowed(DOMString scheme, URI handlerURI, URI documentURI);
|
2018-02-04 15:10:10 +03:00
|
|
|
[Throws, Func="nsGlobalWindowInner::RegisterProtocolHandlerAllowedForContext"]
|
2013-07-12 18:35:35 +04:00
|
|
|
void registerProtocolHandler(DOMString scheme, DOMString url, DOMString title);
|
2018-01-08 05:18:31 +03:00
|
|
|
[Pref="dom.registerContentHandler.enabled", Throws]
|
2013-07-12 18:35:35 +04:00
|
|
|
void registerContentHandler(DOMString mimeType, DOMString url, DOMString title);
|
|
|
|
// NOT IMPLEMENTED
|
|
|
|
//DOMString isProtocolHandlerRegistered(DOMString scheme, DOMString url);
|
|
|
|
//DOMString isContentHandlerRegistered(DOMString mimeType, DOMString url);
|
|
|
|
//void unregisterProtocolHandler(DOMString scheme, DOMString url);
|
|
|
|
//void unregisterContentHandler(DOMString mimeType, DOMString url);
|
|
|
|
};
|
|
|
|
|
2019-09-24 18:22:26 +03:00
|
|
|
[SecureContext]
|
|
|
|
interface mixin NavigatorStorage {
|
2019-06-13 12:01:41 +03:00
|
|
|
[Pref="dom.storageManager.enabled"]
|
2016-06-14 15:57:36 +03:00
|
|
|
readonly attribute StorageManager storage;
|
|
|
|
};
|
|
|
|
|
2019-09-24 18:22:26 +03:00
|
|
|
interface mixin NavigatorStorageUtils {
|
2013-07-12 18:35:35 +04:00
|
|
|
// NOT IMPLEMENTED
|
|
|
|
//void yieldForStorageUpdates();
|
|
|
|
};
|
|
|
|
|
2015-07-28 16:33:46 +03:00
|
|
|
partial interface Navigator {
|
2016-02-03 19:21:31 +03:00
|
|
|
[Throws]
|
2015-07-28 16:33:46 +03:00
|
|
|
readonly attribute Permissions permissions;
|
|
|
|
};
|
|
|
|
|
2013-07-12 18:35:35 +04:00
|
|
|
// Things that definitely need to be in the spec and and are not for some
|
|
|
|
// reason. See https://www.w3.org/Bugs/Public/show_bug.cgi?id=22406
|
|
|
|
partial interface Navigator {
|
|
|
|
[Throws]
|
|
|
|
readonly attribute MimeTypeArray mimeTypes;
|
|
|
|
[Throws]
|
|
|
|
readonly attribute PluginArray plugins;
|
|
|
|
};
|
|
|
|
|
|
|
|
// http://www.w3.org/TR/tracking-dnt/ sort of
|
|
|
|
partial interface Navigator {
|
|
|
|
readonly attribute DOMString doNotTrack;
|
|
|
|
};
|
|
|
|
|
|
|
|
// http://www.w3.org/TR/geolocation-API/#geolocation_interface
|
2019-09-24 18:22:26 +03:00
|
|
|
interface mixin NavigatorGeolocation {
|
2013-07-27 00:12:12 +04:00
|
|
|
[Throws, Pref="geo.enabled"]
|
|
|
|
readonly attribute Geolocation geolocation;
|
2013-07-12 18:35:35 +04:00
|
|
|
};
|
2019-09-24 18:22:26 +03:00
|
|
|
Navigator includes NavigatorGeolocation;
|
2013-07-12 18:35:35 +04:00
|
|
|
|
|
|
|
// http://www.w3.org/TR/battery-status/#navigatorbattery-interface
|
2015-08-21 13:29:25 +03:00
|
|
|
partial interface Navigator {
|
2016-10-29 04:45:36 +03:00
|
|
|
// ChromeOnly to prevent web content from fingerprinting users' batteries.
|
|
|
|
[Throws, ChromeOnly, Pref="dom.battery.enabled"]
|
2015-08-21 13:29:25 +03:00
|
|
|
Promise<BatteryManager> getBattery();
|
2013-07-12 18:35:35 +04:00
|
|
|
};
|
|
|
|
|
|
|
|
// http://www.w3.org/TR/vibration/#vibration-interface
|
|
|
|
partial interface Navigator {
|
|
|
|
// We don't support sequences in unions yet
|
|
|
|
//boolean vibrate ((unsigned long or sequence<unsigned long>) pattern);
|
2013-09-28 22:58:38 +04:00
|
|
|
boolean vibrate(unsigned long duration);
|
|
|
|
boolean vibrate(sequence<unsigned long> pattern);
|
2013-07-12 18:35:35 +04:00
|
|
|
};
|
|
|
|
|
2014-01-28 20:09:34 +04:00
|
|
|
// http://www.w3.org/TR/pointerevents/#extensions-to-the-navigator-interface
|
|
|
|
partial interface Navigator {
|
2018-10-09 14:50:03 +03:00
|
|
|
[Pref="dom.w3c_pointer_events.enabled", NeedsCallerType]
|
2014-01-28 20:09:34 +04:00
|
|
|
readonly attribute long maxTouchPoints;
|
|
|
|
};
|
|
|
|
|
2018-05-31 15:32:51 +03:00
|
|
|
// https://wicg.github.io/media-capabilities/#idl-index
|
|
|
|
[Exposed=Window]
|
|
|
|
partial interface Navigator {
|
|
|
|
[SameObject, Func="mozilla::dom::MediaCapabilities::Enabled"]
|
|
|
|
readonly attribute MediaCapabilities mediaCapabilities;
|
|
|
|
};
|
|
|
|
|
2013-07-12 18:35:35 +04:00
|
|
|
// Mozilla-specific extensions
|
|
|
|
|
2016-04-26 16:40:27 +03:00
|
|
|
// Chrome-only interface for Vibration API permission handling.
|
|
|
|
partial interface Navigator {
|
|
|
|
/* Set permission state to device vibration.
|
|
|
|
* @param permitted permission state (true for allowing vibration)
|
|
|
|
* @param persistent make the permission session-persistent
|
|
|
|
*/
|
|
|
|
[ChromeOnly]
|
|
|
|
void setVibrationPermission(boolean permitted,
|
|
|
|
optional boolean persistent = true);
|
|
|
|
};
|
|
|
|
|
2013-07-12 18:35:35 +04:00
|
|
|
partial interface Navigator {
|
2016-11-16 01:44:43 +03:00
|
|
|
[Throws, Constant, Cached, NeedsCallerType]
|
2013-07-12 18:35:35 +04:00
|
|
|
readonly attribute DOMString oscpu;
|
|
|
|
// WebKit/Blink support this; Trident/Presto do not.
|
|
|
|
readonly attribute DOMString vendor;
|
|
|
|
// WebKit/Blink supports this (hardcoded ""); Trident/Presto do not.
|
|
|
|
readonly attribute DOMString vendorSub;
|
|
|
|
// WebKit/Blink supports this (hardcoded "20030107"); Trident/Presto don't
|
|
|
|
readonly attribute DOMString productSub;
|
|
|
|
// WebKit/Blink/Trident/Presto support this.
|
|
|
|
readonly attribute boolean cookieEnabled;
|
2016-11-16 01:44:43 +03:00
|
|
|
[Throws, Constant, Cached, NeedsCallerType]
|
2013-07-12 18:35:35 +04:00
|
|
|
readonly attribute DOMString buildID;
|
|
|
|
|
|
|
|
// WebKit/Blink/Trident/Presto support this.
|
2017-04-29 04:54:33 +03:00
|
|
|
[Affects=Nothing, DependsOn=Nothing]
|
2013-07-12 18:35:35 +04:00
|
|
|
boolean javaEnabled();
|
|
|
|
};
|
2013-07-12 18:35:44 +04:00
|
|
|
|
2019-08-26 21:56:34 +03:00
|
|
|
// Addon manager bits
|
|
|
|
partial interface Navigator {
|
|
|
|
[Throws, Func="mozilla::AddonManagerWebAPI::IsAPIEnabled"]
|
|
|
|
readonly attribute AddonManager mozAddonManager;
|
|
|
|
};
|
|
|
|
|
2014-03-05 07:22:39 +04:00
|
|
|
// NetworkInformation
|
2013-07-12 18:35:44 +04:00
|
|
|
partial interface Navigator {
|
2014-03-05 07:22:39 +04:00
|
|
|
[Throws, Pref="dom.netinfo.enabled"]
|
|
|
|
readonly attribute NetworkInformation connection;
|
2013-07-12 18:35:44 +04:00
|
|
|
};
|
|
|
|
|
2013-07-12 18:36:32 +04:00
|
|
|
// https://dvcs.w3.org/hg/gamepad/raw-file/default/gamepad.html#navigator-interface-extension
|
|
|
|
partial interface Navigator {
|
|
|
|
[Throws, Pref="dom.gamepad.enabled"]
|
|
|
|
sequence<Gamepad?> getGamepads();
|
|
|
|
};
|
2016-06-28 01:26:00 +03:00
|
|
|
partial interface Navigator {
|
|
|
|
[Pref="dom.gamepad.test.enabled"]
|
|
|
|
GamepadServiceTest requestGamepadServiceTest();
|
|
|
|
};
|
2013-07-12 18:36:32 +04:00
|
|
|
|
2019-12-12 06:10:51 +03:00
|
|
|
// https://immersive-web.github.io/webvr/spec/1.1/#interface-navigator
|
2014-07-09 23:24:49 +04:00
|
|
|
partial interface Navigator {
|
2019-12-12 06:10:51 +03:00
|
|
|
[Throws, SecureContext, Pref="dom.vr.enabled"]
|
2016-04-13 03:39:28 +03:00
|
|
|
Promise<sequence<VRDisplay>> getVRDisplays();
|
2016-08-12 01:57:26 +03:00
|
|
|
// TODO: Use FrozenArray once available. (Bug 1236777)
|
2019-12-12 06:10:51 +03:00
|
|
|
[SecureContext, Frozen, Cached, Pure, Pref="dom.vr.enabled"]
|
2016-08-12 01:57:26 +03:00
|
|
|
readonly attribute sequence<VRDisplay> activeVRDisplays;
|
2017-05-09 02:01:36 +03:00
|
|
|
[ChromeOnly, Pref="dom.vr.enabled"]
|
|
|
|
readonly attribute boolean isWebVRContentDetected;
|
|
|
|
[ChromeOnly, Pref="dom.vr.enabled"]
|
|
|
|
readonly attribute boolean isWebVRContentPresenting;
|
|
|
|
[ChromeOnly, Pref="dom.vr.enabled"]
|
|
|
|
void requestVRPresentation(VRDisplay display);
|
2014-07-09 23:24:49 +04:00
|
|
|
};
|
2017-03-01 13:33:28 +03:00
|
|
|
partial interface Navigator {
|
2019-06-29 00:19:54 +03:00
|
|
|
[Pref="dom.vr.puppet.enabled"]
|
2017-03-01 13:33:28 +03:00
|
|
|
VRServiceTest requestVRServiceTest();
|
|
|
|
};
|
2014-07-09 23:24:49 +04:00
|
|
|
|
2017-11-15 09:02:57 +03:00
|
|
|
// http://webaudio.github.io/web-midi-api/#requestmidiaccess
|
|
|
|
partial interface Navigator {
|
|
|
|
[Throws, Pref="dom.webmidi.enabled"]
|
2019-07-03 10:52:35 +03:00
|
|
|
Promise<MIDIAccess> requestMIDIAccess(optional MIDIOptions options = {});
|
2017-11-15 09:02:57 +03:00
|
|
|
};
|
|
|
|
|
2013-09-16 10:34:57 +04:00
|
|
|
callback NavigatorUserMediaSuccessCallback = void (MediaStream stream);
|
2014-10-27 22:42:56 +03:00
|
|
|
callback NavigatorUserMediaErrorCallback = void (MediaStreamError error);
|
2013-09-16 10:34:57 +04:00
|
|
|
|
2013-07-12 18:37:21 +04:00
|
|
|
partial interface Navigator {
|
2014-09-20 10:20:41 +04:00
|
|
|
[Throws, Func="Navigator::HasUserMediaSupport"]
|
|
|
|
readonly attribute MediaDevices mediaDevices;
|
|
|
|
|
|
|
|
// Deprecated. Use mediaDevices.getUserMedia instead.
|
2015-09-28 21:25:04 +03:00
|
|
|
[Deprecated="NavigatorGetUserMedia", Throws,
|
2017-12-15 01:03:14 +03:00
|
|
|
Func="Navigator::HasUserMediaSupport",
|
2019-05-04 02:50:22 +03:00
|
|
|
NeedsCallerType,
|
|
|
|
UseCounter]
|
2013-09-16 10:34:57 +04:00
|
|
|
void mozGetUserMedia(MediaStreamConstraints constraints,
|
|
|
|
NavigatorUserMediaSuccessCallback successCallback,
|
|
|
|
NavigatorUserMediaErrorCallback errorCallback);
|
2013-07-12 18:37:21 +04:00
|
|
|
};
|
|
|
|
|
|
|
|
// nsINavigatorUserMedia
|
|
|
|
callback MozGetUserMediaDevicesSuccessCallback = void (nsIVariant? devices);
|
|
|
|
partial interface Navigator {
|
|
|
|
[Throws, ChromeOnly]
|
2014-04-18 22:00:16 +04:00
|
|
|
void mozGetUserMediaDevices(MediaStreamConstraints constraints,
|
2013-09-16 10:34:57 +04:00
|
|
|
MozGetUserMediaDevicesSuccessCallback onsuccess,
|
2014-02-14 23:32:58 +04:00
|
|
|
NavigatorUserMediaErrorCallback onerror,
|
|
|
|
// The originating innerWindowID is needed to
|
|
|
|
// avoid calling the callbacks if the window has
|
|
|
|
// navigated away. It is optional only as legacy.
|
2016-01-08 01:30:10 +03:00
|
|
|
optional unsigned long long innerWindowID = 0,
|
|
|
|
// The callID is needed in case of multiple
|
|
|
|
// concurrent requests to find the right one.
|
|
|
|
// It is optional only as legacy.
|
|
|
|
// TODO: Rewrite to not need this method anymore,
|
|
|
|
// now that devices are enumerated earlier.
|
|
|
|
optional DOMString callID = "");
|
2013-07-12 18:37:21 +04:00
|
|
|
};
|
2014-03-06 19:51:23 +04:00
|
|
|
|
2013-11-20 03:14:07 +04:00
|
|
|
// Service Workers/Navigation Controllers
|
|
|
|
partial interface Navigator {
|
2016-01-09 05:59:56 +03:00
|
|
|
[Func="ServiceWorkerContainer::IsEnabled", SameObject]
|
2013-11-20 03:14:07 +04:00
|
|
|
readonly attribute ServiceWorkerContainer serviceWorker;
|
|
|
|
};
|
|
|
|
|
2014-03-06 19:51:23 +04:00
|
|
|
partial interface Navigator {
|
|
|
|
[Throws, Pref="beacon.enabled"]
|
|
|
|
boolean sendBeacon(DOMString url,
|
2017-01-24 14:13:31 +03:00
|
|
|
optional BodyInit? data = null);
|
2014-03-06 19:51:23 +04:00
|
|
|
};
|
2014-08-21 13:15:18 +04:00
|
|
|
|
2015-03-19 10:48:28 +03:00
|
|
|
partial interface Navigator {
|
2016-06-03 14:50:30 +03:00
|
|
|
[Throws, Pref="dom.presentation.enabled", SameObject]
|
2015-03-19 10:48:28 +03:00
|
|
|
readonly attribute Presentation? presentation;
|
|
|
|
};
|
|
|
|
|
2015-03-25 17:36:24 +03:00
|
|
|
partial interface Navigator {
|
2016-04-21 16:48:59 +03:00
|
|
|
[NewObject, Func="mozilla::dom::TCPSocket::ShouldTCPSocketExist"]
|
2015-03-25 17:35:59 +03:00
|
|
|
readonly attribute LegacyMozTCPSocket mozTCPSocket;
|
2015-03-25 17:36:24 +03:00
|
|
|
};
|
2015-03-25 17:35:59 +03:00
|
|
|
|
2014-11-18 12:13:02 +03:00
|
|
|
partial interface Navigator {
|
2017-02-02 09:10:06 +03:00
|
|
|
[NewObject]
|
2014-11-18 12:13:02 +03:00
|
|
|
Promise<MediaKeySystemAccess>
|
|
|
|
requestMediaKeySystemAccess(DOMString keySystem,
|
2015-10-27 04:10:51 +03:00
|
|
|
sequence<MediaKeySystemConfiguration> supportedConfigurations);
|
2014-11-18 12:13:02 +03:00
|
|
|
};
|
2015-02-18 01:10:45 +03:00
|
|
|
|
2019-09-24 18:22:26 +03:00
|
|
|
interface mixin NavigatorConcurrentHardware {
|
2016-03-16 22:41:38 +03:00
|
|
|
readonly attribute unsigned long long hardwareConcurrency;
|
|
|
|
};
|
2017-01-09 23:22:49 +03:00
|
|
|
|
2018-01-17 05:11:44 +03:00
|
|
|
// https://w3c.github.io/webappsec-credential-management/#framework-credential-management
|
2017-05-23 03:09:49 +03:00
|
|
|
partial interface Navigator {
|
2018-01-17 05:11:44 +03:00
|
|
|
[Pref="security.webauth.webauthn", SecureContext, SameObject]
|
2017-05-23 03:09:49 +03:00
|
|
|
readonly attribute CredentialsContainer credentials;
|
|
|
|
};
|
2018-01-27 22:42:17 +03:00
|
|
|
|
|
|
|
// https://w3c.github.io/webdriver/webdriver-spec.html#interface
|
2019-09-24 18:22:26 +03:00
|
|
|
interface mixin NavigatorAutomationInformation {
|
2018-02-09 17:57:32 +03:00
|
|
|
[Pref="dom.webdriver.enabled"]
|
2018-01-27 22:42:17 +03:00
|
|
|
readonly attribute boolean webdriver;
|
|
|
|
};
|
2018-05-31 18:57:57 +03:00
|
|
|
|
|
|
|
// https://www.w3.org/TR/clipboard-apis/#navigator-interface
|
|
|
|
partial interface Navigator {
|
|
|
|
[Pref="dom.events.asyncClipboard", SecureContext, SameObject]
|
|
|
|
readonly attribute Clipboard clipboard;
|
|
|
|
};
|
2019-10-09 13:57:11 +03:00
|
|
|
|
|
|
|
// https://wicg.github.io/web-share/#navigator-interface
|
|
|
|
partial interface Navigator {
|
|
|
|
[SecureContext, Throws, Pref="dom.webshare.enabled"]
|
|
|
|
Promise<void> share(optional ShareData data = {});
|
|
|
|
};
|
|
|
|
// https://wicg.github.io/web-share/#sharedata-dictionary
|
|
|
|
dictionary ShareData {
|
|
|
|
USVString title;
|
|
|
|
USVString text;
|
|
|
|
USVString url;
|
|
|
|
};
|
2019-10-10 22:18:30 +03:00
|
|
|
|
|
|
|
// https://w3c.github.io/mediasession/#idl-index
|
|
|
|
[Exposed=Window]
|
|
|
|
partial interface Navigator {
|
|
|
|
[Pref="dom.media.mediasession.enabled", SameObject]
|
|
|
|
readonly attribute MediaSession mediaSession;
|
|
|
|
};
|