diff options
Diffstat (limited to 'dom/webidl')
-rw-r--r-- | dom/webidl/Fetch.webidl | 14 | ||||
-rw-r--r-- | dom/webidl/Navigator.webidl | 2 | ||||
-rw-r--r-- | dom/webidl/RTCPeerConnection.webidl | 13 | ||||
-rw-r--r-- | dom/webidl/Response.webidl | 10 | ||||
-rw-r--r-- | dom/webidl/WindowOrWorkerGlobalScope.webidl | 4 |
5 files changed, 25 insertions, 18 deletions
diff --git a/dom/webidl/Fetch.webidl b/dom/webidl/Fetch.webidl index 4b2a0af7d0..bbb1faf7f7 100644 --- a/dom/webidl/Fetch.webidl +++ b/dom/webidl/Fetch.webidl @@ -8,7 +8,7 @@ */ typedef object JSON; -typedef (ArrayBuffer or ArrayBufferView or Blob or FormData or USVString or URLSearchParams) BodyInit; +typedef (Blob or BufferSource or FormData or URLSearchParams or USVString) BodyInit; [NoInterfaceObject, Exposed=(Window,Worker)] interface Body { @@ -24,3 +24,15 @@ interface Body { [Throws] Promise<USVString> text(); }; + +// These are helper dictionaries for the parsing of a +// getReader().read().then(data) parsing. +// See more about how these 2 helpers are used in +// dom/fetch/FetchStreamReader.cpp +dictionary FetchReadableStreamReadDataDone { + boolean done = false; +}; + +dictionary FetchReadableStreamReadDataArray { + Uint8Array value; +}; diff --git a/dom/webidl/Navigator.webidl b/dom/webidl/Navigator.webidl index 516b5415e3..5f2ac63e1e 100644 --- a/dom/webidl/Navigator.webidl +++ b/dom/webidl/Navigator.webidl @@ -296,7 +296,7 @@ partial interface Navigator { partial interface Navigator { [Throws, Pref="beacon.enabled"] boolean sendBeacon(DOMString url, - optional (ArrayBufferView or Blob or DOMString or FormData)? data = null); + optional BodyInit? data = null); }; partial interface Navigator { diff --git a/dom/webidl/RTCPeerConnection.webidl b/dom/webidl/RTCPeerConnection.webidl index 6fb4194c36..b852d32070 100644 --- a/dom/webidl/RTCPeerConnection.webidl +++ b/dom/webidl/RTCPeerConnection.webidl @@ -66,17 +66,6 @@ dictionary RTCOfferOptions : RTCOfferAnswerOptions { // Mozilla proprietary options (at risk: Bug 1196974) boolean mozDontOfferDataChannel; boolean mozBundleOnly; - - // TODO: Remove old constraint-like RTCOptions support soon (Bug 1064223). - DeprecatedRTCOfferOptionsSet mandatory; - sequence<DeprecatedRTCOfferOptionsSet> _optional; -}; - -dictionary DeprecatedRTCOfferOptionsSet { - boolean OfferToReceiveAudio; // Note the uppercase 'O' - boolean OfferToReceiveVideo; // Note the uppercase 'O' - boolean MozDontOfferDataChannel; // Note the uppercase 'M' - boolean MozBundleOnly; // Note the uppercase 'M' }; interface RTCDataChannel; @@ -119,8 +108,6 @@ interface RTCPeerConnection : EventTarget { sequence<MediaStream> getLocalStreams (); [UnsafeInPrerendering, Deprecated="RTCPeerConnectionGetStreams"] sequence<MediaStream> getRemoteStreams (); - [UnsafeInPrerendering] - MediaStream? getStreamById (DOMString streamId); void addStream (MediaStream stream); // replaces addStream; fails if already added diff --git a/dom/webidl/Response.webidl b/dom/webidl/Response.webidl index 08f31fe29a..0f4c99dbac 100644 --- a/dom/webidl/Response.webidl +++ b/dom/webidl/Response.webidl @@ -7,7 +7,9 @@ * https://fetch.spec.whatwg.org/#response-class */ -[Constructor(optional BodyInit? body, optional ResponseInit init), +// This should be Constructor(optional BodyInit... but BodyInit doesn't include +// ReadableStream yet because we don't want to expose the Streams API to Request. +[Constructor(optional (Blob or BufferSource or FormData or URLSearchParams or ReadableStream or USVString) body, optional ResponseInit init), Exposed=(Window,Worker)] interface Response { [NewObject] static Response error(); @@ -30,6 +32,12 @@ interface Response { }; Response implements Body; +// This should be part of Body but we don't want to expose body to request yet. +partial interface Response { + [GetterThrows, Func="nsContentUtils::StreamsEnabled"] + readonly attribute ReadableStream? body; +}; + dictionary ResponseInit { unsigned short status = 200; ByteString statusText = "OK"; diff --git a/dom/webidl/WindowOrWorkerGlobalScope.webidl b/dom/webidl/WindowOrWorkerGlobalScope.webidl index 9e639db5f4..d378ba49ec 100644 --- a/dom/webidl/WindowOrWorkerGlobalScope.webidl +++ b/dom/webidl/WindowOrWorkerGlobalScope.webidl @@ -31,9 +31,9 @@ interface WindowOrWorkerGlobalScope { long setTimeout(DOMString handler, optional long timeout = 0, any... unused); void clearTimeout(optional long handle = 0); [Throws] - long setInterval(Function handler, optional long timeout, any... arguments); + long setInterval(Function handler, optional long timeout = 0, any... arguments); [Throws] - long setInterval(DOMString handler, optional long timeout, any... unused); + long setInterval(DOMString handler, optional long timeout = 0, any... unused); void clearInterval(optional long handle = 0); // microtask queuing |