WebKit Bugzilla
Attachment 348327 Details for
Bug 189040
: Remove WebRTC legacy API implementation
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-189040-20180828131249.patch (text/plain), 204.92 KB, created by
youenn fablet
on 2018-08-28 13:12:50 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
youenn fablet
Created:
2018-08-28 13:12:50 PDT
Size:
204.92 KB
patch
obsolete
>Subversion Revision: 235427 >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index a38329957887d7526be5f7d89c364106391caa4d..825fbe2c0e1f53961733fbebfcdd3ad31b5f785a 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,61 @@ >+2018-08-27 Youenn Fablet <youenn@apple.com> >+ >+ Remove WebRTC legacy API implementation >+ https://bugs.webkit.org/show_bug.cgi?id=189040 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ This API is no longer needed so this is better to remove it. >+ This allows removing some code. >+ Covered by existing tests. >+ >+ * CMakeLists.txt: >+ * DerivedSources.make: >+ * Modules/mediastream/MediaStreamEvent.cpp: Removed. >+ * Modules/mediastream/MediaStreamEvent.h: Removed. >+ * Modules/mediastream/MediaStreamEvent.idl: Removed. >+ * Modules/mediastream/NavigatorUserMedia.idl: Removed. >+ * Modules/mediastream/NavigatorUserMedia.js: Removed. >+ * Modules/mediastream/PeerConnectionBackend.cpp: >+ * Modules/mediastream/PeerConnectionBackend.h: >+ * Modules/mediastream/RTCPeerConnection.h: >+ * Modules/mediastream/RTCPeerConnection.idl: >+ * Modules/mediastream/RTCPeerConnection.js: >+ (initializeRTCPeerConnection): >+ (createOffer): >+ (createAnswer): >+ (setLocalDescription): >+ (setRemoteDescription): >+ (addIceCandidate): >+ (getLocalStreams): Deleted. >+ (getStreamById): Deleted. >+ (addStream): Deleted. >+ (): Deleted. >+ * Modules/mediastream/RTCPeerConnectionInternals.js: >+ (callbacksAndDictionaryOverload): >+ (if): Deleted. >+ * Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp: >+ (WebCore::LibWebRTCMediaEndpoint::mediaStreamFromRTCStream): >+ (WebCore::LibWebRTCMediaEndpoint::addRemoteStream): >+ (WebCore::LibWebRTCMediaEndpoint::removeRemoteStream): >+ * Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.h: >+ * Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.cpp: >+ (WebCore::LibWebRTCPeerConnectionBackend::doStop): >+ (WebCore::LibWebRTCPeerConnectionBackend::removeRemoteStream): Deleted. >+ (WebCore::LibWebRTCPeerConnectionBackend::addRemoteStream): Deleted. >+ * Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.h: >+ * Sources.txt: >+ * WebCore.xcodeproj/project.pbxproj: >+ * bindings/js/JSDOMGlobalObject.cpp: >+ (WebCore::JSDOMGlobalObject::addBuiltinGlobals): >+ (WebCore::isWebRTCLegacyAPIEnabled): Deleted. >+ * bindings/js/WebCoreBuiltinNames.h: >+ * dom/EventNames.in: >+ * page/RuntimeEnabledFeatures.h: >+ (WebCore::RuntimeEnabledFeatures::setPeerConnectionEnabled): >+ (WebCore::RuntimeEnabledFeatures::webRTCLegacyAPIEnabled const): Deleted. >+ (WebCore::RuntimeEnabledFeatures::setWebRTCLegacyAPIEnabled): Deleted. >+ > 2018-08-28 Aditya Keerthi <akeerthi@apple.com> > > [iOS] Support inputmode=none >diff --git a/Source/WebKit/ChangeLog b/Source/WebKit/ChangeLog >index 6694ed1bf6797ae0afc3814c83b20b2f7bf93b6c..6544b7e36af635147cd805dd6fbd8e9117e3e807 100644 >--- a/Source/WebKit/ChangeLog >+++ b/Source/WebKit/ChangeLog >@@ -1,3 +1,22 @@ >+2018-08-27 Youenn Fablet <youenn@apple.com> >+ >+ Remove WebRTC legacy API implementation >+ https://bugs.webkit.org/show_bug.cgi?id=189040 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * Shared/WebPreferences.yaml: >+ * UIProcess/API/C/WKPreferences.cpp: >+ (WKPreferencesSetWebRTCLegacyAPIEnabled): Deleted. >+ (WKPreferencesGetWebRTCLegacyAPIEnabled): Deleted. >+ * UIProcess/API/C/WKPreferencesRef.h: >+ * UIProcess/API/Cocoa/WKPreferences.mm: >+ (-[WKPreferences _webRTCLegacyAPIEnabled]): Deleted. >+ (-[WKPreferences _setWebRTCLegacyAPIEnabled:]): Deleted. >+ * UIProcess/API/Cocoa/WKPreferencesPrivate.h: >+ * WebProcess/InjectedBundle/InjectedBundle.cpp: >+ (WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner): >+ > 2018-08-28 Aditya Keerthi <akeerthi@apple.com> > > [Datalist] Pressing enter without a selected option shouldn't change the input >diff --git a/Source/WebKitLegacy/mac/ChangeLog b/Source/WebKitLegacy/mac/ChangeLog >index de2642c76ad3868a80190983b9720e6481e0b6ee..585370751cbb4b9bf5bb47a5fd1526456b521224 100644 >--- a/Source/WebKitLegacy/mac/ChangeLog >+++ b/Source/WebKitLegacy/mac/ChangeLog >@@ -1,3 +1,19 @@ >+2018-08-27 Youenn Fablet <youenn@apple.com> >+ >+ Remove WebRTC legacy API implementation >+ https://bugs.webkit.org/show_bug.cgi?id=189040 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * WebView/WebPreferenceKeysPrivate.h: >+ * WebView/WebPreferences.mm: >+ (+[WebPreferences initialize]): >+ (-[WebPreferences webRTCLegacyAPIEnabled]): Deleted. >+ (-[WebPreferences setWebRTCLegacyAPIEnabled:]): Deleted. >+ * WebView/WebPreferencesPrivate.h: >+ * WebView/WebView.mm: >+ (-[WebView _preferencesChanged:]): >+ > 2018-08-27 Keith Rollin <krollin@apple.com> > > Unreviewed build fix -- disable LTO for production builds >diff --git a/Source/WebCore/CMakeLists.txt b/Source/WebCore/CMakeLists.txt >index a9c4a5f4347046cdacebbf8a1cb381a3f514856d..4d9e61d4aa51f8351c181fc4c3f937c396040745 100644 >--- a/Source/WebCore/CMakeLists.txt >+++ b/Source/WebCore/CMakeLists.txt >@@ -293,13 +293,11 @@ set(WebCore_NON_SVG_IDL_FILES > Modules/mediastream/MediaDeviceInfo.idl > Modules/mediastream/MediaDevices.idl > Modules/mediastream/MediaStream.idl >- Modules/mediastream/MediaStreamEvent.idl > Modules/mediastream/MediaStreamTrack.idl > Modules/mediastream/MediaStreamTrackEvent.idl > Modules/mediastream/MediaTrackConstraints.idl > Modules/mediastream/MediaTrackSupportedConstraints.idl > Modules/mediastream/NavigatorMediaDevices.idl >- Modules/mediastream/NavigatorUserMedia.idl > Modules/mediastream/OverconstrainedError.idl > Modules/mediastream/OverconstrainedErrorEvent.idl > Modules/mediastream/RTCAnswerOptions.idl >@@ -1830,7 +1828,6 @@ add_dependencies(WebCoreTestSupportBindings WebCore) > # WebCore JS Builtins > > set(WebCore_BUILTINS_SOURCES >- ${WEBCORE_DIR}/Modules/mediastream/NavigatorUserMedia.js > ${WEBCORE_DIR}/Modules/mediastream/RTCPeerConnection.js > ${WEBCORE_DIR}/Modules/mediastream/RTCPeerConnectionInternals.js > ${WEBCORE_DIR}/Modules/streams/ByteLengthQueuingStrategy.js >diff --git a/Source/WebCore/DerivedSources.make b/Source/WebCore/DerivedSources.make >index 6c9b2ce6b61c0059d69e7a99460aa70aec8c0a4d..b77ddbff69dbf0daaa5968e9a4e35c6436d806df 100644 >--- a/Source/WebCore/DerivedSources.make >+++ b/Source/WebCore/DerivedSources.make >@@ -217,13 +217,11 @@ JS_BINDING_IDLS = \ > $(WebCore)/Modules/mediastream/MediaDeviceInfo.idl \ > $(WebCore)/Modules/mediastream/MediaDevices.idl \ > $(WebCore)/Modules/mediastream/MediaStream.idl \ >- $(WebCore)/Modules/mediastream/MediaStreamEvent.idl \ > $(WebCore)/Modules/mediastream/MediaStreamTrack.idl \ > $(WebCore)/Modules/mediastream/MediaStreamTrackEvent.idl \ > $(WebCore)/Modules/mediastream/MediaTrackConstraints.idl \ > $(WebCore)/Modules/mediastream/MediaTrackSupportedConstraints.idl \ > $(WebCore)/Modules/mediastream/NavigatorMediaDevices.idl \ >- $(WebCore)/Modules/mediastream/NavigatorUserMedia.idl \ > $(WebCore)/Modules/mediastream/OverconstrainedError.idl \ > $(WebCore)/Modules/mediastream/OverconstrainedErrorEvent.idl \ > $(WebCore)/Modules/mediastream/RTCAnswerOptions.idl \ >@@ -1515,7 +1513,6 @@ CommandLineAPIModuleSource.h : CommandLineAPIModuleSource.js > # WebCore JS Builtins > > WebCore_BUILTINS_SOURCES = \ >- $(WebCore)/Modules/mediastream/NavigatorUserMedia.js \ > $(WebCore)/Modules/mediastream/RTCPeerConnection.js \ > $(WebCore)/Modules/mediastream/RTCPeerConnectionInternals.js \ > $(WebCore)/Modules/streams/ByteLengthQueuingStrategy.js \ >diff --git a/Source/WebCore/Modules/mediastream/MediaStreamEvent.cpp b/Source/WebCore/Modules/mediastream/MediaStreamEvent.cpp >deleted file mode 100644 >index 7bd10f6350375695b3d8e4ae7ebb56a99e9703db..0000000000000000000000000000000000000000 >--- a/Source/WebCore/Modules/mediastream/MediaStreamEvent.cpp >+++ /dev/null >@@ -1,71 +0,0 @@ >-/* >- * Copyright (C) 2011 Google Inc. All rights reserved. >- * >- * Redistribution and use in source and binary forms, with or without >- * modification, are permitted provided that the following conditions >- * are met: >- * 1. Redistributions of source code must retain the above copyright >- * notice, this list of conditions and the following disclaimer. >- * 2. Redistributions in binary form must reproduce the above copyright >- * notice, this list of conditions and the following disclaimer in the >- * documentation and/or other materials provided with the distribution. >- * >- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' AND ANY >- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED >- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE >- * DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS BE LIABLE FOR ANY >- * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES >- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; >- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON >- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT >- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS >- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. >- */ >- >-#include "config.h" >-#include "MediaStreamEvent.h" >- >-#if ENABLE(WEB_RTC) >- >-#include "MediaStream.h" >- >-namespace WebCore { >- >-Ref<MediaStreamEvent> MediaStreamEvent::create(const AtomicString& type, CanBubble canBubble, IsCancelable cancelable, RefPtr<MediaStream>&& stream) >-{ >- return adoptRef(*new MediaStreamEvent(type, canBubble, cancelable, WTFMove(stream))); >-} >- >-Ref<MediaStreamEvent> MediaStreamEvent::create(const AtomicString& type, const Init& initializer, IsTrusted isTrusted) >-{ >- return adoptRef(*new MediaStreamEvent(type, initializer, isTrusted)); >-} >- >-MediaStreamEvent::MediaStreamEvent(const AtomicString& type, CanBubble canBubble, IsCancelable cancelable, RefPtr<MediaStream>&& stream) >- : Event(type, canBubble, cancelable) >- , m_stream(WTFMove(stream)) >-{ >-} >- >-MediaStreamEvent::MediaStreamEvent(const AtomicString& type, const Init& initializer, IsTrusted isTrusted) >- : Event(type, initializer, isTrusted) >- , m_stream(initializer.stream) >-{ >-} >- >-MediaStreamEvent::~MediaStreamEvent() = default; >- >-MediaStream* MediaStreamEvent::stream() const >-{ >- return m_stream.get(); >-} >- >-EventInterface MediaStreamEvent::eventInterface() const >-{ >- return MediaStreamEventInterfaceType; >-} >- >-} // namespace WebCore >- >-#endif // ENABLE(WEB_RTC) >- >diff --git a/Source/WebCore/Modules/mediastream/MediaStreamEvent.h b/Source/WebCore/Modules/mediastream/MediaStreamEvent.h >deleted file mode 100644 >index c7abf5a66a53ed51ed4439afadf3c231c54215df..0000000000000000000000000000000000000000 >--- a/Source/WebCore/Modules/mediastream/MediaStreamEvent.h >+++ /dev/null >@@ -1,59 +0,0 @@ >-/* >- * Copyright (C) 2011 Google Inc. All rights reserved. >- * >- * Redistribution and use in source and binary forms, with or without >- * modification, are permitted provided that the following conditions >- * are met: >- * 1. Redistributions of source code must retain the above copyright >- * notice, this list of conditions and the following disclaimer. >- * 2. Redistributions in binary form must reproduce the above copyright >- * notice, this list of conditions and the following disclaimer in the >- * documentation and/or other materials provided with the distribution. >- * >- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' AND ANY >- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED >- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE >- * DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS BE LIABLE FOR ANY >- * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES >- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; >- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON >- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT >- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS >- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. >- */ >- >-#pragma once >- >-#if ENABLE(WEB_RTC) >- >-#include "Event.h" >-#include "MediaStream.h" >-#include <wtf/text/AtomicString.h> >- >-namespace WebCore { >- >-class MediaStreamEvent : public Event { >-public: >- virtual ~MediaStreamEvent(); >- >- static Ref<MediaStreamEvent> create(const AtomicString& type, CanBubble, IsCancelable, RefPtr<MediaStream>&&); >- >- struct Init : EventInit { >- RefPtr<MediaStream> stream; >- }; >- static Ref<MediaStreamEvent> create(const AtomicString& type, const Init& initializer, IsTrusted = IsTrusted::No); >- >- MediaStream* stream() const; >- >- virtual EventInterface eventInterface() const; >- >-private: >- MediaStreamEvent(const AtomicString& type, CanBubble, IsCancelable, RefPtr<MediaStream>&&); >- MediaStreamEvent(const AtomicString& type, const Init&, IsTrusted); >- >- RefPtr<MediaStream> m_stream; >-}; >- >-} // namespace WebCore >- >-#endif // ENABLE(WEB_RTC) >diff --git a/Source/WebCore/Modules/mediastream/MediaStreamEvent.idl b/Source/WebCore/Modules/mediastream/MediaStreamEvent.idl >deleted file mode 100644 >index 5f8c80387979aa9cbfcc384b308bf00cd4f303a3..0000000000000000000000000000000000000000 >--- a/Source/WebCore/Modules/mediastream/MediaStreamEvent.idl >+++ /dev/null >@@ -1,35 +0,0 @@ >-/* >- * Copyright (C) 2011 Google Inc. All rights reserved. >- * >- * Redistribution and use in source and binary forms, with or without >- * modification, are permitted provided that the following conditions >- * are met: >- * 1. Redistributions of source code must retain the above copyright >- * notice, this list of conditions and the following disclaimer. >- * 2. Redistributions in binary form must reproduce the above copyright >- * notice, this list of conditions and the following disclaimer in the >- * documentation and/or other materials provided with the distribution. >- * >- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' AND ANY >- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED >- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE >- * DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS BE LIABLE FOR ANY >- * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES >- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; >- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON >- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT >- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS >- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. >- */ >- >-[ >- Conditional=WEB_RTC, >- Constructor(DOMString type, optional MediaStreamEventInit eventInitDict), >- EnabledAtRuntime=WebRTCLegacyAPI&MediaStream, >-] interface MediaStreamEvent : Event { >- readonly attribute MediaStream? stream; >-}; >- >-dictionary MediaStreamEventInit : EventInit { >- MediaStream? stream = null; >-}; >diff --git a/Source/WebCore/Modules/mediastream/NavigatorUserMedia.idl b/Source/WebCore/Modules/mediastream/NavigatorUserMedia.idl >deleted file mode 100644 >index 5d86f3c7c48331b4d1db1fa4bb056fb75bc20201..0000000000000000000000000000000000000000 >--- a/Source/WebCore/Modules/mediastream/NavigatorUserMedia.idl >+++ /dev/null >@@ -1,36 +0,0 @@ >-/* >-* Copyright (C) 2017 Apple Inc. All rights reserved. >-* >-* Redistribution and use in source and binary forms, with or without >-* modification, are permitted provided that the following conditions >-* are met: >-* >-* 1. Redistributions of source code must retain the above copyright >-* notice, this list of conditions and the following disclaimer. >-* 2. Redistributions in binary form must reproduce the above copyright >-* notice, this list of conditions and the following disclaimer >-* in the documentation and/or other materials provided with the >-* distribution. >-* 3. Neither the name of Ericsson nor the names of its contributors >-* may be used to endorse or promote products derived from this >-* software without specific prior written permission. >-* >-* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS >-* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT >-* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR >-* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT >-* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, >-* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT >-* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, >-* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY >-* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT >-* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE >-* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. >-*/ >- >-[ >- Conditional=MEDIA_STREAM&WEB_RTC, >- EnabledAtRuntime=WebRTCLegacyAPI&MediaDevices, >-] partial interface Navigator { >- [JSBuiltin] void getUserMedia(MediaStreamConstraints constraints, NavigatorUserMediaSuccessCallback successCallback, NavigatorUserMediaErrorCallback errorCallback); >-}; >diff --git a/Source/WebCore/Modules/mediastream/NavigatorUserMedia.js b/Source/WebCore/Modules/mediastream/NavigatorUserMedia.js >deleted file mode 100644 >index 6ed4f02ea025bcd2cdc103c4ffc8bbeaf675d032..0000000000000000000000000000000000000000 >--- a/Source/WebCore/Modules/mediastream/NavigatorUserMedia.js >+++ /dev/null >@@ -1,49 +0,0 @@ >-/* >- * Copyright (C) 2015 Canon Inc. >- * Copyright (C) 2017 Apple Inc. All rights reserved. >- * >- * Redistribution and use in source and binary forms, with or without >- * modification, are permitted provided that the following conditions >- * are met: >- * 1. Redistributions of source code must retain the above copyright >- * notice, this list of conditions and the following disclaimer. >- * 2. Redistributions in binary form must reproduce the above copyright >- * notice, this list of conditions and the following disclaimer in the >- * documentation and/or other materials provided with the distribution. >- * >- * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY >- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE >- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR >- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR >- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, >- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, >- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR >- * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY >- * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT >- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE >- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. >- */ >- >-// @conditional=ENABLE(MEDIA_STREAM) >- >-function getUserMedia(options, successCallback, errorCallback) >-{ >- "use strict"; >- >- // FIXME: We should raise a DOM unsupported exception if there is no navigator and properly detect whether method is not called on a Navigator object. >- if (!(this.mediaDevices && this.mediaDevices.@getUserMedia)) >- throw @makeThisTypeError("Navigator", "getUserMedia"); >- >- if (arguments.length < 3) >- @throwTypeError("Not enough arguments"); >- >- if (!@isObject(options)) >- @throwTypeError("Argument 1 (options) to Navigator.getUserMedia must be an object"); >- >- if (typeof successCallback !== "function") >- @throwTypeError("Argument 2 ('successCallback') to Navigator.getUserMedia must be a function"); >- if (typeof errorCallback !== "function") >- @throwTypeError("Argument 3 ('errorCallback') to Navigator.getUserMedia must be a function"); >- >- this.mediaDevices.@getUserMedia(options).@then(successCallback, errorCallback); >-} >diff --git a/Source/WebCore/Modules/mediastream/PeerConnectionBackend.cpp b/Source/WebCore/Modules/mediastream/PeerConnectionBackend.cpp >index 7af46655fc1d52e9d913cd35437b6271b669fff6..28734b203f2ccc53fd16f4a9678e8657abfbbdf3 100644 >--- a/Source/WebCore/Modules/mediastream/PeerConnectionBackend.cpp >+++ b/Source/WebCore/Modules/mediastream/PeerConnectionBackend.cpp >@@ -37,6 +37,7 @@ > #include "EventNames.h" > #include "JSRTCSessionDescription.h" > #include "Logging.h" >+#include "Page.h" > #include "RTCIceCandidate.h" > #include "RTCPeerConnection.h" > #include "RTCPeerConnectionIceEvent.h" >diff --git a/Source/WebCore/Modules/mediastream/PeerConnectionBackend.h b/Source/WebCore/Modules/mediastream/PeerConnectionBackend.h >index 3a660118e8faf4f5d51359380dfc28c4c8fab7b0..f8a976b7a58f5c510b79d0979f8aa57a8dd0e43e 100644 >--- a/Source/WebCore/Modules/mediastream/PeerConnectionBackend.h >+++ b/Source/WebCore/Modules/mediastream/PeerConnectionBackend.h >@@ -98,8 +98,6 @@ public: > > virtual void getStats(MediaStreamTrack*, Ref<DeferredPromise>&&) = 0; > >- virtual Vector<RefPtr<MediaStream>> getRemoteStreams() const = 0; >- > virtual Ref<RTCRtpReceiver> createReceiver(const String& transceiverMid, const String& trackKind, const String& trackId) = 0; > virtual void replaceTrack(RTCRtpSender&, RefPtr<MediaStreamTrack>&&, DOMPromiseDeferred<void>&&) = 0; > virtual bool notifyAddedTrack(RTCRtpSender&) { return false; } >diff --git a/Source/WebCore/Modules/mediastream/RTCPeerConnection.h b/Source/WebCore/Modules/mediastream/RTCPeerConnection.h >index f46ac9a6036dfcbbef8b6956c6b62dfaaf71e5ee..427bf223eb8e419c39b2b5ef145dfa6d108d1de7 100644 >--- a/Source/WebCore/Modules/mediastream/RTCPeerConnection.h >+++ b/Source/WebCore/Modules/mediastream/RTCPeerConnection.h >@@ -126,9 +126,6 @@ public: > // 8.2 Statistics API > void getStats(MediaStreamTrack*, Ref<DeferredPromise>&&); > >- // Legacy MediaStream-based API, mostly implemented as JS built-ins >- Vector<RefPtr<MediaStream>> getRemoteStreams() const { return m_backend->getRemoteStreams(); } >- > // EventTarget > EventTargetInterface eventTargetInterface() const final { return RTCPeerConnectionEventTargetInterfaceType; } > ScriptExecutionContext* scriptExecutionContext() const final { return ActiveDOMObject::scriptExecutionContext(); } >diff --git a/Source/WebCore/Modules/mediastream/RTCPeerConnection.idl b/Source/WebCore/Modules/mediastream/RTCPeerConnection.idl >index 977338aba0c66eb9af8e8013c17bbd00fbcd3f94..1f4359b95b20401fc1de2f569ea8ef9fd814f7fb 100644 >--- a/Source/WebCore/Modules/mediastream/RTCPeerConnection.idl >+++ b/Source/WebCore/Modules/mediastream/RTCPeerConnection.idl >@@ -119,18 +119,17 @@ typedef RTCRtpTransceiverDirection RtpTransceiverDirection; > > // 5.1 RTCPeerConnection extensions > // RTP Media API extensions >- [PrivateIdentifier, PublicIdentifier] sequence<RTCRtpSender> getSenders(); >+ sequence<RTCRtpSender> getSenders(); > sequence<RTCRtpReceiver> getReceivers(); > sequence<RTCRtpTransceiver> getTransceivers(); > >- [PrivateIdentifier, PublicIdentifier, MayThrowException] RTCRtpSender addTrack(MediaStreamTrack track, MediaStream... streams); >- [PrivateIdentifier, PublicIdentifier, MayThrowException] void removeTrack(RTCRtpSender sender); >+ [MayThrowException] RTCRtpSender addTrack(MediaStreamTrack track, MediaStream... streams); >+ [MayThrowException] void removeTrack(RTCRtpSender sender); > > [MayThrowException] RTCRtpTransceiver addTransceiver((MediaStreamTrack or DOMString) track, optional RTCRtpTransceiverInit init); > > attribute EventHandler ontrack; > >- > // 6.1 Peer-to-peer data API > // FIXME 169644: missing sctp > >@@ -145,15 +144,4 @@ typedef RTCRtpTransceiverDirection RtpTransceiverDirection; > > // 9.6 Identity Provider API > // FIXME 169644: missing IdP >- >- // Legacy MediaStream API >- [JSBuiltin, EnabledAtRuntime=WebRTCLegacyAPI] sequence<MediaStream> getLocalStreams(); >- [PrivateIdentifier, PublicIdentifier, EnabledAtRuntime=WebRTCLegacyAPI] sequence<MediaStream> getRemoteStreams(); >- [JSBuiltin, EnabledAtRuntime=WebRTCLegacyAPI] MediaStream getStreamById(DOMString streamId); >- >- [JSBuiltin, EnabledAtRuntime=WebRTCLegacyAPI] void addStream(MediaStream stream); >- [JSBuiltin, EnabledAtRuntime=WebRTCLegacyAPI] void removeStream(MediaStream stream); >- >- // Legacy event handler (MediaStream-based API) >- [EnabledAtRuntime=WebRTCLegacyAPI] attribute EventHandler onaddstream; > }; >diff --git a/Source/WebCore/Modules/mediastream/RTCPeerConnection.js b/Source/WebCore/Modules/mediastream/RTCPeerConnection.js >index 8302c33a5d0c7c6ace188c2f80dd0404b2b3ed4e..c13ee1e3b2bb946d05a667a57e6d04d486294079 100644 >--- a/Source/WebCore/Modules/mediastream/RTCPeerConnection.js >+++ b/Source/WebCore/Modules/mediastream/RTCPeerConnection.js >@@ -41,85 +41,10 @@ function initializeRTCPeerConnection(configuration) > > this.@initializeWith(configuration); > @putByIdDirectPrivate(this, "operations", []); >- @putByIdDirectPrivate(this, "localStreams", []); > > return this; > } > >-function getLocalStreams() >-{ >- "use strict"; >- >- if (!@isRTCPeerConnection(this)) >- throw @makeThisTypeError("RTCPeerConnection", "getLocalStreams"); >- >- return @getByIdDirectPrivate(this, "localStreams").slice(); >-} >- >-function getStreamById(streamIdArg) >-{ >- "use strict"; >- >- if (!@isRTCPeerConnection(this)) >- throw @makeThisTypeError("RTCPeerConnection", "getStreamById"); >- >- if (arguments.length < 1) >- @throwTypeError("Not enough arguments"); >- >- const streamId = @toString(streamIdArg); >- >- return @getByIdDirectPrivate(this, "localStreams").find(stream => stream.id === streamId) >- || this.@getRemoteStreams().find(stream => stream.id === streamId) >- || null; >-} >- >-function addStream(stream) >-{ >- "use strict"; >- >- if (!@isRTCPeerConnection(this)) >- throw @makeThisTypeError("RTCPeerConnection", "addStream"); >- >- if (arguments.length < 1) >- @throwTypeError("Not enough arguments"); >- >- if (!(stream instanceof @MediaStream)) >- @throwTypeError("Argument 1 ('stream') to RTCPeerConnection.addStream must be an instance of MediaStream"); >- >- if (@getByIdDirectPrivate(this, "localStreams").find(localStream => localStream.id === stream.id)) >- return; >- >- @getByIdDirectPrivate(this, "localStreams").@push(stream); >- stream.@getTracks().forEach(track => this.@addTrack(track, stream)); >-} >- >-function removeStream(stream) >-{ >- "use strict"; >- >- if (!@isRTCPeerConnection(this)) >- throw @makeThisTypeError("RTCPeerConnection", "removeStream"); >- >- if (arguments.length < 1) >- @throwTypeError("Not enough arguments"); >- >- if (!(stream instanceof @MediaStream)) >- @throwTypeError("Argument 1 ('stream') to RTCPeerConnection.removeStream must be an instance of MediaStream"); >- >- const indexOfStreamToRemove = @getByIdDirectPrivate(this, "localStreams").findIndex(localStream => localStream.id === stream.id); >- if (indexOfStreamToRemove === -1) >- return; >- >- const senders = this.@getSenders(); >- @getByIdDirectPrivate(this, "localStreams")[indexOfStreamToRemove].@getTracks().forEach(track => { >- const senderForTrack = senders.find(sender => sender.track && sender.track.id === track.id); >- if (senderForTrack) >- this.@removeTrack(senderForTrack); >- }); >- >- @getByIdDirectPrivate(this, "localStreams").splice(indexOfStreamToRemove, 1); >-} >- > function createOffer() > { > "use strict"; >@@ -130,17 +55,9 @@ function createOffer() > const peerConnection = this; > > return @callbacksAndDictionaryOverload(arguments, "createOffer", function (options) { >- // Promise mode > return @enqueueOperation(peerConnection, function () { > return peerConnection.@queuedCreateOffer(options); > }); >- }, function (successCallback, errorCallback, options) { >- // Legacy callbacks mode >- @enqueueOperation(peerConnection, function () { >- return peerConnection.@queuedCreateOffer(options).@then(successCallback, errorCallback); >- }); >- >- return @Promise.@resolve(@undefined); > }); > } > >@@ -154,17 +71,9 @@ function createAnswer() > const peerConnection = this; > > return @callbacksAndDictionaryOverload(arguments, "createAnswer", function (options) { >- // Promise mode > return @enqueueOperation(peerConnection, function () { > return peerConnection.@queuedCreateAnswer(options); > }); >- }, function (successCallback, errorCallback, options) { >- // Legacy callbacks mode >- @enqueueOperation(peerConnection, function () { >- return peerConnection.@queuedCreateAnswer(options).@then(successCallback, errorCallback); >- }); >- >- return @Promise.@resolve(@undefined); > }); > } > >@@ -185,17 +94,9 @@ function setLocalDescription() > "maybeDictionary": "true" > }; > return @objectAndCallbacksOverload(arguments, "setLocalDescription", objectInfo, function (description) { >- // Promise mode > return @enqueueOperation(peerConnection, function () { > return peerConnection.@queuedSetLocalDescription(description); > }); >- }, function (description, successCallback, errorCallback) { >- // Legacy callbacks mode >- @enqueueOperation(peerConnection, function () { >- return peerConnection.@queuedSetLocalDescription(description).@then(successCallback, errorCallback); >- }); >- >- return @Promise.@resolve(@undefined); > }); > } > >@@ -216,17 +117,9 @@ function setRemoteDescription() > "maybeDictionary": "true" > }; > return @objectAndCallbacksOverload(arguments, "setRemoteDescription", objectInfo, function (description) { >- // Promise mode > return @enqueueOperation(peerConnection, function () { > return peerConnection.@queuedSetRemoteDescription(description); > }); >- }, function (description, successCallback, errorCallback) { >- // Legacy callbacks mode >- @enqueueOperation(peerConnection, function () { >- return peerConnection.@queuedSetRemoteDescription(description).@then(successCallback, errorCallback); >- }); >- >- return @Promise.@resolve(@undefined); > }); > } > >@@ -250,16 +143,8 @@ function addIceCandidate(candidate) > "defaultsToNull" : "true" > }; > return @objectAndCallbacksOverload(arguments, "addIceCandidate", objectInfo, function (candidate) { >- // Promise mode > return @enqueueOperation(peerConnection, function () { > return peerConnection.@queuedAddIceCandidate(candidate); > }); >- }, function (candidate, successCallback, errorCallback) { >- // Legacy callbacks mode >- @enqueueOperation(peerConnection, function () { >- return peerConnection.@queuedAddIceCandidate(candidate).@then(successCallback, errorCallback); >- }); >- >- return @Promise.@resolve(@undefined); > }); > } >diff --git a/Source/WebCore/Modules/mediastream/RTCPeerConnectionInternals.js b/Source/WebCore/Modules/mediastream/RTCPeerConnectionInternals.js >index 3bc1d7b4777a5e99ec548c2d63288329c00d6c8a..411dcc91f01ec9ac62b2c52ad8f1ea44f6b1441a 100644 >--- a/Source/WebCore/Modules/mediastream/RTCPeerConnectionInternals.js >+++ b/Source/WebCore/Modules/mediastream/RTCPeerConnectionInternals.js >@@ -54,7 +54,7 @@ function enqueueOperation(peerConnection, operation) > }); > } > >-function objectAndCallbacksOverload(args, functionName, objectInfo, promiseMode, legacyMode) >+function objectAndCallbacksOverload(args, functionName, objectInfo, promiseMode) > { > "use strict"; > >@@ -80,53 +80,18 @@ function objectAndCallbacksOverload(args, functionName, objectInfo, promiseMode, > if (!objectArgOk) > return @Promise.@reject(new @TypeError(`Argument 1 ('${objectInfo.argName}') to RTCPeerConnection.${functionName} must be an instance of ${objectInfo.argType}`)); > >- if (!@webRTCLegacyAPIEnabled() || argsCount === 1) >- return promiseMode(objectArg); >- >- // More than one argument: Legacy mode >- if (argsCount < 3) >- return @Promise.@reject(new @TypeError("Not enough arguments")); >- >- const successCallback = args[1]; >- const errorCallback = args[2]; >- >- if (typeof successCallback !== "function") >- return @Promise.@reject(new @TypeError(`Argument 2 ('successCallback') to RTCPeerConnection.${functionName} must be a function`)); >- >- if (typeof errorCallback !== "function") >- return @Promise.@reject(new @TypeError(`Argument 3 ('errorCallback') to RTCPeerConnection.${functionName} must be a function`)); >- >- return legacyMode(objectArg, successCallback, errorCallback); >+ return promiseMode(objectArg); > } > >-function callbacksAndDictionaryOverload(args, functionName, promiseMode, legacyMode) >+function callbacksAndDictionaryOverload(args, functionName, promiseMode) > { > "use strict"; > >- if (!@webRTCLegacyAPIEnabled() || args.length <= 1) { >- // Zero or one arguments: Promise mode >- const options = args[0]; >- if (args.length && !@isDictionary(options)) >- return @Promise.@reject(new @TypeError(`Argument 1 ('options') to RTCPeerConnection.${functionName} must be a dictionary`)); >- >- return promiseMode(options); >- } >- >- // More than one argument: Legacy mode >- const successCallback = args[0]; >- const errorCallback = args[1]; >- const options = args[2]; >- >- if (typeof successCallback !== "function") >- return @Promise.@reject(new @TypeError(`Argument 1 ('successCallback') to RTCPeerConnection.${functionName} must be a function`)); >- >- if (typeof errorCallback !== "function") >- return @Promise.@reject(new @TypeError(`Argument 2 ('errorCallback') to RTCPeerConnection.${functionName} must be a function`)); >- >- if (args.length > 2 && !@isDictionary(options)) >- return @Promise.@reject(new @TypeError(`Argument 3 ('options') to RTCPeerConnection.${functionName} must be a dictionary`)); >+ const options = args[0]; >+ if (args.length && !@isDictionary(options)) >+ return @Promise.@reject(new @TypeError(`Argument 1 ('options') to RTCPeerConnection.${functionName} must be a dictionary`)); > >- return legacyMode(successCallback, errorCallback, args[2]); >+ return promiseMode(options); > } > > function isRTCPeerConnection(connection) >diff --git a/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp b/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp >index 8b35f6557fe18cfcb6bbb3ccbc79c547b7d630e2..0ae30342f30a118f592e1dd5ec1cb1b82cfe8d46 100644 >--- a/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp >+++ b/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp >@@ -33,7 +33,6 @@ > #include "LibWebRTCPeerConnectionBackend.h" > #include "LibWebRTCProvider.h" > #include "Logging.h" >-#include "MediaStreamEvent.h" > #include "NotImplemented.h" > #include "Performance.h" > #include "PlatformStrategies.h" >@@ -629,22 +628,13 @@ MediaStream& LibWebRTCMediaEndpoint::mediaStreamFromRTCStream(webrtc::MediaStrea > { > auto mediaStream = m_streams.ensure(&rtcStream, [&rtcStream, this] { > auto label = rtcStream.id(); >- auto stream = MediaStream::create(*m_peerConnectionBackend.connection().scriptExecutionContext(), MediaStreamPrivate::create({ }, fromStdString(label))); >- auto streamPointer = stream.ptr(); >- m_peerConnectionBackend.addRemoteStream(WTFMove(stream)); >- return streamPointer; >+ return MediaStream::create(*m_peerConnectionBackend.connection().scriptExecutionContext(), MediaStreamPrivate::create({ }, fromStdString(label))); > }); > return *mediaStream.iterator->value; > } > >-void LibWebRTCMediaEndpoint::addRemoteStream(webrtc::MediaStreamInterface& rtcStream) >+void LibWebRTCMediaEndpoint::addRemoteStream(webrtc::MediaStreamInterface&) > { >- if (!RuntimeEnabledFeatures::sharedFeatures().webRTCLegacyAPIEnabled()) >- return; >- >- auto& mediaStream = mediaStreamFromRTCStream(rtcStream); >- m_peerConnectionBackend.connection().fireEvent(MediaStreamEvent::create(eventNames().addstreamEvent, >- Event::CanBubble::No, Event::IsCancelable::No, &mediaStream)); > } > > class RTCRtpReceiverBackend final : public RTCRtpReceiver::Backend { >@@ -703,9 +693,8 @@ void LibWebRTCMediaEndpoint::addRemoteTrack(rtc::scoped_refptr<webrtc::RtpReceiv > > void LibWebRTCMediaEndpoint::removeRemoteStream(webrtc::MediaStreamInterface& rtcStream) > { >- auto* mediaStream = m_streams.take(&rtcStream); >- if (mediaStream) >- m_peerConnectionBackend.removeRemoteStream(mediaStream); >+ bool removed = m_streams.remove(&rtcStream); >+ ASSERT_UNUSED(removed, removed); > } > > void LibWebRTCMediaEndpoint::OnAddStream(rtc::scoped_refptr<webrtc::MediaStreamInterface> stream) >diff --git a/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.h b/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.h >index 4dafaf4f4f64c2cdb2654244eb0d41c83a7a8081..52331681bf78fa267b5d1db0de4e21a263cf3659 100644 >--- a/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.h >+++ b/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.h >@@ -217,7 +217,7 @@ private: > CreateSessionDescriptionObserver m_createSessionDescriptionObserver; > SetLocalSessionDescriptionObserver m_setLocalSessionDescriptionObserver; > SetRemoteSessionDescriptionObserver m_setRemoteSessionDescriptionObserver; >- HashMap<webrtc::MediaStreamInterface*, MediaStream*> m_streams; >+ HashMap<webrtc::MediaStreamInterface*, RefPtr<MediaStream>> m_streams; > HashMap<RTCRtpSender*, rtc::scoped_refptr<webrtc::RtpSenderInterface>> m_senders; > > bool m_isInitiator { false }; >diff --git a/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.cpp b/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.cpp >index b811497dd2db20ca4824be46a439bb92dfcfe020..22ba150c4b464dc29abf622e79b19f6d8fc3217c 100644 >--- a/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.cpp >+++ b/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.cpp >@@ -201,7 +201,6 @@ void LibWebRTCPeerConnectionBackend::doStop() > m_audioSources.clear(); > m_videoSources.clear(); > m_statsPromises.clear(); >- m_remoteStreams.clear(); > m_pendingReceivers.clear(); > } > >@@ -360,18 +359,6 @@ void LibWebRTCPeerConnectionBackend::notifyRemovedTrack(RTCRtpSender& sender) > m_endpoint->removeTrack(sender); > } > >-void LibWebRTCPeerConnectionBackend::removeRemoteStream(MediaStream* mediaStream) >-{ >- m_remoteStreams.removeFirstMatching([mediaStream](const auto& item) { >- return item.get() == mediaStream; >- }); >-} >- >-void LibWebRTCPeerConnectionBackend::addRemoteStream(Ref<MediaStream>&& mediaStream) >-{ >- m_remoteStreams.append(WTFMove(mediaStream)); >-} >- > template<typename Source> > static inline bool updateTrackSource(Source& source, MediaStreamTrack* track) > { >diff --git a/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.h b/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.h >index 1745b24d1ec703649fedce0737148b035b224e88..fa0f0137095252612f4b0eb6116484d14fa33101 100644 >--- a/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.h >+++ b/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.h >@@ -88,10 +88,6 @@ private: > void getStatsSucceeded(const DeferredPromise&, Ref<RTCStatsReport>&&); > void getStatsFailed(const DeferredPromise&, Exception&&); > >- Vector<RefPtr<MediaStream>> getRemoteStreams() const final { return m_remoteStreams; } >- void removeRemoteStream(MediaStream*); >- void addRemoteStream(Ref<MediaStream>&&); >- > bool notifyAddedTrack(RTCRtpSender&) final; > void notifyRemovedTrack(RTCRtpSender&) final; > >@@ -113,8 +109,6 @@ private: > bool m_isLocalDescriptionSet { false }; > bool m_isRemoteDescriptionSet { false }; > >- // FIXME: Make m_remoteStreams a Vector of Ref. >- Vector<RefPtr<MediaStream>> m_remoteStreams; > Vector<std::unique_ptr<webrtc::IceCandidateInterface>> m_pendingCandidates; > Vector<Ref<RealtimeOutgoingAudioSource>> m_audioSources; > Vector<Ref<RealtimeOutgoingVideoSource>> m_videoSources; >diff --git a/Source/WebCore/Sources.txt b/Source/WebCore/Sources.txt >index 80a74e4b506f7e94a583d37458c8aab0d2debb0a..af5f3a7c28b060c62fc017f15eb4c1a4f2c0c9ba 100644 >--- a/Source/WebCore/Sources.txt >+++ b/Source/WebCore/Sources.txt >@@ -159,7 +159,6 @@ Modules/mediastream/MediaDevices.cpp > Modules/mediastream/MediaDevicesEnumerationRequest.cpp > Modules/mediastream/MediaDevicesRequest.cpp > Modules/mediastream/MediaStream.cpp >-Modules/mediastream/MediaStreamEvent.cpp > Modules/mediastream/MediaStreamRegistry.cpp > Modules/mediastream/MediaStreamTrack.cpp > Modules/mediastream/MediaStreamTrackEvent.cpp >@@ -2757,7 +2756,6 @@ JSMediaSource.cpp > JSMediaStream.cpp > JSMediaStreamAudioDestinationNode.cpp > JSMediaStreamAudioSourceNode.cpp >-JSMediaStreamEvent.cpp > JSMediaStreamTrack.cpp > JSMediaStreamTrackEvent.cpp > JSMediaTrackConstraints.cpp >@@ -2784,7 +2782,6 @@ JSNavigatorMediaCapabilities.cpp > JSNavigatorMediaDevices.cpp > JSNavigatorOnLine.cpp > JSNavigatorServiceWorker.cpp >-JSNavigatorUserMedia.cpp > JSNavigatorWebDriver.cpp > JSNavigatorWebVR.cpp > JSNode.cpp >diff --git a/Source/WebCore/WebCore.xcodeproj/project.pbxproj b/Source/WebCore/WebCore.xcodeproj/project.pbxproj >index b6df748a6d190485b18c3d58cb5183bbadb82f89..f9805db13dce32d0cfa219097fac9acdc61d1f41 100644 >--- a/Source/WebCore/WebCore.xcodeproj/project.pbxproj >+++ b/Source/WebCore/WebCore.xcodeproj/project.pbxproj >@@ -101,7 +101,6 @@ > 07277E4D17D018CC0015534D /* JSMediaStream.h in Headers */ = {isa = PBXBuildFile; fileRef = 07277E4117D018CC0015534D /* JSMediaStream.h */; }; > 07277E4D17D018CC0015534E /* JSCanvasCaptureMediaStreamTrack.h in Headers */ = {isa = PBXBuildFile; fileRef = 07277E4117D018CC0015534E /* JSCanvasCaptureMediaStreamTrack.h */; }; > 07277E4F17D018CC0015534D /* JSMediaStreamAudioDestinationNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 07277E4317D018CC0015534D /* JSMediaStreamAudioDestinationNode.h */; }; >- 07277E5117D018CC0015534D /* JSMediaStreamEvent.h in Headers */ = {isa = PBXBuildFile; fileRef = 07277E4517D018CC0015534D /* JSMediaStreamEvent.h */; }; > 07277E5317D018CC0015534D /* JSMediaStreamTrack.h in Headers */ = {isa = PBXBuildFile; fileRef = 07277E4717D018CC0015534D /* JSMediaStreamTrack.h */; }; > 07277E5517D018CC0015534D /* JSMediaStreamTrackEvent.h in Headers */ = {isa = PBXBuildFile; fileRef = 07277E4917D018CC0015534D /* JSMediaStreamTrackEvent.h */; }; > 072A70401D6E8F6200DF0AFC /* OverconstrainedErrorEvent.h in Headers */ = {isa = PBXBuildFile; fileRef = 072A703E1D6E8F6200DF0AFC /* OverconstrainedErrorEvent.h */; }; >@@ -119,7 +118,6 @@ > 073B87671E4385AC0071C0EC /* AudioSampleBufferList.h in Headers */ = {isa = PBXBuildFile; fileRef = 073B87631E43859D0071C0EC /* AudioSampleBufferList.h */; }; > 073B87691E4385AC0071C0EC /* AudioSampleDataSource.h in Headers */ = {isa = PBXBuildFile; fileRef = 073B87651E43859D0071C0EC /* AudioSampleDataSource.h */; }; > 073BDC051F68436100EE34ED /* TrackPrivateBase.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 076E11BE1F683E0D00177395 /* TrackPrivateBase.cpp */; }; >- 073BE34117D17E01002BD431 /* JSNavigatorUserMedia.h in Headers */ = {isa = PBXBuildFile; fileRef = 073BE33F17D17E01002BD431 /* JSNavigatorUserMedia.h */; settings = {ATTRIBUTES = (Private, ); }; }; > 074E82BB18A69F0E007EF54C /* PlatformTimeRanges.h in Headers */ = {isa = PBXBuildFile; fileRef = 074E82B918A69F0E007EF54C /* PlatformTimeRanges.h */; settings = {ATTRIBUTES = (Private, ); }; }; > 0753860214489E9800B78452 /* CachedTextTrack.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0753860014489E9800B78452 /* CachedTextTrack.cpp */; }; > 0753860314489E9800B78452 /* CachedTextTrack.h in Headers */ = {isa = PBXBuildFile; fileRef = 0753860114489E9800B78452 /* CachedTextTrack.h */; }; >@@ -139,7 +137,6 @@ > 07846385145B1B8E00A58DF1 /* JSTrackCustom.h in Headers */ = {isa = PBXBuildFile; fileRef = 07846384145B1B8E00A58DF1 /* JSTrackCustom.h */; }; > 0787C46A1BFBDF6F006DCD7F /* JSMediaTrackSupportedConstraints.h in Headers */ = {isa = PBXBuildFile; fileRef = 0787C4681BFBDF6F006DCD7F /* JSMediaTrackSupportedConstraints.h */; }; > 078E091517D14D1C00420AA1 /* MediaStream.h in Headers */ = {isa = PBXBuildFile; fileRef = 07221B4D17CEC32700848E51 /* MediaStream.h */; }; >- 078E091617D14D1C00420AA1 /* MediaStreamEvent.h in Headers */ = {isa = PBXBuildFile; fileRef = 07221B5017CEC32700848E51 /* MediaStreamEvent.h */; }; > 078E091717D14D1C00420AA1 /* MediaStreamRegistry.h in Headers */ = {isa = PBXBuildFile; fileRef = 07221B5317CEC32700848E51 /* MediaStreamRegistry.h */; settings = {ATTRIBUTES = (Private, ); }; }; > 078E091817D14D1C00420AA1 /* MediaStreamTrack.h in Headers */ = {isa = PBXBuildFile; fileRef = 07221B5517CEC32700848E51 /* MediaStreamTrack.h */; settings = {ATTRIBUTES = (Private, ); }; }; > 078E091917D14D1C00420AA1 /* MediaStreamTrackEvent.h in Headers */ = {isa = PBXBuildFile; fileRef = 07221B5817CEC32700848E51 /* MediaStreamTrackEvent.h */; settings = {ATTRIBUTES = (Private, ); }; }; >@@ -4055,8 +4052,8 @@ > CDE595951BF16DF300A1CBE8 /* CDMSessionAVContentKeySession.mm in Sources */ = {isa = PBXBuildFile; fileRef = CDE595931BF166AD00A1CBE8 /* CDMSessionAVContentKeySession.mm */; }; > CDE595971BF26E2100A1CBE8 /* CDMSessionMediaSourceAVFObjC.h in Headers */ = {isa = PBXBuildFile; fileRef = CDE595961BF26E2100A1CBE8 /* CDMSessionMediaSourceAVFObjC.h */; }; > CDE5959D1BF2757100A1CBE8 /* CDMSessionMediaSourceAVFObjC.mm in Sources */ = {isa = PBXBuildFile; fileRef = CDE5959C1BF2757100A1CBE8 /* CDMSessionMediaSourceAVFObjC.mm */; }; >- CDE667A41E4BBF1500E8154A /* WebAudioBufferList.cpp in Sources */ = {isa = PBXBuildFile; fileRef = CDE667A21E4BBF1500E8154A /* WebAudioBufferList.cpp */; }; >- CDE667A51E4BBF1500E8154A /* WebAudioBufferList.h in Headers */ = {isa = PBXBuildFile; fileRef = CDE667A31E4BBF1500E8154A /* WebAudioBufferList.h */; settings = {ATTRIBUTES = (Private, ); }; }; >+ CDE667A41E4BBF1500E8154A /* cocoa/WebAudioBufferList.cpp in Sources */ = {isa = PBXBuildFile; fileRef = CDE667A21E4BBF1500E8154A /* cocoa/WebAudioBufferList.cpp */; }; >+ CDE667A51E4BBF1500E8154A /* cocoa/WebAudioBufferList.h in Headers */ = {isa = PBXBuildFile; fileRef = CDE667A31E4BBF1500E8154A /* cocoa/WebAudioBufferList.h */; settings = {ATTRIBUTES = (Private, ); }; }; > CDE7FC45181904B1002BBB77 /* OrderIterator.h in Headers */ = {isa = PBXBuildFile; fileRef = CDE7FC43181904B1002BBB77 /* OrderIterator.h */; settings = {ATTRIBUTES = (Private, ); }; }; > CDE83DB2183C44060031EAA3 /* VideoPlaybackQuality.h in Headers */ = {isa = PBXBuildFile; fileRef = CDE83DB0183C44060031EAA3 /* VideoPlaybackQuality.h */; }; > CDE8B5EC1A69777300B4B66A /* LegacyCDMPrivateClearKey.cpp in Sources */ = {isa = PBXBuildFile; fileRef = CDE8B5EA1A69777300B4B66A /* LegacyCDMPrivateClearKey.cpp */; }; >@@ -5218,9 +5215,6 @@ > 07221B4C17CEC32700848E51 /* MediaStream.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = MediaStream.cpp; sourceTree = "<group>"; }; > 07221B4D17CEC32700848E51 /* MediaStream.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MediaStream.h; sourceTree = "<group>"; }; > 07221B4E17CEC32700848E51 /* MediaStream.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = MediaStream.idl; sourceTree = "<group>"; }; >- 07221B4F17CEC32700848E51 /* MediaStreamEvent.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = MediaStreamEvent.cpp; sourceTree = "<group>"; }; >- 07221B5017CEC32700848E51 /* MediaStreamEvent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MediaStreamEvent.h; sourceTree = "<group>"; }; >- 07221B5117CEC32700848E51 /* MediaStreamEvent.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = MediaStreamEvent.idl; sourceTree = "<group>"; }; > 07221B5217CEC32700848E51 /* MediaStreamRegistry.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = MediaStreamRegistry.cpp; sourceTree = "<group>"; }; > 07221B5317CEC32700848E51 /* MediaStreamRegistry.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MediaStreamRegistry.h; sourceTree = "<group>"; }; > 07221B5417CEC32700848E51 /* MediaStreamTrack.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = MediaStreamTrack.cpp; sourceTree = "<group>"; }; >@@ -5229,7 +5223,6 @@ > 07221B5717CEC32700848E51 /* MediaStreamTrackEvent.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = MediaStreamTrackEvent.cpp; sourceTree = "<group>"; }; > 07221B5817CEC32700848E51 /* MediaStreamTrackEvent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MediaStreamTrackEvent.h; sourceTree = "<group>"; }; > 07221B5917CEC32700848E51 /* MediaStreamTrackEvent.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = MediaStreamTrackEvent.idl; sourceTree = "<group>"; }; >- 07221B5C17CEC32700848E51 /* NavigatorUserMedia.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = NavigatorUserMedia.idl; sourceTree = "<group>"; }; > 07221B6317CEC32700848E51 /* RTCDataChannel.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = RTCDataChannel.cpp; sourceTree = "<group>"; }; > 07221B6417CEC32700848E51 /* RTCDataChannel.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RTCDataChannel.h; sourceTree = "<group>"; }; > 07221B6517CEC32700848E51 /* RTCDataChannel.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = RTCDataChannel.idl; sourceTree = "<group>"; }; >@@ -5280,8 +5273,6 @@ > 07277E4117D018CC0015534E /* JSCanvasCaptureMediaStreamTrack.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSCanvasCaptureMediaStreamTrack.h; sourceTree = "<group>"; }; > 07277E4217D018CC0015534D /* JSMediaStreamAudioDestinationNode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSMediaStreamAudioDestinationNode.cpp; sourceTree = "<group>"; }; > 07277E4317D018CC0015534D /* JSMediaStreamAudioDestinationNode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSMediaStreamAudioDestinationNode.h; sourceTree = "<group>"; }; >- 07277E4417D018CC0015534D /* JSMediaStreamEvent.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSMediaStreamEvent.cpp; sourceTree = "<group>"; }; >- 07277E4517D018CC0015534D /* JSMediaStreamEvent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSMediaStreamEvent.h; sourceTree = "<group>"; }; > 07277E4617D018CC0015534D /* JSMediaStreamTrack.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSMediaStreamTrack.cpp; sourceTree = "<group>"; }; > 07277E4717D018CC0015534D /* JSMediaStreamTrack.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSMediaStreamTrack.h; sourceTree = "<group>"; }; > 07277E4817D018CC0015534D /* JSMediaStreamTrackEvent.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSMediaStreamTrackEvent.cpp; sourceTree = "<group>"; }; >@@ -5316,8 +5307,6 @@ > 073B87631E43859D0071C0EC /* AudioSampleBufferList.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AudioSampleBufferList.h; sourceTree = "<group>"; }; > 073B87641E43859D0071C0EC /* AudioSampleDataSource.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = AudioSampleDataSource.mm; sourceTree = "<group>"; }; > 073B87651E43859D0071C0EC /* AudioSampleDataSource.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AudioSampleDataSource.h; sourceTree = "<group>"; }; >- 073BE33E17D17E01002BD431 /* JSNavigatorUserMedia.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSNavigatorUserMedia.cpp; sourceTree = "<group>"; }; >- 073BE33F17D17E01002BD431 /* JSNavigatorUserMedia.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSNavigatorUserMedia.h; sourceTree = "<group>"; }; > 0744ECEB1E0C4AE5000D0944 /* MockRealtimeAudioSourceMac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MockRealtimeAudioSourceMac.h; sourceTree = "<group>"; }; > 0744ECEC1E0C4AE5000D0944 /* MockRealtimeAudioSourceMac.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = MockRealtimeAudioSourceMac.mm; sourceTree = "<group>"; }; > 074E82B818A69F0E007EF54C /* PlatformTimeRanges.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = PlatformTimeRanges.cpp; sourceTree = "<group>"; }; >@@ -7072,7 +7061,7 @@ > 339B5B62131DAA3200F48D02 /* CookiesStrategy.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CookiesStrategy.h; sourceTree = "<group>"; }; > 3662F984047CEDBE5DDDAFAA /* RenderMathMLMenclose.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = RenderMathMLMenclose.cpp; sourceTree = "<group>"; }; > 37119A7920CCB610002C6DC9 /* WebKitTargetConditionals.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = WebKitTargetConditionals.xcconfig; sourceTree = "<group>"; }; >- 3717D7E517ECC3A6003C276D /* extract-localizable-strings.pl */ = {isa = PBXFileReference; lastKnownFileType = text.script.perl; name = extract-localizable-strings.pl; path = "Scripts/extract-localizable-strings.pl"; sourceTree = "<group>"; }; >+ 3717D7E517ECC3A6003C276D /* extract-localizable-strings.pl */ = {isa = PBXFileReference; lastKnownFileType = text.script.perl; name = "extract-localizable-strings.pl"; path = "Scripts/extract-localizable-strings.pl"; sourceTree = "<group>"; }; > 371A67CA11C6C7DB00047B8B /* HyphenationCF.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = HyphenationCF.cpp; sourceTree = "<group>"; }; > 371E65CB13661EDC00BEEDB0 /* PageSerializer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PageSerializer.h; sourceTree = "<group>"; }; > 371E65CD13661EED00BEEDB0 /* PageSerializer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = PageSerializer.cpp; sourceTree = "<group>"; }; >@@ -7290,7 +7279,6 @@ > 419BC2DC1685329900D64D6D /* VisitedLinkState.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = VisitedLinkState.cpp; sourceTree = "<group>"; }; > 419BC2DD1685329900D64D6D /* VisitedLinkState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VisitedLinkState.h; sourceTree = "<group>"; }; > 419BE7521BC7F3DB00E1C85B /* WebCoreBuiltinNames.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebCoreBuiltinNames.h; sourceTree = "<group>"; }; >- 419BE75A1BCBD3ED00E1C85B /* NavigatorUserMedia.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; path = NavigatorUserMedia.js; sourceTree = "<group>"; }; > 419FAFAD1ABABCD5005B3572 /* ReadableStreamBYOBReader.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = ReadableStreamBYOBReader.idl; sourceTree = "<group>"; }; > 419FAFAD1ABABCD5005B828B /* ReadableStreamDefaultReader.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = ReadableStreamDefaultReader.idl; sourceTree = "<group>"; }; > 41A023ED1A39DB7900F722CF /* ReadableStream.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = ReadableStream.idl; sourceTree = "<group>"; }; >@@ -13357,8 +13345,8 @@ > CDE5959C1BF2757100A1CBE8 /* CDMSessionMediaSourceAVFObjC.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = CDMSessionMediaSourceAVFObjC.mm; sourceTree = "<group>"; }; > CDE6560E17CA6E7600526BA7 /* mediaControlsApple.js */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.javascript; path = mediaControlsApple.js; sourceTree = "<group>"; }; > CDE667A11E4BBA4D00E8154A /* PlatformAudioData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PlatformAudioData.h; sourceTree = "<group>"; }; >- CDE667A21E4BBF1500E8154A /* WebAudioBufferList.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = cocoa/WebAudioBufferList.cpp; sourceTree = "<group>"; }; >- CDE667A31E4BBF1500E8154A /* WebAudioBufferList.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cocoa/WebAudioBufferList.h; sourceTree = "<group>"; }; >+ CDE667A21E4BBF1500E8154A /* cocoa/WebAudioBufferList.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = cocoa/WebAudioBufferList.cpp; sourceTree = "<group>"; }; >+ CDE667A31E4BBF1500E8154A /* cocoa/WebAudioBufferList.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = cocoa/WebAudioBufferList.h; sourceTree = "<group>"; }; > CDE7FC42181904B1002BBB77 /* OrderIterator.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = OrderIterator.cpp; sourceTree = "<group>"; }; > CDE7FC43181904B1002BBB77 /* OrderIterator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = OrderIterator.h; sourceTree = "<group>"; }; > CDE83DAF183C44060031EAA3 /* VideoPlaybackQuality.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = VideoPlaybackQuality.cpp; sourceTree = "<group>"; }; >@@ -15037,9 +15025,6 @@ > 07221B4C17CEC32700848E51 /* MediaStream.cpp */, > 07221B4D17CEC32700848E51 /* MediaStream.h */, > 07221B4E17CEC32700848E51 /* MediaStream.idl */, >- 07221B4F17CEC32700848E51 /* MediaStreamEvent.cpp */, >- 07221B5017CEC32700848E51 /* MediaStreamEvent.h */, >- 07221B5117CEC32700848E51 /* MediaStreamEvent.idl */, > 07221B5217CEC32700848E51 /* MediaStreamRegistry.cpp */, > 07221B5317CEC32700848E51 /* MediaStreamRegistry.h */, > 07221B5417CEC32700848E51 /* MediaStreamTrack.cpp */, >@@ -15056,8 +15041,6 @@ > 5EA725CA1ACABCB500EAD17B /* NavigatorMediaDevices.cpp */, > 5EA725CB1ACABCB500EAD17B /* NavigatorMediaDevices.h */, > 5EA725CC1ACABCB500EAD17B /* NavigatorMediaDevices.idl */, >- 07221B5C17CEC32700848E51 /* NavigatorUserMedia.idl */, >- 419BE75A1BCBD3ED00E1C85B /* NavigatorUserMedia.js */, > 0704A4051D6DE9F10086DCDB /* OverconstrainedError.h */, > 0704A4031D6DE9F10086DCDB /* OverconstrainedError.idl */, > 072A703E1D6E8F6200DF0AFC /* OverconstrainedErrorEvent.h */, >@@ -15310,8 +15293,6 @@ > 07277E4117D018CC0015534D /* JSMediaStream.h */, > 07277E4217D018CC0015534D /* JSMediaStreamAudioDestinationNode.cpp */, > 07277E4317D018CC0015534D /* JSMediaStreamAudioDestinationNode.h */, >- 07277E4417D018CC0015534D /* JSMediaStreamEvent.cpp */, >- 07277E4517D018CC0015534D /* JSMediaStreamEvent.h */, > 07277E4617D018CC0015534D /* JSMediaStreamTrack.cpp */, > 07277E4717D018CC0015534D /* JSMediaStreamTrack.h */, > 07277E4817D018CC0015534D /* JSMediaStreamTrackEvent.cpp */, >@@ -15320,8 +15301,6 @@ > 932CC0D11DFFD667004C0F9F /* JSMediaTrackConstraints.h */, > 0787C4671BFBDF6F006DCD7F /* JSMediaTrackSupportedConstraints.cpp */, > 0787C4681BFBDF6F006DCD7F /* JSMediaTrackSupportedConstraints.h */, >- 073BE33E17D17E01002BD431 /* JSNavigatorUserMedia.cpp */, >- 073BE33F17D17E01002BD431 /* JSNavigatorUserMedia.h */, > 0704A4091D6DFC690086DCDB /* JSOverconstrainedError.cpp */, > 0704A40A1D6DFC690086DCDB /* JSOverconstrainedError.h */, > 0704A4131D6F39FB0086DCDB /* JSOverconstrainedErrorEvent.cpp */, >@@ -24551,10 +24530,10 @@ > CD669D651D232DF4004D1866 /* cocoa */ = { > isa = PBXGroup; > children = ( >+ CDE667A21E4BBF1500E8154A /* cocoa/WebAudioBufferList.cpp */, >+ CDE667A31E4BBF1500E8154A /* cocoa/WebAudioBufferList.h */, > CD669D661D232DFF004D1866 /* MediaSessionManagerCocoa.cpp */, > CD227E362113AEFA00D285AF /* MediaSessionManagerCocoa.h */, >- CDE667A21E4BBF1500E8154A /* WebAudioBufferList.cpp */, >- CDE667A31E4BBF1500E8154A /* WebAudioBufferList.h */, > ); > name = cocoa; > sourceTree = "<group>"; >@@ -27264,6 +27243,7 @@ > FB92DF4B15FED08700994433 /* ClipPathOperation.h in Headers */, > 580371621A66F00A00BAF519 /* ClipRect.h in Headers */, > 97AABD1314FA09D5007457AE /* CloseEvent.h in Headers */, >+ CDE667A51E4BBF1500E8154A /* cocoa/WebAudioBufferList.h in Headers */, > C0C054CB1118C8E400CE2636 /* CodeGenerator.pm in Headers */, > BC5EB5DF0E81B9AB00B25965 /* CollapsedBorderValue.h in Headers */, > E425A49A18292B840020CFCF /* CollectionIndexCache.h in Headers */, >@@ -28725,7 +28705,6 @@ > 07277E4D17D018CC0015534D /* JSMediaStream.h in Headers */, > 07277E4F17D018CC0015534D /* JSMediaStreamAudioDestinationNode.h in Headers */, > FDBD480D159BC6870093EB4F /* JSMediaStreamAudioSourceNode.h in Headers */, >- 07277E5117D018CC0015534D /* JSMediaStreamEvent.h in Headers */, > 07277E5317D018CC0015534D /* JSMediaStreamTrack.h in Headers */, > 07277E5517D018CC0015534D /* JSMediaStreamTrackEvent.h in Headers */, > 932CC0D51DFFD667004C0F9F /* JSMediaTrackConstraints.h in Headers */, >@@ -28744,7 +28723,6 @@ > A9D247F80D757E3400FDF959 /* JSNavigator.h in Headers */, > 77D510251ED74B5800DA4C87 /* JSNavigatorCredentials.h in Headers */, > 51F886C01F32923100C193EF /* JSNavigatorServiceWorker.h in Headers */, >- 073BE34117D17E01002BD431 /* JSNavigatorUserMedia.h in Headers */, > BC9439C3116CF4940048C750 /* JSNodeCustom.h in Headers */, > 14115B7309F84CD600CA4FC1 /* JSNodeFilter.h in Headers */, > 1A750D8E0A90E521000FF215 /* JSNodeIterator.h in Headers */, >@@ -29349,7 +29327,6 @@ > 0783228518013ED800999E0C /* MediaStreamAudioSource.h in Headers */, > FD671A78159BB07000197559 /* MediaStreamAudioSourceNode.h in Headers */, > 070F549817F12F6B00169E04 /* MediaStreamConstraintsValidationClient.h in Headers */, >- 078E091617D14D1C00420AA1 /* MediaStreamEvent.h in Headers */, > 078E093717D16B2C00420AA1 /* MediaStreamPrivate.h in Headers */, > 078E091717D14D1C00420AA1 /* MediaStreamRegistry.h in Headers */, > 078E3CC01FE1C73C00483C1D /* MediaStreamRequest.h in Headers */, >@@ -30753,7 +30730,6 @@ > 7132445120109DA500AE7FB2 /* WebAnimationUtilities.h in Headers */, > E18536841F4E481400FE091B /* WebArchiveResourceFromNSAttributedString.h in Headers */, > E18C35441F71970C00FF632D /* WebArchiveResourceWebResourceHandler.h in Headers */, >- CDE667A51E4BBF1500E8154A /* WebAudioBufferList.h in Headers */, > 41B2A6261EF1BF6D002B9D7A /* WebAudioSourceProvider.h in Headers */, > 07D637401BB0B11300256CE9 /* WebAudioSourceProviderAVFObjC.h in Headers */, > 1F36EA9C1E21BA1700621E25 /* WebBackgroundTaskController.h in Headers */, >@@ -31352,6 +31328,7 @@ > CDDE02ED18B3ED6D00CF7FF1 /* CDMSessionAVFoundationObjC.mm in Sources */, > CDDE02F018B5651300CF7FF1 /* CDMSessionAVStreamSession.mm in Sources */, > CDE5959D1BF2757100A1CBE8 /* CDMSessionMediaSourceAVFObjC.mm in Sources */, >+ CDE667A41E4BBF1500E8154A /* cocoa/WebAudioBufferList.cpp in Sources */, > A14090FB1AA51E1D0091191A /* ContentFilterUnblockHandlerCocoa.mm in Sources */, > 07AFF4231EFB144900B545B3 /* CoreAudioCaptureSourceIOS.mm in Sources */, > 46C696CC1E7205FC00597937 /* CPUMonitor.cpp in Sources */, >@@ -32078,7 +32055,6 @@ > A14832B9187F63D500DA63A6 /* WAKView.mm in Sources */, > DE5F861E1FA281FD006DB63A /* WebAccessibilityObjectWrapperBase.mm in Sources */, > DE5F861D1FA2815B006DB63A /* WebAccessibilityObjectWrapperMac.mm in Sources */, >- CDE667A41E4BBF1500E8154A /* WebAudioBufferList.cpp in Sources */, > CD7E05221651C28200C1201F /* WebCoreAVFResourceLoader.mm in Sources */, > CD225C0B1C46FBF400140761 /* WebCoreNSURLSession.mm in Sources */, > 93F19B0708245E59001E9ABC /* WebCoreView.m in Sources */, >diff --git a/Source/WebCore/bindings/js/JSDOMGlobalObject.cpp b/Source/WebCore/bindings/js/JSDOMGlobalObject.cpp >index fa8500ed657a9af89487a866fd00f561f315d5df..ebb2f61ddcc325a01dc524b2b52eb8b114143058 100644 >--- a/Source/WebCore/bindings/js/JSDOMGlobalObject.cpp >+++ b/Source/WebCore/bindings/js/JSDOMGlobalObject.cpp >@@ -55,7 +55,6 @@ using namespace JSC; > > EncodedJSValue JSC_HOST_CALL makeThisTypeErrorForBuiltins(ExecState*); > EncodedJSValue JSC_HOST_CALL makeGetterTypeErrorForBuiltins(ExecState*); >-EncodedJSValue JSC_HOST_CALL isWebRTCLegacyAPIEnabled(ExecState*); > EncodedJSValue JSC_HOST_CALL isReadableByteStreamAPIEnabled(ExecState*); > > const ClassInfo JSDOMGlobalObject::s_info = { "DOMGlobalObject", &JSGlobalObject::s_info, nullptr, nullptr, CREATE_METHOD_TABLE(JSDOMGlobalObject) }; >@@ -103,13 +102,6 @@ EncodedJSValue JSC_HOST_CALL makeGetterTypeErrorForBuiltins(ExecState* execState > return JSValue::encode(createTypeError(execState, makeGetterTypeErrorMessage(interfaceName.utf8().data(), attributeName.utf8().data()))); > } > >-#if ENABLE(WEB_RTC) >-EncodedJSValue JSC_HOST_CALL isWebRTCLegacyAPIEnabled(ExecState*) >-{ >- return JSValue::encode(jsBoolean(RuntimeEnabledFeatures::sharedFeatures().webRTCLegacyAPIEnabled())); >-} >-#endif >- > #if ENABLE(STREAMS_API) > EncodedJSValue JSC_HOST_CALL isReadableByteStreamAPIEnabled(ExecState*) > { >@@ -169,9 +161,6 @@ void JSDOMGlobalObject::addBuiltinGlobals(VM& vm) > JSDOMGlobalObject::GlobalPropertyInfo(clientData.builtinNames().ReadableStreamDefaultReaderPrivateName(), privateReadableStreamDefaultReaderConstructor, PropertyAttribute::DontDelete | PropertyAttribute::ReadOnly), > JSDOMGlobalObject::GlobalPropertyInfo(clientData.builtinNames().ReadableStreamBYOBReaderPrivateName(), privateReadableStreamBYOBReaderConstructor, PropertyAttribute::DontDelete | PropertyAttribute::ReadOnly), > JSDOMGlobalObject::GlobalPropertyInfo(clientData.builtinNames().readableByteStreamAPIEnabledPrivateName(), JSFunction::create(vm, this, 0, String(), isReadableByteStreamAPIEnabled), PropertyAttribute::DontDelete | PropertyAttribute::ReadOnly), >-#endif >-#if ENABLE(WEB_RTC) >- JSDOMGlobalObject::GlobalPropertyInfo(clientData.builtinNames().webRTCLegacyAPIEnabledPrivateName(), JSFunction::create(vm, this, 0, String(), isWebRTCLegacyAPIEnabled), PropertyAttribute::DontDelete | PropertyAttribute::ReadOnly), > #endif > }; > addStaticGlobals(staticGlobals, WTF_ARRAY_LENGTH(staticGlobals)); >diff --git a/Source/WebCore/bindings/js/WebCoreBuiltinNames.h b/Source/WebCore/bindings/js/WebCoreBuiltinNames.h >index 99eb328d818314c40a37d69f1971baa952fc762c..528ca237abd5e0a4e46c5c9f3e50d0bf76e960ad 100644 >--- a/Source/WebCore/bindings/js/WebCoreBuiltinNames.h >+++ b/Source/WebCore/bindings/js/WebCoreBuiltinNames.h >@@ -99,7 +99,6 @@ namespace WebCore { > macro(MediaKeys) \ > macro(MediaSource) \ > macro(MediaStream) \ >- macro(MediaStreamEvent) \ > macro(MediaStreamTrack) \ > macro(ModernMediaControls) \ > macro(NavigatorCredentials) \ >@@ -191,7 +190,6 @@ namespace WebCore { > macro(WindowClient) \ > macro(WritableStream) \ > macro(XMLHttpRequest) \ >- macro(addTrack) \ > macro(appendFromJS) \ > macro(associatedReadableByteStreamController) \ > macro(autoAllocateChunkSize) \ >@@ -223,8 +221,6 @@ namespace WebCore { > macro(finishConsumingStream) \ > macro(focus) \ > macro(frames) \ >- macro(getRemoteStreams) \ >- macro(getSenders) \ > macro(getTracks) \ > macro(getUserMedia) \ > macro(header) \ >@@ -268,7 +264,6 @@ namespace WebCore { > macro(readableStreamController) \ > macro(reader) \ > macro(readyPromiseCapability) \ >- macro(removeTrack) \ > macro(response) \ > macro(responseCacheIsValid) \ > macro(retrieveResponse) \ >@@ -298,7 +293,6 @@ namespace WebCore { > macro(underlyingSource) \ > macro(view) \ > macro(visualViewport) \ >- macro(webRTCLegacyAPIEnabled) \ > macro(webkit) \ > macro(webkitAudioContext) \ > macro(webkitIDBCursor) \ >diff --git a/Source/WebCore/dom/EventNames.in b/Source/WebCore/dom/EventNames.in >index 39a1b0e3887ebc5a6a5d107fb205bdf3ebadb573..7157c916339fbf9ee8246743ee063ecf0c9c5f15 100644 >--- a/Source/WebCore/dom/EventNames.in >+++ b/Source/WebCore/dom/EventNames.in >@@ -48,7 +48,6 @@ ApplePayShippingMethodSelectedEvent conditional=APPLE_PAY > ApplePayValidateMerchantEvent conditional=APPLE_PAY > AudioProcessingEvent conditional=WEB_AUDIO > OfflineAudioCompletionEvent conditional=WEB_AUDIO >-MediaStreamEvent conditional=WEB_RTC > MediaStreamTrackEvent conditional=MEDIA_STREAM > MerchantValidationEvent conditional=PAYMENT_REQUEST > PaymentRequestUpdateEvent conditional=PAYMENT_REQUEST >diff --git a/Source/WebCore/page/RuntimeEnabledFeatures.h b/Source/WebCore/page/RuntimeEnabledFeatures.h >index 0e645b341d921f07900a4f15b448385c411c5226..cd9193af6a41dc4d2ed94d1bc6e14c8040394750 100644 >--- a/Source/WebCore/page/RuntimeEnabledFeatures.h >+++ b/Source/WebCore/page/RuntimeEnabledFeatures.h >@@ -118,8 +118,6 @@ public: > #if ENABLE(WEB_RTC) > bool peerConnectionEnabled() const { return m_isPeerConnectionEnabled; } > void setPeerConnectionEnabled(bool isEnabled) { m_isPeerConnectionEnabled = isEnabled; } >- bool webRTCLegacyAPIEnabled() const { return m_webRTCLegacyAPIEnabled; } >- void setWebRTCLegacyAPIEnabled(bool isEnabled) { m_webRTCLegacyAPIEnabled = isEnabled; } > bool mdnsICECandidatesEnabled() const { return m_mdnsICECandidatesEnabled; } > void setMDNSICECandidatesEnabled(bool isEnabled) { m_mdnsICECandidatesEnabled = isEnabled; } > #endif >@@ -322,7 +320,6 @@ private: > > #if ENABLE(WEB_RTC) > bool m_isPeerConnectionEnabled { true }; >- bool m_webRTCLegacyAPIEnabled { false }; > bool m_mdnsICECandidatesEnabled { false }; > #endif > >diff --git a/Source/WebKit/Shared/WebPreferences.yaml b/Source/WebKit/Shared/WebPreferences.yaml >index 260221cb30cd25bf524c22b74e6525187fb8001c..97bb9bd0d443dacdd11df080501474e869e7ead1 100644 >--- a/Source/WebKit/Shared/WebPreferences.yaml >+++ b/Source/WebKit/Shared/WebPreferences.yaml >@@ -1147,14 +1147,6 @@ IntersectionObserverEnabled: > category: experimental > condition: ENABLE(INTERSECTION_OBSERVER) > >-WebRTCLegacyAPIEnabled: >- type: bool >- defaultValue: false >- humanReadableName: "Enable Legacy WebRTC API" >- humanReadableDescription: "Enable Legacy WebRTC API" >- webcoreBinding: RuntimeEnabledFeatures >- condition: ENABLE(WEB_RTC) >- > MDNSICECandidatesEnabled: > type: bool > defaultValue: false >diff --git a/Source/WebKit/UIProcess/API/C/WKPreferences.cpp b/Source/WebKit/UIProcess/API/C/WKPreferences.cpp >index cf3955012d34d9a4db515701fd4be0cd77505707..2b06b4c1746f33c03868351f3ecc189f473cfb7d 100644 >--- a/Source/WebKit/UIProcess/API/C/WKPreferences.cpp >+++ b/Source/WebKit/UIProcess/API/C/WKPreferences.cpp >@@ -1428,16 +1428,6 @@ bool WKPreferencesGetPeerConnectionEnabled(WKPreferencesRef preferencesRef) > return toImpl(preferencesRef)->peerConnectionEnabled(); > } > >-void WKPreferencesSetWebRTCLegacyAPIEnabled(WKPreferencesRef preferencesRef, bool enabled) >-{ >- toImpl(preferencesRef)->setWebRTCLegacyAPIEnabled(enabled); >-} >- >-bool WKPreferencesGetWebRTCLegacyAPIEnabled(WKPreferencesRef preferencesRef) >-{ >- return toImpl(preferencesRef)->webRTCLegacyAPIEnabled(); >-} >- > void WKPreferencesSetWebRTCMDNSICECandidatesEnabled(WKPreferencesRef preferencesRef, bool enabled) > { > toImpl(preferencesRef)->setMDNSICECandidatesEnabled(enabled); >diff --git a/Source/WebKit/UIProcess/API/C/WKPreferencesRef.h b/Source/WebKit/UIProcess/API/C/WKPreferencesRef.h >index 5fd8c93fb7bf2f6dde4bc84832db181c671da970..1c2fbb4aea2f69d5bf16f445d382f300570baf63 100644 >--- a/Source/WebKit/UIProcess/API/C/WKPreferencesRef.h >+++ b/Source/WebKit/UIProcess/API/C/WKPreferencesRef.h >@@ -268,10 +268,6 @@ WK_EXPORT bool WKPreferencesGetMediaDevicesEnabled(WKPreferencesRef preferencesR > WK_EXPORT void WKPreferencesSetPeerConnectionEnabled(WKPreferencesRef preferencesRef, bool enabled); > WK_EXPORT bool WKPreferencesGetPeerConnectionEnabled(WKPreferencesRef preferencesRef); > >-// Should default to false >-WK_EXPORT void WKPreferencesSetWebRTCLegacyAPIEnabled(WKPreferencesRef preferencesRef, bool enabled); >-WK_EXPORT bool WKPreferencesGetWebRTCLegacyAPIEnabled(WKPreferencesRef preferencesRef); >- > // Defaults to false > WK_EXPORT void WKPreferencesSetWebRTCMDNSICECandidatesEnabled(WKPreferencesRef preferencesRef, bool enabled); > WK_EXPORT bool WKPreferencesGetWebRTCMDNSICECandidatesEnabled(WKPreferencesRef preferencesRef); >diff --git a/Source/WebKit/UIProcess/API/Cocoa/WKPreferences.mm b/Source/WebKit/UIProcess/API/Cocoa/WKPreferences.mm >index c49b4768a2d801e1a299f4c69f0b37c8bd20ae3a..139a89f4e98f9427f8ac45d60b2bcc5ec89009e2 100644 >--- a/Source/WebKit/UIProcess/API/Cocoa/WKPreferences.mm >+++ b/Source/WebKit/UIProcess/API/Cocoa/WKPreferences.mm >@@ -669,16 +669,6 @@ - (void)_setICECandidateFilteringEnabled:(BOOL)enabled > _preferences->setICECandidateFilteringEnabled(enabled); > } > >-- (BOOL)_webRTCLegacyAPIEnabled >-{ >- return _preferences->webRTCLegacyAPIEnabled(); >-} >- >-- (void)_setWebRTCLegacyAPIEnabled:(BOOL)enabled >-{ >- _preferences->setWebRTCLegacyAPIEnabled(enabled); >-} >- > - (void)_setJavaScriptCanAccessClipboard:(BOOL)javaScriptCanAccessClipboard > { > _preferences->setJavaScriptCanAccessClipboard(javaScriptCanAccessClipboard); >diff --git a/Source/WebKit/UIProcess/API/Cocoa/WKPreferencesPrivate.h b/Source/WebKit/UIProcess/API/Cocoa/WKPreferencesPrivate.h >index 3879e35ed325e857b0c5ab73cd7bdac419e6533c..f86fba215522f2fd4c8e5dd47ceca3570198ca58 100644 >--- a/Source/WebKit/UIProcess/API/Cocoa/WKPreferencesPrivate.h >+++ b/Source/WebKit/UIProcess/API/Cocoa/WKPreferencesPrivate.h >@@ -118,7 +118,6 @@ typedef NS_ENUM(NSInteger, _WKEditableLinkBehavior) { > @property (nonatomic, setter=_setMediaCaptureRequiresSecureConnection:) BOOL _mediaCaptureRequiresSecureConnection WK_API_AVAILABLE(macosx(10.13), ios(11.0)); > @property (nonatomic, setter=_setEnumeratingAllNetworkInterfacesEnabled:) BOOL _enumeratingAllNetworkInterfacesEnabled WK_API_AVAILABLE(macosx(10.13), ios(11.0)); > @property (nonatomic, setter=_setICECandidateFilteringEnabled:) BOOL _iceCandidateFilteringEnabled WK_API_AVAILABLE(macosx(10.13.4), ios(11.3)); >-@property (nonatomic, setter=_setWebRTCLegacyAPIEnabled:) BOOL _webRTCLegacyAPIEnabled WK_API_AVAILABLE(macosx(10.13), ios(11.0)); > @property (nonatomic, setter=_setInactiveMediaCaptureSteamRepromptIntervalInMinutes:) double _inactiveMediaCaptureSteamRepromptIntervalInMinutes WK_API_AVAILABLE(macosx(10.13.4), ios(11.3)); > > @property (nonatomic, setter=_setJavaScriptCanAccessClipboard:) BOOL _javaScriptCanAccessClipboard WK_API_AVAILABLE(macosx(10.13), ios(11.0)); >diff --git a/Source/WebKit/WebProcess/InjectedBundle/InjectedBundle.cpp b/Source/WebKit/WebProcess/InjectedBundle/InjectedBundle.cpp >index d43114c20646b4743bad7caabced8ff186c31437..38e2bcf6fcfbc158980814455cf3027b9187961d 100644 >--- a/Source/WebKit/WebProcess/InjectedBundle/InjectedBundle.cpp >+++ b/Source/WebKit/WebProcess/InjectedBundle/InjectedBundle.cpp >@@ -239,8 +239,6 @@ void InjectedBundle::overrideBoolPreferenceForTestRunner(WebPageGroupProxy* page > #endif > > #if ENABLE(WEB_RTC) >- if (preference == "WebKitWebRTCLegacyAPIEnabled") >- RuntimeEnabledFeatures::sharedFeatures().setWebRTCLegacyAPIEnabled(enabled); > if (preference == "WebKitMDNSICECandidatesEnabled") > RuntimeEnabledFeatures::sharedFeatures().setMDNSICECandidatesEnabled(enabled); > #endif >diff --git a/Source/WebKitLegacy/mac/WebView/WebPreferenceKeysPrivate.h b/Source/WebKitLegacy/mac/WebView/WebPreferenceKeysPrivate.h >index fc7bf743c00b09de3b0df8fb52e35e4b1136e14e..d774691c817a48bcd7d3ffafd604ef29158d226f 100644 >--- a/Source/WebKitLegacy/mac/WebView/WebPreferenceKeysPrivate.h >+++ b/Source/WebKitLegacy/mac/WebView/WebPreferenceKeysPrivate.h >@@ -187,7 +187,6 @@ > #define WebKitMediaDevicesEnabledPreferenceKey @"WebKitMediaDevicesEnabled" > #define WebKitMediaStreamEnabledPreferenceKey @"WebKitMediaStreamEnabled" > #define WebKitPeerConnectionEnabledPreferenceKey @"WebKitPeerConnectionEnabled" >-#define WebKitWebRTCLegacyAPIEnabledPreferenceKey @"WebKitWebRTCLegacyAPIEnabled" > #define WebKitLinkPreloadEnabledPreferenceKey @"WebKitLinkPreloadEnabled" > #define WebKitMediaPreloadingEnabledPreferenceKey @"WebKitMediaPreloadingEnabled" > #define WebKitWebAuthenticationEnabledPreferenceKey @"WebKitWebAuthenticationEnabled" >diff --git a/Source/WebKitLegacy/mac/WebView/WebPreferences.mm b/Source/WebKitLegacy/mac/WebView/WebPreferences.mm >index 3a986070eb3cb6a7161a9925c09eee59d85eb1b8..be6eb0b632205d2ff16f80ec3538806fde46e8fd 100644 >--- a/Source/WebKitLegacy/mac/WebView/WebPreferences.mm >+++ b/Source/WebKitLegacy/mac/WebView/WebPreferences.mm >@@ -662,7 +662,6 @@ + (void)initialize > #endif > #if ENABLE(WEB_RTC) > [NSNumber numberWithBool:YES], WebKitPeerConnectionEnabledPreferenceKey, >- [NSNumber numberWithBool:NO], WebKitWebRTCLegacyAPIEnabledPreferenceKey, > #endif > #if ENABLE(INTERSECTION_OBSERVER) > @NO, WebKitIntersectionObserverEnabledPreferenceKey, >@@ -2833,16 +2832,6 @@ - (void)setPeerConnectionEnabled:(BOOL)flag > [self _setBoolValue:flag forKey:WebKitPeerConnectionEnabledPreferenceKey]; > } > >-- (BOOL)webRTCLegacyAPIEnabled >-{ >- return [self _boolValueForKey:WebKitWebRTCLegacyAPIEnabledPreferenceKey]; >-} >- >-- (void)setWebRTCLegacyAPIEnabled:(BOOL)flag >-{ >- [self _setBoolValue:flag forKey:WebKitWebRTCLegacyAPIEnabledPreferenceKey]; >-} >- > - (BOOL)linkPreloadEnabled > { > return [self _boolValueForKey:WebKitLinkPreloadEnabledPreferenceKey]; >diff --git a/Source/WebKitLegacy/mac/WebView/WebPreferencesPrivate.h b/Source/WebKitLegacy/mac/WebView/WebPreferencesPrivate.h >index 2f1ddc4971ece4f3697199f3fa648fb6664d23b9..894011833fa83b4115ba5e6cc430b06dee336c6e 100644 >--- a/Source/WebKitLegacy/mac/WebView/WebPreferencesPrivate.h >+++ b/Source/WebKitLegacy/mac/WebView/WebPreferencesPrivate.h >@@ -183,9 +183,6 @@ extern NSString *WebPreferencesCacheModelChangedInternalNotification WEBKIT_DEPR > - (void)setPeerConnectionEnabled:(BOOL)flag; > - (BOOL)peerConnectionEnabled; > >-- (void)setWebRTCLegacyAPIEnabled:(BOOL)flag; >-- (BOOL)webRTCLegacyAPIEnabled; >- > #if !TARGET_OS_IPHONE > // zero means do AutoScale > - (float)PDFScaleFactor; >diff --git a/Source/WebKitLegacy/mac/WebView/WebView.mm b/Source/WebKitLegacy/mac/WebView/WebView.mm >index b892734caff365dd78549d87ec0a0394976b6666..0121b084f634b8faeecdf8ec2521e85d03b7ea5b 100644 >--- a/Source/WebKitLegacy/mac/WebView/WebView.mm >+++ b/Source/WebKitLegacy/mac/WebView/WebView.mm >@@ -3049,7 +3049,6 @@ - (void)_preferencesChanged:(WebPreferences *)preferences > > #if ENABLE(WEB_RTC) > RuntimeEnabledFeatures::sharedFeatures().setPeerConnectionEnabled([preferences peerConnectionEnabled]); >- RuntimeEnabledFeatures::sharedFeatures().setWebRTCLegacyAPIEnabled([preferences webRTCLegacyAPIEnabled]); > #endif > > #if ENABLE(WEB_AUDIO) >diff --git a/Tools/ChangeLog b/Tools/ChangeLog >index f7509116444599c491a07550cc2eaf464ce98f62..7a0887d3331b3daa394146a10088d7413b8c11b4 100644 >--- a/Tools/ChangeLog >+++ b/Tools/ChangeLog >@@ -1,3 +1,19 @@ >+2018-08-27 Youenn Fablet <youenn@apple.com> >+ >+ Remove WebRTC legacy API implementation >+ https://bugs.webkit.org/show_bug.cgi?id=189040 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * DumpRenderTree/mac/DumpRenderTree.mm: >+ (enableExperimentalFeatures): >+ * WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl: >+ * WebKitTestRunner/InjectedBundle/TestRunner.cpp: >+ (WTR::TestRunner::setWebRTCLegacyAPIEnabled): Deleted. >+ * WebKitTestRunner/InjectedBundle/TestRunner.h: >+ * WebKitTestRunner/TestController.cpp: >+ (WTR::TestController::resetPreferencesToConsistentValues): >+ > 2018-08-27 Wenson Hsieh <wenson_hsieh@apple.com> > > [Attachment Support] Remove WebCore::AttachmentDisplayOptions and friends >diff --git a/Tools/DumpRenderTree/mac/DumpRenderTree.mm b/Tools/DumpRenderTree/mac/DumpRenderTree.mm >index 2ad03a018457e540eed866b72f74656f4b9f6948..6d115ba325908ddaeec3a6b6864fdd36195fc30b 100644 >--- a/Tools/DumpRenderTree/mac/DumpRenderTree.mm >+++ b/Tools/DumpRenderTree/mac/DumpRenderTree.mm >@@ -856,7 +856,6 @@ static void enableExperimentalFeatures(WebPreferences* preferences) > [preferences setWebGL2Enabled:YES]; > [preferences setWebGPUEnabled:YES]; > // FIXME: AsyncFrameScrollingEnabled >- [preferences setWebRTCLegacyAPIEnabled:YES]; > [preferences setWebAuthenticationEnabled:NO]; > [preferences setCacheAPIEnabled:NO]; > [preferences setReadableByteStreamAPIEnabled:YES]; >diff --git a/Tools/WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl b/Tools/WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl >index e9902110aefa1f0173e5134aea266b694a03d656..9a55d9213262eaae1fb8c7f1ecca92051f0556a2 100644 >--- a/Tools/WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl >+++ b/Tools/WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl >@@ -320,7 +320,6 @@ interface TestRunner { > // Open panel > void setOpenPanelFiles(object filesArray); > >- void setWebRTCLegacyAPIEnabled(boolean value); > void setMDNSICECandidatesEnabled(boolean value); > void setCustomUserAgent(DOMString userAgent); > >diff --git a/Tools/WebKitTestRunner/InjectedBundle/TestRunner.cpp b/Tools/WebKitTestRunner/InjectedBundle/TestRunner.cpp >index d3cf06b41249e3cc8df85ffad3bfde926f9acf5e..ef98e634c162d50f02c6d6d7adb3582db1e0d254 100644 >--- a/Tools/WebKitTestRunner/InjectedBundle/TestRunner.cpp >+++ b/Tools/WebKitTestRunner/InjectedBundle/TestRunner.cpp >@@ -448,13 +448,6 @@ void TestRunner::setCustomUserAgent(JSStringRef userAgent) > WKBundlePostSynchronousMessage(InjectedBundle::singleton().bundle(), messageName.get(), toWK(userAgent).get(), nullptr); > } > >-void TestRunner::setWebRTCLegacyAPIEnabled(bool enabled) >-{ >- WKRetainPtr<WKStringRef> key(AdoptWK, WKStringCreateWithUTF8CString("WebKitWebRTCLegacyAPIEnabled")); >- auto& injectedBundle = InjectedBundle::singleton(); >- WKBundleOverrideBoolPreferenceForTestRunner(injectedBundle.bundle(), injectedBundle.pageGroup(), key.get(), enabled); >-} >- > void TestRunner::setModernMediaControlsEnabled(bool enabled) > { > WKRetainPtr<WKStringRef> key(AdoptWK, WKStringCreateWithUTF8CString("WebKitModernMediaControlsEnabled")); >diff --git a/Tools/WebKitTestRunner/InjectedBundle/TestRunner.h b/Tools/WebKitTestRunner/InjectedBundle/TestRunner.h >index a24ddfe474e7e9a3db2a472dce79790db9f8f983..92964889a9a6ec606672a3c4a23862130dc3eeab 100644 >--- a/Tools/WebKitTestRunner/InjectedBundle/TestRunner.h >+++ b/Tools/WebKitTestRunner/InjectedBundle/TestRunner.h >@@ -130,7 +130,6 @@ public: > void setAllowsAnySSLCertificate(bool); > void setEncryptedMediaAPIEnabled(bool); > void setMediaDevicesEnabled(bool); >- void setWebRTCLegacyAPIEnabled(bool); > void setMDNSICECandidatesEnabled(bool); > void setCustomUserAgent(JSStringRef); > >diff --git a/Tools/WebKitTestRunner/TestController.cpp b/Tools/WebKitTestRunner/TestController.cpp >index 68a4d12f50692d0050e735b5467fc09b0c0d3b31..975026377ddef514ff14fa2dbc56f554bef0c70a 100644 >--- a/Tools/WebKitTestRunner/TestController.cpp >+++ b/Tools/WebKitTestRunner/TestController.cpp >@@ -706,7 +706,6 @@ void TestController::resetPreferencesToConsistentValues(const TestOptions& optio > WKPreferencesSetXSSAuditorEnabled(preferences, false); > WKPreferencesSetWebAudioEnabled(preferences, true); > WKPreferencesSetMediaDevicesEnabled(preferences, true); >- WKPreferencesSetWebRTCLegacyAPIEnabled(preferences, true); > WKPreferencesSetWebRTCMDNSICECandidatesEnabled(preferences, false); > WKPreferencesSetDeveloperExtrasEnabled(preferences, true); > WKPreferencesSetJavaScriptRuntimeFlags(preferences, kWKJavaScriptRuntimeFlagsAllEnabled); >diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog >index d4762b8fae8414052d7fb54ddfddf69df320d595..0e67aeeabf893d28e55fa7ff4452e36cf7524a31 100644 >--- a/LayoutTests/ChangeLog >+++ b/LayoutTests/ChangeLog >@@ -1,3 +1,51 @@ >+2018-08-27 Youenn Fablet <youenn@apple.com> >+ >+ Remove WebRTC legacy API implementation >+ https://bugs.webkit.org/show_bug.cgi?id=189040 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * TestExpectations: >+ * fast/events/constructors/media-stream-event-constructor-expected.txt: Removed. >+ * fast/events/constructors/media-stream-event-constructor.html: Removed. >+ * fast/mediastream/RTCPeerConnection-AddRemoveStream-expected.txt: Removed. >+ * fast/mediastream/RTCPeerConnection-AddRemoveStream.html: Removed. >+ * fast/mediastream/RTCPeerConnection-createAnswer-expected.txt: >+ * fast/mediastream/RTCPeerConnection-createAnswer.html: >+ * fast/mediastream/RTCPeerConnection-createOffer-expected.txt: Removed. >+ * fast/mediastream/RTCPeerConnection-createOffer.html: Removed. >+ * fast/mediastream/RTCPeerConnection-dtmf.html: Removed. >+ * fast/mediastream/RTCPeerConnection-events-expected.txt: Removed. >+ * fast/mediastream/RTCPeerConnection-events.html: Removed. >+ * fast/mediastream/RTCPeerConnection-have-local-offer-expected.txt: >+ * fast/mediastream/RTCPeerConnection-have-local-offer.html: >+ * fast/mediastream/RTCPeerConnection-have-local-pranswer-expected.txt: >+ * fast/mediastream/RTCPeerConnection-have-local-pranswer.html: >+ * fast/mediastream/RTCPeerConnection-have-remote-offer-expected.txt: >+ * fast/mediastream/RTCPeerConnection-have-remote-offer.html: >+ * fast/mediastream/RTCPeerConnection-have-remote-pranswer-expected.txt: >+ * fast/mediastream/RTCPeerConnection-have-remote-pranswer.html: >+ * fast/mediastream/RTCPeerConnection-legacy-stream-based-api-expected.txt: Removed. >+ * fast/mediastream/RTCPeerConnection-legacy-stream-based-api.html: Removed. >+ * fast/mediastream/RTCPeerConnection-localDescription-expected.txt: >+ * fast/mediastream/RTCPeerConnection-localDescription.html: >+ * fast/mediastream/RTCPeerConnection-remoteDescription-expected.txt: >+ * fast/mediastream/RTCPeerConnection-remoteDescription.html: >+ * fast/mediastream/RTCPeerConnection-stable-expected.txt: >+ * fast/mediastream/RTCPeerConnection-stable.html: >+ * fast/mediastream/RTCPeerConnection-stats.html: >+ * fast/mediastream/RTCPeerConnection-statsSelector-expected.txt: >+ * fast/mediastream/RTCPeerConnection-statsSelector.html: >+ * fast/mediastream/argument-types-expected.txt: Removed. >+ * fast/mediastream/argument-types.html: Removed. >+ * fast/mediastream/getusermedia-expected.txt: Removed. >+ * fast/mediastream/getusermedia.html: Removed. >+ * fast/mediastream/webkitGetUserMedia-shadowing-then-expected.txt: Removed. >+ * fast/mediastream/webkitGetUserMedia-shadowing-then.html: Removed. >+ * platform/mac/TestExpectations: >+ * webrtc/legacy-api-expected.txt: >+ * webrtc/legacy-api.html: >+ > 2018-08-28 Aditya Keerthi <akeerthi@apple.com> > > [Datalist] Pressing enter without a selected option shouldn't change the input >diff --git a/LayoutTests/imported/w3c/ChangeLog b/LayoutTests/imported/w3c/ChangeLog >index 0365e46f7d61dcddd5b023a99f20339964943aec..75ac6a409b0aa8bb0839be0dca254f24129abb3e 100644 >--- a/LayoutTests/imported/w3c/ChangeLog >+++ b/LayoutTests/imported/w3c/ChangeLog >@@ -1,3 +1,17 @@ >+2018-08-27 Youenn Fablet <youenn@apple.com> >+ >+ Remove WebRTC legacy API implementation >+ https://bugs.webkit.org/show_bug.cgi?id=189040 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * web-platform-tests/mediacapture-streams/MediaDevices-IDL-all-expected.txt: >+ * web-platform-tests/mediacapture-streams/MediaDevices-IDL-enumerateDevices-expected.txt: >+ * web-platform-tests/mediacapture-streams/MediaStream-default-feature-policy.https-expected.txt: >+ * web-platform-tests/webrtc/historical-expected.txt: >+ * web-platform-tests/webrtc/no-media-call.html: >+ * web-platform-tests/webrtc/simplecall.https.html: >+ > 2018-08-28 Aditya Keerthi <akeerthi@apple.com> > > [iOS] Support inputmode=none >diff --git a/LayoutTests/TestExpectations b/LayoutTests/TestExpectations >index 6c712b96c9f9632ce1f97f0937e10583966a6864..4265285b67d32957a47549550bcd876c0e7bb28b 100644 >--- a/LayoutTests/TestExpectations >+++ b/LayoutTests/TestExpectations >@@ -1177,12 +1177,14 @@ webkit.org/b/172f21 imported/w3c/web-platform-tests/webrtc/getstats.html [ Failu > imported/w3c/web-platform-tests/webrtc/RTCPeerConnection-ontrack.https.html [ Skip ] > imported/w3c/web-platform-tests/webrtc/RTCPeerConnection-setLocalDescription-offer.html [ Failure ] > >+# Uses legacy WebRTC API. >+imported/w3c/web-platform-tests/webrtc/rtcpeerconnection/setRemoteDescription.html [ Skip ] >+ > fast/mediastream/RTCPeerConnection-closed-state.html [ Skip ] > fast/mediastream/RTCPeerConnection-iceconnectionstatechange-event.html [ Skip ] > fast/mediastream/RTCPeerConnection-more-media-to-negotiate.html [ Skip ] > fast/mediastream/RTCPeerConnection-overloaded-operations-params.html [ Skip ] > fast/mediastream/RTCRtpSender-replaceTrack.html [ Skip ] >-fast/mediastream/RTCPeerConnection-dtmf.html [ Failure ] > fast/mediastream/RTCPeerConnection-inspect-offer-bundlePolicy-bundle-only.html [ Failure ] > > # Only iOS WK1 has testRunner.setPagePaused. >diff --git a/LayoutTests/fast/events/constructors/media-stream-event-constructor-expected.txt b/LayoutTests/fast/events/constructors/media-stream-event-constructor-expected.txt >deleted file mode 100644 >index 2b710cd521b5e0b065c31986f8c9fb31feae74fc..0000000000000000000000000000000000000000 >--- a/LayoutTests/fast/events/constructors/media-stream-event-constructor-expected.txt >+++ /dev/null >@@ -1,34 +0,0 @@ >-This tests the constructor for the MediaStreamEvent DOM class. >- >-On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE". >- >- >-PASS new MediaStreamEvent('eventType').bubbles is false >-PASS new MediaStreamEvent('eventType').cancelable is false >-PASS new MediaStreamEvent('eventType').stream is null >-PASS new MediaStreamEvent('eventType', { bubbles: false }).bubbles is false >-PASS new MediaStreamEvent('eventType', { bubbles: true }).bubbles is true >-PASS new MediaStreamEvent('eventType', { cancelable: false }).cancelable is false >-PASS new MediaStreamEvent('eventType', { cancelable: true }).cancelable is true >-PASS new MediaStreamEvent('eventType', { stream: mediaStream }).stream is mediaStream >-PASS new MediaStreamEvent('eventType', { stream: testObject }).stream threw exception TypeError: Type error. >-PASS new MediaStreamEvent('eventType', { stream: document }).stream threw exception TypeError: Type error. >-PASS new MediaStreamEvent('eventType', { stream: undefined }).stream is null >-PASS new MediaStreamEvent('eventType', { stream: null }).stream is null >-PASS new MediaStreamEvent('eventType', { stream: false }).stream threw exception TypeError: Type error. >-PASS new MediaStreamEvent('eventType', { stream: true }).stream threw exception TypeError: Type error. >-PASS new MediaStreamEvent('eventType', { stream: '' }).stream threw exception TypeError: Type error. >-PASS new MediaStreamEvent('eventType', { stream: 'chocolate' }).stream threw exception TypeError: Type error. >-PASS new MediaStreamEvent('eventType', { stream: 12345 }).stream threw exception TypeError: Type error. >-PASS new MediaStreamEvent('eventType', { stream: 18446744073709551615 }).stream threw exception TypeError: Type error. >-PASS new MediaStreamEvent('eventType', { stream: NaN }).stream threw exception TypeError: Type error. >-PASS new MediaStreamEvent('eventType', { stream: {valueOf: function () { return mediaStream; } } }).stream threw exception TypeError: Type error. >-PASS new MediaStreamEvent('eventType', { get stream() { return 123; } }).stream threw exception TypeError: Type error. >-PASS new MediaStreamEvent('eventType', { get stream() { throw 'MediaStreamEvent Error'; } }) threw exception MediaStreamEvent Error. >-PASS new MediaStreamEvent('eventType', { bubbles: true, cancelable: true, stream: mediaStream }).bubbles is true >-PASS new MediaStreamEvent('eventType', { bubbles: true, cancelable: true, stream: mediaStream }).cancelable is true >-PASS new MediaStreamEvent('eventType', { bubbles: true, cancelable: true, stream: mediaStream }).stream is mediaStream >-PASS successfullyParsed is true >- >-TEST COMPLETE >- >diff --git a/LayoutTests/fast/events/constructors/media-stream-event-constructor.html b/LayoutTests/fast/events/constructors/media-stream-event-constructor.html >deleted file mode 100644 >index 01ae846ded0dd6945100da9274349c8615c56b70..0000000000000000000000000000000000000000 >--- a/LayoutTests/fast/events/constructors/media-stream-event-constructor.html >+++ /dev/null >@@ -1,55 +0,0 @@ >-<!DOCTYPE html> >-<html> >-<head> >-<script src="../../../resources/js-test-pre.js"></script> >-</head> >-<body> >-<script> >- >-description("This tests the constructor for the MediaStreamEvent DOM class."); >- >-var testObject = {nyannyan: 123}; >-var mediaStream = new MediaStream(); >- >-// No initializer is passed. >-shouldBe("new MediaStreamEvent('eventType').bubbles", "false"); >-shouldBe("new MediaStreamEvent('eventType').cancelable", "false"); >-shouldBe("new MediaStreamEvent('eventType').stream", "null"); >- >-// bubbles is passed. >-shouldBe("new MediaStreamEvent('eventType', { bubbles: false }).bubbles", "false"); >-shouldBe("new MediaStreamEvent('eventType', { bubbles: true }).bubbles", "true"); >- >-// cancelable is passed. >-shouldBe("new MediaStreamEvent('eventType', { cancelable: false }).cancelable", "false"); >-shouldBe("new MediaStreamEvent('eventType', { cancelable: true }).cancelable", "true"); >- >-// stream is passed. >-// Valid object. >-shouldBe("new MediaStreamEvent('eventType', { stream: mediaStream }).stream", "mediaStream"); >- >-// Invalid objects. >-shouldThrowErrorName("new MediaStreamEvent('eventType', { stream: testObject }).stream", "TypeError"); >-shouldThrowErrorName("new MediaStreamEvent('eventType', { stream: document }).stream", "TypeError"); >-shouldBe("new MediaStreamEvent('eventType', { stream: undefined }).stream", "null"); >-shouldBe("new MediaStreamEvent('eventType', { stream: null }).stream", "null"); >-shouldThrowErrorName("new MediaStreamEvent('eventType', { stream: false }).stream", "TypeError"); >-shouldThrowErrorName("new MediaStreamEvent('eventType', { stream: true }).stream", "TypeError"); >-shouldThrowErrorName("new MediaStreamEvent('eventType', { stream: '' }).stream", "TypeError"); >-shouldThrowErrorName("new MediaStreamEvent('eventType', { stream: 'chocolate' }).stream", "TypeError"); >-shouldThrowErrorName("new MediaStreamEvent('eventType', { stream: 12345 }).stream", "TypeError"); >-shouldThrowErrorName("new MediaStreamEvent('eventType', { stream: 18446744073709551615 }).stream", "TypeError"); >-shouldThrowErrorName("new MediaStreamEvent('eventType', { stream: NaN }).stream", "TypeError"); >-// Note that valueOf() is not called, when the left hand side is evaluated. >-shouldThrowErrorName("new MediaStreamEvent('eventType', { stream: {valueOf: function () { return mediaStream; } } }).stream", "TypeError"); >-shouldThrowErrorName("new MediaStreamEvent('eventType', { get stream() { return 123; } }).stream", "TypeError"); >-shouldThrow("new MediaStreamEvent('eventType', { get stream() { throw 'MediaStreamEvent Error'; } })"); >- >-// All initializers are passed. >-shouldBe("new MediaStreamEvent('eventType', { bubbles: true, cancelable: true, stream: mediaStream }).bubbles", "true"); >-shouldBe("new MediaStreamEvent('eventType', { bubbles: true, cancelable: true, stream: mediaStream }).cancelable", "true"); >-shouldBe("new MediaStreamEvent('eventType', { bubbles: true, cancelable: true, stream: mediaStream }).stream", "mediaStream"); >-</script> >-<script src="../../../resources/js-test-post.js"></script> >-</body> >-</html> >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-AddRemoveStream-expected.txt b/LayoutTests/fast/mediastream/RTCPeerConnection-AddRemoveStream-expected.txt >deleted file mode 100644 >index 12a5aa3e60201fbd41cd82f1c9cf7791285d5d02..0000000000000000000000000000000000000000 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-AddRemoveStream-expected.txt >+++ /dev/null >@@ -1,21 +0,0 @@ >-Tests RTCPeerConnection [add|remove]Stream. >- >-On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE". >- >- >-PASS Got a stream. >-PASS pc.addStream(null) threw exception TypeError: Argument 1 ('stream') to RTCPeerConnection.addStream must be an instance of MediaStream. >-PASS pc.getLocalStreams().length is 0 >-PASS Got another stream. >-PASS stream.id === stream2.id is false >-PASS onAddStream was called. >-PASS pc.getStreamById(stream.id) is stream >-PASS pc.getStreamById(stream2.id) is null >-PASS pc.getLocalStreams().length is 1 >-PASS pc.getLocalStreams().length is 1 >-PASS onRemoveStream was called. >-PASS pc.getLocalStreams().length is 0 >-PASS successfullyParsed is true >- >-TEST COMPLETE >- >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-AddRemoveStream.html b/LayoutTests/fast/mediastream/RTCPeerConnection-AddRemoveStream.html >deleted file mode 100644 >index 6d04794d406d921219cafe937148216e120b14b7..0000000000000000000000000000000000000000 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-AddRemoveStream.html >+++ /dev/null >@@ -1,104 +0,0 @@ >-<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> >-<html> >- <head> >- <script src="../../resources/js-test-pre.js"></script> >- <script src="./resources/getUserMedia-helper.js"></script> >- </head> >- <body> >- <script> >- description("Tests RTCPeerConnection [add|remove]Stream."); >- >- var stream = null; >- var stream2 = null; >- var pc = null; >- >- function error() >- { >- testFailed('Stream generation failed.'); >- finishJSTest(); >- } >- >- function getUserMedia(dictionary, callback) >- { >- try { >- navigator.mediaDevices.getUserMedia(dictionary) >- .then(callback) >- .catch(error); >- } catch (e) { >- testFailed('webkitGetUserMedia threw exception :' + e); >- finishJSTest(); >- } >- } >- >- function onErroneousNegotiationNeeded() >- { >- testFailed('onErroneousNegotiationNeeded was called.'); >- finishJSTest(); >- } >- >- function onRemoveStream(event) >- { >- testPassed('onRemoveStream was called.'); >- >- shouldBe('pc.getLocalStreams().length', '0'); >- >- finishJSTest(); >- } >- >- function onAddStream(event) >- { >- testPassed('onAddStream was called.'); >- >- shouldBe('pc.getStreamById(stream.id)', 'stream'); >- shouldBe('pc.getStreamById(stream2.id)', 'null'); >- >- pc.onnegotiationneeded = onErroneousNegotiationNeeded; >- pc.addStream(stream); >- shouldBe('pc.getLocalStreams().length', '1'); >- pc.removeStream(stream2); >- shouldBe('pc.getLocalStreams().length', '1'); >- >- pc.onnegotiationneeded = onRemoveStream; >- pc.removeStream(stream); >- } >- >- function gotStream2(s) >- { >- testPassed('Got another stream.'); >- stream2 = s; >- >- shouldBeFalse("stream.id === stream2.id"); >- >- pc.onnegotiationneeded = onAddStream; >- pc.addStream(stream); >- } >- >- function gotStream1(s) >- { >- testPassed('Got a stream.'); >- stream = s; >- >- pc = new RTCPeerConnection({iceServers:[{urls:'stun:foo.com'}]}); >- pc.onnegotiationneeded = onErroneousNegotiationNeeded; >- shouldThrow("pc.addStream(null)"); >- >- shouldBe('pc.getLocalStreams().length', '0'); >- >- getUserMedia({audio:true, video:true}, gotStream2); >- } >- >- if (window.testRunner) >- testRunner.setUserMediaPermission(true); >- else { >- debug("This test can not be run without the testRunner"); >- finishJSTest(); >- } >- >- getUserMedia({audio:true, video:true}, gotStream1); >- >- window.jsTestIsAsync = true; >- window.successfullyParsed = true; >- </script> >- <script src="../../resources/js-test-post.js"></script> >- </body> >-</html> >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-createAnswer-expected.txt b/LayoutTests/fast/mediastream/RTCPeerConnection-createAnswer-expected.txt >index 95ff8a5125dd91798e68397aa3a29999ba87e96e..f63a0a2b8a792a246470624a113a2a879e6343d7 100644 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-createAnswer-expected.txt >+++ b/LayoutTests/fast/mediastream/RTCPeerConnection-createAnswer-expected.txt >@@ -3,7 +3,7 @@ Tests RTCPeerConnection createAnswer. > On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE". > > >-PASS pc.createAnswer(requestSucceeded1, requestFailed1); did not throw exception. >+PASS pc.createAnswer().then(requestSucceeded1, requestFailed1); did not throw exception. > FAIL createAnswer request failed. > PASS successfullyParsed is true > >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-createAnswer.html b/LayoutTests/fast/mediastream/RTCPeerConnection-createAnswer.html >index 8274b73a1c4eda9f817b18513720434149c21fd4..e8e9c4c7f7939911b03683578adb4982386d0527 100644 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-createAnswer.html >+++ b/LayoutTests/fast/mediastream/RTCPeerConnection-createAnswer.html >@@ -26,7 +26,7 @@ > sessionDescription = sd; > shouldBe('sessionDescription.type', '"answer"'); > >- shouldNotThrow('pc.createAnswer(requestSucceeded5, requestFailed1, {requestIdentity:"no"});'); >+ shouldNotThrow('pc.createAnswer({requestIdentity:"no"}).then(requestSucceeded5, requestFailed1);'); > } > > function requestSucceeded3(sd) >@@ -37,7 +37,7 @@ > sessionDescription = sd; > shouldBe('sessionDescription.type', '"answer"'); > >- shouldNotThrow('pc.createAnswer(requestSucceeded4, requestFailed1, {requestIdentity:"yes"});'); >+ shouldNotThrow('pc.createAnswer({requestIdentity:"yes"}).then(requestSucceeded4, requestFailed1);'); > } > > function requestFailed2(reason) >@@ -46,7 +46,7 @@ > > errorReason = reason; > shouldBe('errorReason.name', '"Invalid createAnswer argument."'); >- shouldNotThrow('pc.createAnswer(requestSucceeded3, requestFailed1, {requestIdentity:"ifconfigured"});'); >+ shouldNotThrow('pc.createAnswer({requestIdentity:"ifconfigured"}).then(requestSucceeded3, requestFailed1);'); > } > > function requestSucceeded2() >@@ -68,7 +68,7 @@ > testPassed('createAnswer request succeeded.'); > > sessionDescription = new RTCSessionDescription({type:"offer", sdp:"v=0\r\no=- 5667094644266930845 0 IN IP4 127.0.0.1\r\ns=-\r\nt=0 0\r\n"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, setDescriptionSucceeded, setDescriptionFailed);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(setDescriptionSucceeded, setDescriptionFailed);'); > } > > function setDescriptionFailed(message) >@@ -81,11 +81,11 @@ > function setDescriptionSucceeded() > { > testPassed('setRemoteDescription succeeded.'); >- pc.createAnswer(requestSucceeded2, requestFailed2, {}); >+ pc.createAnswer({}).then(requestSucceeded2, requestFailed2); > } > > pc = new RTCPeerConnection({iceServers:[{urls:'stun:foo.com'}]}); >- shouldNotThrow('pc.createAnswer(requestSucceeded1, requestFailed1);'); >+ shouldNotThrow('pc.createAnswer().then(requestSucceeded1, requestFailed1);'); > > window.jsTestIsAsync = true; > window.successfullyParsed = true; >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-createOffer-expected.txt b/LayoutTests/fast/mediastream/RTCPeerConnection-createOffer-expected.txt >deleted file mode 100644 >index 3739292b5dc2c60fe78650ae5343522dc2959c20..0000000000000000000000000000000000000000 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-createOffer-expected.txt >+++ /dev/null >@@ -1,14 +0,0 @@ >-Tests RTCPeerConnection createOffer. >- >-On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE". >- >- >-PASS pc.createOffer(requestSucceeded1, requestFailed1); did not throw exception. >-PASS createOffer request succeeded. >-PASS sessionDescription.type is "offer" >-FAIL pc.createOffer(requestSucceeded2, requestFailed2, {}); should throw an exception. Was [object Promise]. >-FAIL createOffer request succeeded. >-PASS successfullyParsed is true >- >-TEST COMPLETE >- >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-createOffer.html b/LayoutTests/fast/mediastream/RTCPeerConnection-createOffer.html >deleted file mode 100644 >index 1d5e8ec0a31b59f9bbda1f87f6f49f1b41ca8429..0000000000000000000000000000000000000000 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-createOffer.html >+++ /dev/null >@@ -1,118 +0,0 @@ >-<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> >-<html> >- <head> >- <script src="../../resources/js-test-pre.js"></script> >- </head> >- <body> >- <script> >- description("Tests RTCPeerConnection createOffer."); >- >- // Let's ensure built-ins are shielded from user scripts >- var thenPromise = Promise.prototype.then; >- Promise.prototype.then = function() { >- console.log("Promise.prototype.then is called internally"); >- return thenPromise.apply(this, arguments); >- } >- >- var pc = null; >- >- function requestSucceeded3(sd) >- { >- testPassed('createOffer request succeeded.'); >- >- sessionDescription = sd; >- shouldBe('sessionDescription.type', '"offer"'); >- finishJSTest(); >- } >- >- function requestFailed7(reason) >- { >- testPassed('createOffer request failed.'); >- >- errorReason = reason; >- shouldBe('errorReason.name', '"Invalid createOffer argument."'); >- >- shouldNotThrow('pc.createOffer(requestSucceeded3, requestFailed1, {requestIdentity:"yes", offerToReceiveVideo:0, offerToReceiveAudio:0});'); >- } >- >- function requestFailed6(reason) >- { >- testPassed('createOffer request failed.'); >- >- errorReason = reason; >- shouldBe('errorReason.name', '"Invalid createOffer argument."'); >- >- shouldThrow('pc.createOffer(requestSucceeded2, requestFailed7, {requestIdentity:"yes", offerToReceiveVideo:0, offerToReceiveAudio:""});'); >- } >- >- function requestFailed5(reason) >- { >- testPassed('createOffer request failed.'); >- >- errorReason = reason; >- shouldBe('errorReason.name', '"Invalid createOffer argument."'); >- >- shouldThrow('pc.createOffer(requestSucceeded2, requestFailed6, {requestIdentity:"yes", offerToReceiveVideo:"", offerToReceiveAudio:0});'); >- } >- >- function requestFailed4(reason) >- { >- testPassed('createOffer request failed.'); >- >- errorReason = reason; >- shouldBe('errorReason.name', '"Invalid createOffer argument."'); >- >- shouldThrow('pc.createOffer(requestSucceeded2, requestFailed5, {offerToReceiveVideo:0, offerToReceiveAudio:0});'); >- } >- >- function requestFailed3(reason) >- { >- testPassed('createOffer request failed.'); >- >- errorReason = reason; >- shouldBe('errorReason.name', '"Invalid createOffer argument."'); >- >- shouldThrow('pc.createOffer(requestSucceeded2, requestFailed4, {requestIdentity:"yes", offerToReceiveVideo:0});'); >- } >- >- function requestFailed2(reason) >- { >- testPassed('createOffer request failed.'); >- >- errorReason = reason; >- shouldBe('errorReason.name', '"Invalid createOffer argument."'); >- >- shouldThrow('pc.createOffer(requestSucceeded2, requestFailed3, {requestIdentity:"yes", offerToReceiveAudio:0});'); >- } >- >- function requestSucceeded2(sd) >- { >- testFailed('createOffer request succeeded.'); >- finishJSTest(); >- } >- >- function requestFailed1() >- { >- testFailed('createOffer request failed.'); >- finishJSTest(); >- } >- >- function requestSucceeded1(sd) >- { >- testPassed('createOffer request succeeded.'); >- >- sessionDescription = sd; >- shouldBe('sessionDescription.type', '"offer"'); >- >- shouldThrow('pc.createOffer(requestSucceeded2, requestFailed2, {});'); >- } >- >- pc = new RTCPeerConnection({iceServers:[{urls:'stun:foo.com'}]}); >- shouldNotThrow('pc.createOffer(requestSucceeded1, requestFailed1);'); >- >- window.jsTestIsAsync = true; >- window.successfullyParsed = true; >- </script> >- <script src="../../resources/js-test-post.js"></script> >- </body> >-</html> >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-dtmf.html b/LayoutTests/fast/mediastream/RTCPeerConnection-dtmf.html >deleted file mode 100644 >index ce528b42f2bce2bfc9df7d19e4ca0d123d39744b..0000000000000000000000000000000000000000 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-dtmf.html >+++ /dev/null >@@ -1,82 +0,0 @@ >-<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> >-<html> >- <head> >- <script src="../../resources/js-test-pre.js"></script> >- </head> >- <body> >- <script> >- description("Tests RTCDTMFSender."); >- >- var pc = null; >- var stream = null; >- var dtmfsender = null; >- >- function error() { >- testFailed('Error callback called.'); >- finishJSTest(); >- } >- >- var lastCall = false; >- var callCount = 1; >- >- function ontonechange(e) { >- event = e; >- testPassed("ontonechange was called " + event.tone); >- if (!lastCall) { >- callCount++; >- if (8 == callCount) >- lastCall = true; >- } else { >- shouldBeEmptyString('event.tone'); >- finishJSTest(); >- } >- } >- >- function pc_onicechange() { >- if (pc.iceConnectionState === "completed") { >- testPassed("pc is connected"); >- track = stream.getAudioTracks()[0]; >- >- shouldThrow('dtmfsender = pc.createDTMFSender(track);'); >- pc.addStream(stream); >- shouldNotThrow('dtmfsender = pc.createDTMFSender(track);'); >- shouldBeTrue('dtmfsender.canInsertDTMF'); >- >- dtmfsender.ontonechange = ontonechange; >- dtmfsender.insertDTMF("1"); >- shouldBe('dtmfsender.duration', "100"); >- shouldBe('dtmfsender.interToneGap', "70"); >- >- dtmfsender.insertDTMF("4", "40", "30"); >- shouldBe('dtmfsender.duration', "40"); >- shouldBe('dtmfsender.interToneGap', "30"); >- >- dtmfsender.insertDTMF("123", "6000"); >- shouldBe('dtmfsender.duration', "6000"); >- shouldBe('dtmfsender.interToneGap', "70"); >- >- shouldThrow('dtmfsender.insertDTMF("1", "20");'); >- shouldThrow('dtmfsender.insertDTMF("1", "7000");'); >- shouldThrow('dtmfsender.insertDTMF("1", "70", "10");'); >- >- } >- } >- >- function gotStream(s) { >- stream = s; >- testPassed('Stream generated.'); >- shouldBe('stream.getAudioTracks().length', '1'); >- shouldBe('stream.getVideoTracks().length', '0'); >- >- pc = new RTCPeerConnection({iceServers:[{urls:'stun:foo.com'}]}); >- pc.oniceconnectionstatechange = pc_onicechange; >- } >- >- shouldNotThrow("navigator.webkitGetUserMedia({audio:true}, gotStream, error);"); >- >- window.jsTestIsAsync = true; >- window.successfullyParsed = true; >- </script> >- <script src="../../resources/js-test-post.js"></script> >- </body> >-</html> >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-events-expected.txt b/LayoutTests/fast/mediastream/RTCPeerConnection-events-expected.txt >deleted file mode 100644 >index 091cb7d8e8bdbc20cc0a78e2202dbbc912993365..0000000000000000000000000000000000000000 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-events-expected.txt >+++ /dev/null >@@ -1,10 +0,0 @@ >-Tests that RTCPeerConnection event callbacks are async so that for example close can be called safely. The order of the messages is very important. >- >-On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE". >- >- >-FAIL webkitGetUserMedia threw exception :TypeError: navigator.webkitGetUserMedia is not a function. (In 'navigator.webkitGetUserMedia(dictionary, callback, error)', 'navigator.webkitGetUserMedia' is undefined) >-PASS successfullyParsed is true >- >-TEST COMPLETE >- >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-events.html b/LayoutTests/fast/mediastream/RTCPeerConnection-events.html >deleted file mode 100644 >index 96e58d947d829076e336745ff67203c5ee6749f6..0000000000000000000000000000000000000000 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-events.html >+++ /dev/null >@@ -1,58 +0,0 @@ >-<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> >-<html> >- <head> >- <script src="../../resources/js-test-pre.js"></script> >- </head> >- <body> >- <script> >- description("Tests that RTCPeerConnection event callbacks are async so that for example close can be called safely. The order of the messages is very important."); >- >- var stream = null; >- var pc = null; >- >- function error() { >- testFailed('Stream generation failed.'); >- finishJSTest(); >- } >- >- function getUserMedia(dictionary, callback) { >- try { >- navigator.webkitGetUserMedia(dictionary, callback, error); >- } catch (e) { >- testFailed('webkitGetUserMedia threw exception :' + e); >- finishJSTest(); >- } >- } >- >- function onStateChange(event) { >- testPassed('onStateChange was called.'); >- shouldBe("pc.signalingState", "'closed'"); >- finishJSTest(); >- } >- >- function onNegotiationNeeded(event) { >- testPassed('onNegotiationNeeded was called.'); >- pc.onsignalingstatechange = onStateChange; >- pc.close(); >- testPassed('onNegotiationNeeded done.') >- } >- >- function gotStream(s) { >- testPassed('gotStream was called.'); >- stream = s; >- >- pc = new RTCPeerConnection({iceServers:[{urls:'stun:foo.com'}]}); >- pc.onnegotiationneeded = onNegotiationNeeded; >- >- pc.addStream(stream); >- testPassed('gotStream done.'); >- } >- >- getUserMedia({audio:true, video:true}, gotStream); >- >- window.jsTestIsAsync = true; >- window.successfullyParsed = true; >- </script> >- <script src="../../resources/js-test-post.js"></script> >- </body> >-</html> >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-have-local-offer-expected.txt b/LayoutTests/fast/mediastream/RTCPeerConnection-have-local-offer-expected.txt >index 01b1b8441f6453b794503b90fd27cc0d0d0cd426..a015684a5903bb55601ca45e060e4fa8e433779c 100644 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-have-local-offer-expected.txt >+++ b/LayoutTests/fast/mediastream/RTCPeerConnection-have-local-offer-expected.txt >@@ -4,7 +4,7 @@ On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE > > > PASS pc.signalingState is "stable" >-PASS pc.setLocalDescription(sessionDescription, requestSucceeded1, finishIfFailed); did not throw exception. >+PASS pc.setLocalDescription(sessionDescription).then(requestSucceeded1, finishIfFailed); did not throw exception. > FAIL setRemoteDescription failed. > PASS successfullyParsed is true > >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-have-local-offer.html b/LayoutTests/fast/mediastream/RTCPeerConnection-have-local-offer.html >index dea481dc19538a0a884c8558d5c2f268eab2e03e..530de6ee7e16787c7bb47f914803caca7e03e9cc 100644 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-have-local-offer.html >+++ b/LayoutTests/fast/mediastream/RTCPeerConnection-have-local-offer.html >@@ -21,7 +21,7 @@ > testPassed('setLocalDescription succeeded.'); > check("offer", "local", "", "", '"have-local-offer"'); > sessionDescription = new RTCSessionDescription({type:"answer", sdp:"remote"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, requestSucceeded5, finishIfFailed);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(requestSucceeded5, finishIfFailed);'); > } > > function requestSucceeded3() >@@ -31,7 +31,7 @@ > pc = new RTCPeerConnection({iceServers:[{urls:'stun:foo.com'}]}); > check("", "", "", "", '"stable"'); > sessionDescription = new RTCSessionDescription({type:"offer", sdp:"local"}); >- shouldNotThrow('pc.setLocalDescription(sessionDescription, requestSucceeded4, finishIfFailed);'); >+ shouldNotThrow('pc.setLocalDescription(sessionDescription).then(requestSucceeded4, finishIfFailed);'); > } > > function requestSucceeded2() >@@ -39,7 +39,7 @@ > testPassed('setLocalDescription succeeded.'); > check("offer", "local", "", "", '"have-local-offer"'); > sessionDescription = new RTCSessionDescription({type:"pranswer", sdp:"remote"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, requestSucceeded3, finishIfFailed);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(requestSucceeded3, finishIfFailed);'); > } > > function requestFailed3(reason) >@@ -49,7 +49,7 @@ > shouldBe('errorReason.name', '"InvalidSessionDescriptionError"'); > check("offer", "local", "", "", '"have-local-offer"'); > sessionDescription = new RTCSessionDescription({type:"offer", sdp:"local"}); >- shouldNotThrow('pc.setLocalDescription(sessionDescription, requestSucceeded2, finishIfFailed);'); >+ shouldNotThrow('pc.setLocalDescription(sessionDescription).then(requestSucceeded2, finishIfFailed);'); > } > > function requestFailed2(reason) >@@ -59,7 +59,7 @@ > shouldBe('errorReason.name', '"InvalidSessionDescriptionError"'); > check("offer", "local", "", "", '"have-local-offer"'); > sessionDescription = new RTCSessionDescription({type:"offer", sdp:"remote"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, finishIfSucceeded, requestFailed3);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(finishIfSucceeded, requestFailed3);'); > } > > function requestFailed1(reason) >@@ -69,7 +69,7 @@ > shouldBe('errorReason.name', '"InvalidSessionDescriptionError"'); > check("offer", "local", "", "", '"have-local-offer"'); > sessionDescription = new RTCSessionDescription({type:"pranswer", sdp:"local"}); >- shouldNotThrow('pc.setLocalDescription(sessionDescription, finishIfSucceeded, requestFailed2);'); >+ shouldNotThrow('pc.setLocalDescription(sessionDescription).then(finishIfSucceeded, requestFailed2);'); > } > > function requestSucceeded1() >@@ -77,7 +77,7 @@ > testPassed('setLocalDescription succeeded.'); > check("offer", "local", "", "", '"have-local-offer"'); > sessionDescription = new RTCSessionDescription({type:"answer", sdp:"local"}); >- shouldNotThrow('pc.setLocalDescription(sessionDescription, finishIfSucceeded, requestFailed1);'); >+ shouldNotThrow('pc.setLocalDescription(sessionDescription).then(finishIfSucceeded, requestFailed1);'); > } > > function finishIfSucceeded() >@@ -112,7 +112,7 @@ > pc = new RTCPeerConnection({iceServers:[{urls:'stun:foo.com'}]}); > shouldBe('pc.signalingState', '"stable"'); > var sessionDescription = new RTCSessionDescription({type:"offer", sdp:"local"}); >- shouldNotThrow('pc.setLocalDescription(sessionDescription, requestSucceeded1, finishIfFailed);'); >+ shouldNotThrow('pc.setLocalDescription(sessionDescription).then(requestSucceeded1, finishIfFailed);'); > > window.jsTestIsAsync = true; > window.successfullyParsed = true; >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-have-local-pranswer-expected.txt b/LayoutTests/fast/mediastream/RTCPeerConnection-have-local-pranswer-expected.txt >index 1b011d15559f0aaa56eb13270a3a8fb80ebe9787..fa7dfa2624c0fd1cf1ff49fd47557ae54a2d2d79 100644 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-have-local-pranswer-expected.txt >+++ b/LayoutTests/fast/mediastream/RTCPeerConnection-have-local-pranswer-expected.txt >@@ -4,7 +4,7 @@ On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE > > > PASS pc.signalingState is "stable" >-PASS pc.setRemoteDescription(sessionDescription, requestSucceeded1, finishIfFailed); did not throw exception. >+PASS pc.setRemoteDescription(sessionDescription).then(requestSucceeded1, finishIfFailed); did not throw exception. > FAIL setRemoteDescription failed. > PASS successfullyParsed is true > >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-have-local-pranswer.html b/LayoutTests/fast/mediastream/RTCPeerConnection-have-local-pranswer.html >index 4825bd4807e4548fa15e1a552f4971b807ee15fb..cf45f5a5143e208885bfe4c1c8f52e63100af9e8 100644 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-have-local-pranswer.html >+++ b/LayoutTests/fast/mediastream/RTCPeerConnection-have-local-pranswer.html >@@ -23,7 +23,7 @@ > shouldBe('errorReason.name', '"InvalidSessionDescriptionError"'); > check("pranswer", "local", "offer", "remote", '"have-local-pranswer"'); > sessionDescription = new RTCSessionDescription({type:"answer", sdp:"local"}); >- shouldNotThrow('pc.setLocalDescription(sessionDescription, requestSucceeded4, finishIfFailed);'); >+ shouldNotThrow('pc.setLocalDescription(sessionDescription).then(requestSucceeded4, finishIfFailed);'); > } > > function requestFailed3(reason) >@@ -33,7 +33,7 @@ > shouldBe('errorReason.name', '"InvalidSessionDescriptionError"'); > check("pranswer", "local", "offer", "remote", '"have-local-pranswer"'); > sessionDescription = new RTCSessionDescription({type:"pranswer", sdp:"remote"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, finishIfSucceeded, requestFailed4);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(finishIfSucceeded, requestFailed4);'); > } > > function requestFailed2(reason) >@@ -43,7 +43,7 @@ > shouldBe('errorReason.name', '"InvalidSessionDescriptionError"'); > check("pranswer", "local", "offer", "remote", '"have-local-pranswer"'); > sessionDescription = new RTCSessionDescription({type:"answer", sdp:"remote"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, finishIfSucceeded, requestFailed3);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(finishIfSucceeded, requestFailed3);'); > } > > function requestFailed1(reason) >@@ -53,7 +53,7 @@ > shouldBe('errorReason.name', '"InvalidSessionDescriptionError"'); > check("pranswer", "local", "offer", "remote", '"have-local-pranswer"'); > sessionDescription = new RTCSessionDescription({type:"offer", sdp:"remote"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, finishIfSucceeded, requestFailed2);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(finishIfSucceeded, requestFailed2);'); > } > > function requestSucceeded3() >@@ -61,7 +61,7 @@ > testPassed('setLocalDescription succeeded.'); > check("pranswer", "local", "offer", "remote", '"have-local-pranswer"'); > sessionDescription = new RTCSessionDescription({type:"offer", sdp:"local"}); >- shouldNotThrow('pc.setLocalDescription(sessionDescription, finishIfSucceeded, requestFailed1);'); >+ shouldNotThrow('pc.setLocalDescription(sessionDescription).then(finishIfSucceeded, requestFailed1);'); > } > > function requestSucceeded2() >@@ -69,7 +69,7 @@ > testPassed('setLocalDescription succeeded.'); > check("pranswer", "local", "offer", "remote", '"have-local-pranswer"'); > sessionDescription = new RTCSessionDescription({type:"pranswer", sdp:"local"}); >- shouldNotThrow('pc.setLocalDescription(sessionDescription, requestSucceeded3, finishIfFailed);'); >+ shouldNotThrow('pc.setLocalDescription(sessionDescription).then(requestSucceeded3, finishIfFailed);'); > } > > function requestSucceeded1() >@@ -77,7 +77,7 @@ > testPassed('setRemoteDescription succeeded.'); > check("", "", "offer", "remote", '"have-remote-offer"'); > sessionDescription = new RTCSessionDescription({type:"pranswer", sdp:"local"}); >- shouldNotThrow('pc.setLocalDescription(sessionDescription, requestSucceeded2, finishIfFailed);'); >+ shouldNotThrow('pc.setLocalDescription(sessionDescription).then(requestSucceeded2, finishIfFailed);'); > } > > function finishIfSucceeded() >@@ -108,7 +108,7 @@ > pc = new RTCPeerConnection({iceServers:[{urls:'stun:foo.com'}]}); > shouldBe('pc.signalingState', '"stable"'); > var sessionDescription = new RTCSessionDescription({type:"offer", sdp:"remote"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, requestSucceeded1, finishIfFailed);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(requestSucceeded1, finishIfFailed);'); > > window.jsTestIsAsync = true; > window.successfullyParsed = true; >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-have-remote-offer-expected.txt b/LayoutTests/fast/mediastream/RTCPeerConnection-have-remote-offer-expected.txt >index 37c50e3a5617c9d570be5f6efc81f04a09fe978b..ff4f24d1567f473408ccd59ca4669f654d41d692 100644 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-have-remote-offer-expected.txt >+++ b/LayoutTests/fast/mediastream/RTCPeerConnection-have-remote-offer-expected.txt >@@ -4,7 +4,7 @@ On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE > > > PASS pc.signalingState is "stable" >-PASS pc.setRemoteDescription(sessionDescription, requestSucceeded1, finishIfFailed); did not throw exception. >+PASS pc.setRemoteDescription(sessionDescription).then(requestSucceeded1, finishIfFailed); did not throw exception. > FAIL setRemoteDescription failed. > PASS successfullyParsed is true > >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-have-remote-offer.html b/LayoutTests/fast/mediastream/RTCPeerConnection-have-remote-offer.html >index fd5bf88df88e05c78f8c8c0a7c094d076f45bc92..2f5637c8fd245016dd37bf64f2de76b47e77f246 100644 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-have-remote-offer.html >+++ b/LayoutTests/fast/mediastream/RTCPeerConnection-have-remote-offer.html >@@ -21,7 +21,7 @@ > testPassed('setRemoteDescription succeeded.'); > check("", "", "offer", "remote", '"have-remote-offer"'); > sessionDescription = new RTCSessionDescription({type:"pranswer", sdp:"local"}); >- shouldNotThrow('pc.setLocalDescription(sessionDescription, requestSucceeded5, finishIfFailed);'); >+ shouldNotThrow('pc.setLocalDescription(sessionDescription).then(requestSucceeded5, finishIfFailed);'); > } > > function requestSucceeded3() >@@ -31,7 +31,7 @@ > pc = new RTCPeerConnection({iceServers:[{urls:'stun:foo.com'}]}); > check("", "", "", "", '"stable"'); > sessionDescription = new RTCSessionDescription({type:"offer", sdp:"remote"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, requestSucceeded4, finishIfFailed);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(requestSucceeded4, finishIfFailed);'); > } > > function requestSucceeded2() >@@ -39,7 +39,7 @@ > testPassed('setRemoteDescription succeeded.'); > check("", "", "offer", "remote", '"have-remote-offer"'); > sessionDescription = new RTCSessionDescription({type:"answer", sdp:"local"}); >- shouldNotThrow('pc.setLocalDescription(sessionDescription, requestSucceeded3, finishIfFailed);'); >+ shouldNotThrow('pc.setLocalDescription(sessionDescription).then(requestSucceeded3, finishIfFailed);'); > } > > function requestFailed3(reason) >@@ -49,7 +49,7 @@ > shouldBe('errorReason.name', '"InvalidSessionDescriptionError"'); > check("", "", "offer", "remote", '"have-remote-offer"'); > sessionDescription = new RTCSessionDescription({type:"offer", sdp:"remote"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, requestSucceeded2, finishIfFailed);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(requestSucceeded2, finishIfFailed);'); > } > > function requestFailed2(reason) >@@ -59,7 +59,7 @@ > shouldBe('errorReason.name', '"InvalidSessionDescriptionError"'); > check("", "", "offer", "remote", '"have-remote-offer"'); > sessionDescription = new RTCSessionDescription({type:"answer", sdp:"remote"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, finishIfSucceeded, requestFailed3);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(finishIfSucceeded, requestFailed3);'); > } > > function requestFailed1(reason) >@@ -69,7 +69,7 @@ > shouldBe('errorReason.name', '"InvalidSessionDescriptionError"'); > check("", "", "offer", "remote", '"have-remote-offer"'); > sessionDescription = new RTCSessionDescription({type:"pranswer", sdp:"remote"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, finishIfSucceeded, requestFailed2);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(finishIfSucceeded, requestFailed2);'); > } > > function requestSucceeded1() >@@ -77,7 +77,7 @@ > testPassed('setRemoteDescription succeeded.'); > check("", "", "offer", "remote", '"have-remote-offer"'); > sessionDescription = new RTCSessionDescription({type:"offer", sdp:"local"}); >- shouldNotThrow('pc.setLocalDescription(sessionDescription, finishIfSucceeded, requestFailed1);'); >+ shouldNotThrow('pc.setLocalDescription(sessionDescription).then(finishIfSucceeded, requestFailed1);'); > } > > function finishIfSucceeded() >@@ -112,7 +112,7 @@ > pc = new RTCPeerConnection({iceServers:[{urls:'stun:foo.com'}]}); > shouldBe('pc.signalingState', '"stable"'); > var sessionDescription = new RTCSessionDescription({type:"offer", sdp:"remote"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, requestSucceeded1, finishIfFailed);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(requestSucceeded1, finishIfFailed);'); > > window.jsTestIsAsync = true; > window.successfullyParsed = true; >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-have-remote-pranswer-expected.txt b/LayoutTests/fast/mediastream/RTCPeerConnection-have-remote-pranswer-expected.txt >index 1cfd6bd69961899f5247b9fd3fa827cc820f8e79..17a59b2be4c04e8bc1ad24baaef8ecf775c47ba5 100644 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-have-remote-pranswer-expected.txt >+++ b/LayoutTests/fast/mediastream/RTCPeerConnection-have-remote-pranswer-expected.txt >@@ -4,7 +4,7 @@ On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE > > > PASS pc.signalingState is "stable" >-PASS pc.setLocalDescription(sessionDescription, requestSucceeded1, finishIfFailed); did not throw exception. >+PASS pc.setLocalDescription(sessionDescription).then(requestSucceeded1, finishIfFailed); did not throw exception. > FAIL setRemoteDescription failed. > PASS successfullyParsed is true > >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-have-remote-pranswer.html b/LayoutTests/fast/mediastream/RTCPeerConnection-have-remote-pranswer.html >index df3de0073f09350af126242165393391a955d88f..2ccc1f09cc4e7d4fb024d578f9b5df456addec05 100644 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-have-remote-pranswer.html >+++ b/LayoutTests/fast/mediastream/RTCPeerConnection-have-remote-pranswer.html >@@ -23,7 +23,7 @@ > shouldBe('errorReason.name', '"InvalidSessionDescriptionError"'); > check("offer", "local", "pranswer", "remote", '"have-remote-pranswer"'); > sessionDescription = new RTCSessionDescription({type:"answer", sdp:"remote"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, requestSucceeded4, finishIfFailed);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(requestSucceeded4, finishIfFailed);'); > } > > function requestFailed3(reason) >@@ -33,7 +33,7 @@ > shouldBe('errorReason.name', '"InvalidSessionDescriptionError"'); > check("offer", "local", "pranswer", "remote", '"have-remote-pranswer"'); > sessionDescription = new RTCSessionDescription({type:"pranswer", sdp:"local"}); >- shouldNotThrow('pc.setLocalDescription(sessionDescription, finishIfSucceeded, requestFailed4);'); >+ shouldNotThrow('pc.setLocalDescription(sessionDescription).then(finishIfSucceeded, requestFailed4);'); > } > > function requestFailed2(reason) >@@ -43,7 +43,7 @@ > shouldBe('errorReason.name', '"InvalidSessionDescriptionError"'); > check("offer", "local", "pranswer", "remote", '"have-remote-pranswer"'); > sessionDescription = new RTCSessionDescription({type:"answer", sdp:"local"}); >- shouldNotThrow('pc.setLocalDescription(sessionDescription, finishIfSucceeded, requestFailed3);'); >+ shouldNotThrow('pc.setLocalDescription(sessionDescription).then(finishIfSucceeded, requestFailed3);'); > } > > function requestFailed1(reason) >@@ -53,7 +53,7 @@ > shouldBe('errorReason.name', '"InvalidSessionDescriptionError"'); > check("offer", "local", "pranswer", "remote", '"have-remote-pranswer"'); > sessionDescription = new RTCSessionDescription({type:"offer", sdp:"local"}); >- shouldNotThrow('pc.setLocalDescription(sessionDescription, finishIfSucceeded, requestFailed2);'); >+ shouldNotThrow('pc.setLocalDescription(sessionDescription).then(finishIfSucceeded, requestFailed2);'); > } > > function requestSucceeded3() >@@ -61,7 +61,7 @@ > testPassed('setRemoteDescription succeeded.'); > check("offer", "local", "pranswer", "remote", '"have-remote-pranswer"'); > sessionDescription = new RTCSessionDescription({type:"offer", sdp:"remote"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, finishIfSucceeded, requestFailed1);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(finishIfSucceeded, requestFailed1);'); > } > > function requestSucceeded2() >@@ -69,7 +69,7 @@ > testPassed('setRemoteDescription succeeded.'); > check("offer", "local", "pranswer", "remote", '"have-remote-pranswer"'); > sessionDescription = new RTCSessionDescription({type:"pranswer", sdp:"remote"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, requestSucceeded3, finishIfFailed);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(requestSucceeded3, finishIfFailed);'); > } > > function requestSucceeded1() >@@ -77,7 +77,7 @@ > testPassed('setLocalDescription succeeded.'); > check("offer", "local", "", "", '"have-local-offer"'); > sessionDescription = new RTCSessionDescription({type:"pranswer", sdp:"remote"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, requestSucceeded2, finishIfFailed);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(requestSucceeded2, finishIfFailed);'); > } > > function finishIfSucceeded() >@@ -108,7 +108,7 @@ > pc = new RTCPeerConnection({iceServers:[{urls:'stun:foo.com'}]}); > shouldBe('pc.signalingState', '"stable"'); > var sessionDescription = new RTCSessionDescription({type:"offer", sdp:"local"}); >- shouldNotThrow('pc.setLocalDescription(sessionDescription, requestSucceeded1, finishIfFailed);'); >+ shouldNotThrow('pc.setLocalDescription(sessionDescription).then(requestSucceeded1, finishIfFailed);'); > > window.jsTestIsAsync = true; > window.successfullyParsed = true; >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-legacy-stream-based-api-expected.txt b/LayoutTests/fast/mediastream/RTCPeerConnection-legacy-stream-based-api-expected.txt >deleted file mode 100644 >index a8d811791416584c461a17e31f7ac9c881369192..0000000000000000000000000000000000000000 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-legacy-stream-based-api-expected.txt >+++ /dev/null >@@ -1,57 +0,0 @@ >-Test RTCPeerConnection's legacy MediaStream-based API >- >-On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE". >- >- >-Stream sets should be empty initially >-PASS pc.getLocalStreams().length is 0 >-PASS pc.getRemoteStreams().length is 0 >- >-Test with single track MediaStream >-audioTrack = stream.getAudioTracks()[0] >-PASS pc.addStream(stream) did not throw exception. >-PASS pc.getLocalStreams().length is 1 >-PASS pc.getLocalStreams()[0] is stream >-PASS pc.getStreamById(stream.id) is stream >-PASS pc.getSenders().length is 1 >-PASS pc.getSenders()[0].track is audioTrack >-Adding the same stream again should be a no-op >-PASS pc.addStream(stream) did not throw exception. >-PASS pc.getLocalStreams().length is 1 >- >-Test with audio and video MediaStream >-audioTrack = stream.getAudioTracks()[0] >-videoTrack = stream.getVideoTracks()[0] >-PASS pc.addStream(stream) did not throw exception. >-PASS pc.getLocalStreams().length is 2 >-PASS pc.getLocalStreams().includes(stream) is true >-PASS pc.getStreamById(stream.id) is stream >-PASS pc.getSenders().length is 3 >-PASS audioTrackFoundAmongSenders is true >-PASS videoTrackFoundAmongSenders is true >- >-Test removeStream >-Remove a non-existent stream >-otherStream = stream.clone() >-PASS pc.removeStream(otherStream) did not throw exception. >-Both streams should still be present >-PASS pc.getLocalStreams().length is 2 >-PASS pc.removeStream(stream) did not throw exception. >-PASS pc.getLocalStreams().length is 1 >-PASS pc.getStreamById(stream.id) is null >-All senders should still be present >-PASS pc.getSenders().length is 3 >-Removing the same stream again should be a no-op >-PASS pc.removeStream(stream) did not throw exception. >-PASS pc.getLocalStreams().length is 1 >- >-Test applying a remote description offering a stream with two tracks >-Create remote offer >-Got remote offer, set it >-Remote offer set >-PASS End of test promise chain >- >-PASS successfullyParsed is true >- >-TEST COMPLETE >- >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-legacy-stream-based-api.html b/LayoutTests/fast/mediastream/RTCPeerConnection-legacy-stream-based-api.html >deleted file mode 100644 >index 7a21156b8927c978ef038fe121a79108da8d9007..0000000000000000000000000000000000000000 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-legacy-stream-based-api.html >+++ /dev/null >@@ -1,144 +0,0 @@ >-<!DOCTYPE html> >-<html> >- <head> >- <script src="../../resources/js-test-pre.js"></script> >- </head> >- <body> >- <script> >- if (window.internals) >- internals.useMockRTCPeerConnectionFactory(""); >- >- description("Test RTCPeerConnection's legacy MediaStream-based API"); >- >- let stream; >- let otherStream; >- let audioTrack; >- let videoTrack; >- let audioTrackFoundAmongSenders; >- let videoTrackFoundAmongSenders; >- let remoteStream; >- >- if (window.testRunner) >- testRunner.setUserMediaPermission(true); >- else { >- debug("This test can not be run without the testRunner"); >- finishJSTest(); >- } >- >- const pc = new RTCPeerConnection({iceServers:[{urls:'stun:foo.com'}]}); >- const remotePc = new RTCPeerConnection({iceServers:[{urls:'stun:foo.com'}]}); >- >- debug("Stream sets should be empty initially") >- shouldBe("pc.getLocalStreams().length", "0"); >- shouldBe("pc.getRemoteStreams().length", "0"); >- >- pc.onaddstream = evt => { >- testPassed("Got 'addstream' event (before setRemoteDescription promise fulfilled)"); >- remoteStream = evt.stream; >- >- shouldBe("remoteStream.getTracks().length", "2"); >- >- shouldBe("pc.getRemoteStreams().length", "1"); >- shouldBe("pc.getRemoteStreams()[0]", "remoteStream"); >- >- shouldBe("pc.getStreamById(remoteStream.id)", "remoteStream"); >- }; >- >- navigator.mediaDevices.getUserMedia({ "audio": true }) >- .then(s => { >- stream = s; >- >- debug("<br>Test with single track MediaStream"); >- evalAndLog("audioTrack = stream.getAudioTracks()[0]"); >- shouldNotThrow("pc.addStream(stream)"); >- >- shouldBe("pc.getLocalStreams().length", "1"); >- shouldBe("pc.getLocalStreams()[0]", "stream"); >- >- shouldBe("pc.getStreamById(stream.id)", "stream"); >- >- shouldBe("pc.getSenders().length", "1"); >- shouldBe("pc.getSenders()[0].track", "audioTrack"); >- >- debug("Adding the same stream again should be a no-op"); >- shouldNotThrow("pc.addStream(stream)"); >- shouldBe("pc.getLocalStreams().length", "1"); >- >- return navigator.mediaDevices.getUserMedia({ "audio": true, "video": true }); >- }) >- .then(s => { >- stream = s; >- >- debug("<br>Test with audio and video MediaStream"); >- evalAndLog("audioTrack = stream.getAudioTracks()[0]"); >- evalAndLog("videoTrack = stream.getVideoTracks()[0]"); >- >- shouldNotThrow("pc.addStream(stream)"); >- >- shouldBe("pc.getLocalStreams().length", "2"); >- shouldBeTrue("pc.getLocalStreams().includes(stream)"); >- >- shouldBe("pc.getStreamById(stream.id)", "stream"); >- >- shouldBe("pc.getSenders().length", "3"); >- >- audioTrackFoundAmongSenders = false; >- videoTrackFoundAmongSenders = false; >- pc.getSenders().forEach(sender => { >- if (sender.track === audioTrack) >- audioTrackFoundAmongSenders = true; >- else if (sender.track === videoTrack) >- videoTrackFoundAmongSenders = true; >- }); >- >- shouldBeTrue("audioTrackFoundAmongSenders"); >- shouldBeTrue("videoTrackFoundAmongSenders"); >- >- debug("<br>Test removeStream"); >- debug("Remove a non-existent stream"); >- evalAndLog("otherStream = stream.clone()"); >- shouldNotThrow("pc.removeStream(otherStream)"); >- >- debug("Both streams should still be present"); >- shouldBe("pc.getLocalStreams().length", "2"); >- >- shouldNotThrow("pc.removeStream(stream)"); >- >- shouldBe("pc.getLocalStreams().length", "1"); >- shouldBe("pc.getStreamById(stream.id)", "null"); >- >- debug("All senders should still be present") >- shouldBe("pc.getSenders().length", "3"); >- >- debug("Removing the same stream again should be a no-op"); >- shouldNotThrow("pc.removeStream(stream)"); >- shouldBe("pc.getLocalStreams().length", "1"); >- >- debug("<br>Test applying a remote description offering a stream with two tracks"); >- remotePc.addStream(stream); >- >- debug("Create remote offer"); >- return remotePc.createOffer(); >- }) >- .then(remoteOffer => { >- debug("Got remote offer, set it"); >- return pc.setRemoteDescription(remoteOffer); >- }) >- .then(() => { >- debug("Remote offer set"); >- testPassed("End of test promise chain"); >- debug(""); >- >- finishJSTest(); >- }) >- .catch(error => { >- testFailed("Error in promise chain: " + error); >- finishJSTest(); >- }); >- >- window.jsTestIsAsync = true; >- window.successfullyParsed = true; >- </script> >- <script src="../../resources/js-test-post.js"></script> >- </body> >-</html> >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-localDescription-expected.txt b/LayoutTests/fast/mediastream/RTCPeerConnection-localDescription-expected.txt >index 630275179c9a3f9f906b76d37cd246a896b2993a..cbea3dbc9a3bc72d5b3ef44b2aa4423c90644d5a 100644 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-localDescription-expected.txt >+++ b/LayoutTests/fast/mediastream/RTCPeerConnection-localDescription-expected.txt >@@ -3,7 +3,7 @@ Tests RTCPeerConnection localDescription. > On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE". > > >-PASS pc.setLocalDescription(sessionDescription, requestSucceeded1, requestFailed1); did not throw exception. >+PASS pc.setLocalDescription(sessionDescription).then(requestSucceeded1, requestFailed1); did not throw exception. > FAIL requestFailed was called. > PASS successfullyParsed is true > >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-localDescription.html b/LayoutTests/fast/mediastream/RTCPeerConnection-localDescription.html >index 13ce481223d08e8a7ae3aba2c73e2886550bbb5d..3211d0db60a2b1df0f47e82ab85d9529cce814a0 100644 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-localDescription.html >+++ b/LayoutTests/fast/mediastream/RTCPeerConnection-localDescription.html >@@ -39,12 +39,12 @@ > testPassed('requestSucceeded was called.'); > > sessionDescription = new RTCSessionDescription({type:"answer", sdp:"remote"}); >- shouldNotThrow('pc.setLocalDescription(sessionDescription, requestSucceeded2, requestFailed2);'); >+ shouldNotThrow('pc.setLocalDescription(sessionDescription).then(requestSucceeded2, requestFailed2);'); > } > > pc = new RTCPeerConnection({iceServers:[{urls:'stun:foo.com'}]}); > var sessionDescription = new RTCSessionDescription({type:"offer", sdp:"local"}); >- shouldNotThrow('pc.setLocalDescription(sessionDescription, requestSucceeded1, requestFailed1);'); >+ shouldNotThrow('pc.setLocalDescription(sessionDescription).then(requestSucceeded1, requestFailed1);'); > > > window.jsTestIsAsync = true; >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-remoteDescription-expected.txt b/LayoutTests/fast/mediastream/RTCPeerConnection-remoteDescription-expected.txt >index 462512fe5b583ecbed38f64ddea860cb891c9710..72ce19be9fb152a9309bbc0c7006658b6f248f58 100644 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-remoteDescription-expected.txt >+++ b/LayoutTests/fast/mediastream/RTCPeerConnection-remoteDescription-expected.txt >@@ -3,7 +3,7 @@ Tests RTCPeerConnection remoteDescription. > On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE". > > >-PASS pc.setRemoteDescription(sessionDescription, requestSucceeded1, requestFailed1); did not throw exception. >+PASS pc.setRemoteDescription(sessionDescription).then(requestSucceeded1, requestFailed1); did not throw exception. > FAIL requestFailed was called. > PASS successfullyParsed is true > >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-remoteDescription.html b/LayoutTests/fast/mediastream/RTCPeerConnection-remoteDescription.html >index dfefb22f2fca1acb484e58c813f815bbafd21742..aeb67c25eea7e574ddbe0e5cc6dc50bd2e9044e2 100644 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-remoteDescription.html >+++ b/LayoutTests/fast/mediastream/RTCPeerConnection-remoteDescription.html >@@ -39,12 +39,12 @@ > testPassed('requestSucceeded was called.'); > > sessionDescription = new RTCSessionDescription({type:"answer", sdp:"local"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, requestSucceeded2, requestFailed2);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(requestSucceeded2, requestFailed2);'); > } > > pc = new RTCPeerConnection({iceServers:[{urls:'stun:foo.com'}]}); > var sessionDescription = new RTCSessionDescription({type:"offer", sdp:"remote"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, requestSucceeded1, requestFailed1);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(requestSucceeded1, requestFailed1);'); > > > window.jsTestIsAsync = true; >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-stable-expected.txt b/LayoutTests/fast/mediastream/RTCPeerConnection-stable-expected.txt >index 45edeb2ab0b9256467ead75203e3167e921ed1e0..4dad6c725e9788bcf7d93af7e66aed3dadd60ffc 100644 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-stable-expected.txt >+++ b/LayoutTests/fast/mediastream/RTCPeerConnection-stable-expected.txt >@@ -4,31 +4,31 @@ On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE > > > PASS pc.signalingState is "stable" >-PASS pc.setLocalDescription(sessionDescription, finishIfSucceeded, requestFailed1); did not throw exception. >+PASS pc.setLocalDescription(sessionDescription).then(finishIfSucceeded, requestFailed1); did not throw exception. > PASS setLocalDescription failed. > FAIL errorReason.name should be InvalidSessionDescriptionError. Was InvalidStateError. > FAIL pc.localDescription should throw an exception. Was null. > FAIL pc.remoteDescription should throw an exception. Was null. > PASS pc.signalingState is "stable" >-PASS pc.setLocalDescription(sessionDescription, finishIfSucceeded, requestFailed2); did not throw exception. >+PASS pc.setLocalDescription(sessionDescription).then(finishIfSucceeded, requestFailed2); did not throw exception. > PASS setLocalDescription failed. > FAIL errorReason.name should be InvalidSessionDescriptionError. Was InvalidStateError. > FAIL pc.localDescription should throw an exception. Was null. > FAIL pc.remoteDescription should throw an exception. Was null. > PASS pc.signalingState is "stable" >-PASS pc.setRemoteDescription(sessionDescription, finishIfSucceeded, requestFailed3); did not throw exception. >+PASS pc.setRemoteDescription(sessionDescription).then(finishIfSucceeded, requestFailed3); did not throw exception. > PASS setRemoteDescription failed. > FAIL errorReason.name should be InvalidSessionDescriptionError. Was InvalidStateError. > FAIL pc.localDescription should throw an exception. Was null. > FAIL pc.remoteDescription should throw an exception. Was null. > PASS pc.signalingState is "stable" >-PASS pc.setRemoteDescription(sessionDescription, finishIfSucceeded, requestFailed4); did not throw exception. >+PASS pc.setRemoteDescription(sessionDescription).then(finishIfSucceeded, requestFailed4); did not throw exception. > PASS setRemoteDescription failed. > FAIL errorReason.name should be InvalidSessionDescriptionError. Was InvalidStateError. > FAIL pc.localDescription should throw an exception. Was null. > FAIL pc.remoteDescription should throw an exception. Was null. > PASS pc.signalingState is "stable" >-PASS pc.setLocalDescription(sessionDescription, requestSucceeded1, finishIfFailed); did not throw exception. >+PASS pc.setLocalDescription(sessionDescription).then(requestSucceeded1, finishIfFailed); did not throw exception. > FAIL setRemoteDescription failed. > PASS successfullyParsed is true > >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-stable.html b/LayoutTests/fast/mediastream/RTCPeerConnection-stable.html >index 7daa82fa539fedae9eae2572104a8f2bbb25ecc7..959cb0d0e9e55e8cc50b2008768741ca502a4fff 100644 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-stable.html >+++ b/LayoutTests/fast/mediastream/RTCPeerConnection-stable.html >@@ -9,13 +9,6 @@ > > var pc = null; > >- // Let's ensure built-ins are shielded from user scripts >- var thenPromise = Promise.prototype.then; >- Promise.prototype.then = function() { >- console.log("Promise.prototype.then is called internally"); >- return thenPromise.apply(this, arguments); >- } >- > function requestSucceeded2() > { > testPassed('setRemoteDescription succeeded.'); >@@ -30,7 +23,7 @@ > pc = new RTCPeerConnection({iceServers:[{urls:'stun:foo.com'}]}); > check("", "", "", "", '"stable"'); > sessionDescription = new RTCSessionDescription({type:"offer", sdp:"remote"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, requestSucceeded2, finishIfFailed);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(requestSucceeded2, finishIfFailed);'); > } > > function requestFailed4(reason) >@@ -40,7 +33,7 @@ > shouldBe('errorReason.name', '"InvalidSessionDescriptionError"'); > check("", "", "", "", '"stable"'); > sessionDescription = new RTCSessionDescription({type:"offer", sdp:"local"}); >- shouldNotThrow('pc.setLocalDescription(sessionDescription, requestSucceeded1, finishIfFailed);'); >+ shouldNotThrow('pc.setLocalDescription(sessionDescription).then(requestSucceeded1, finishIfFailed);'); > } > > function requestFailed3(reason) >@@ -50,7 +43,7 @@ > shouldBe('errorReason.name', '"InvalidSessionDescriptionError"'); > check("", "", "", "", '"stable"'); > sessionDescription = new RTCSessionDescription({type:"answer", sdp:"remote"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, finishIfSucceeded, requestFailed4);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(finishIfSucceeded, requestFailed4);'); > } > > function requestFailed2(reason) >@@ -60,7 +53,7 @@ > shouldBe('errorReason.name', '"InvalidSessionDescriptionError"'); > check("", "", "", "", '"stable"'); > sessionDescription = new RTCSessionDescription({type:"pranswer", sdp:"remote"}); >- shouldNotThrow('pc.setRemoteDescription(sessionDescription, finishIfSucceeded, requestFailed3);'); >+ shouldNotThrow('pc.setRemoteDescription(sessionDescription).then(finishIfSucceeded, requestFailed3);'); > } > > function requestFailed1(reason) >@@ -70,7 +63,7 @@ > shouldBe('errorReason.name', '"InvalidSessionDescriptionError"'); > check("", "", "", "", '"stable"'); > sessionDescription = new RTCSessionDescription({type:"pranswer", sdp:"local"}); >- shouldNotThrow('pc.setLocalDescription(sessionDescription, finishIfSucceeded, requestFailed2);'); >+ shouldNotThrow('pc.setLocalDescription(sessionDescription).then(finishIfSucceeded, requestFailed2);'); > } > > function finishIfSucceeded() >@@ -105,7 +98,7 @@ > pc = new RTCPeerConnection({iceServers:[{urls:'stun:foo.com'}]}); > shouldBe('pc.signalingState', '"stable"'); > var sessionDescription = new RTCSessionDescription({type:"answer", sdp:"local"}); >- shouldNotThrow('pc.setLocalDescription(sessionDescription, finishIfSucceeded, requestFailed1);'); >+ shouldNotThrow('pc.setLocalDescription(sessionDescription).then(finishIfSucceeded, requestFailed1);'); > > window.jsTestIsAsync = true; > window.successfullyParsed = true; >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-stats.html b/LayoutTests/fast/mediastream/RTCPeerConnection-stats.html >index 3c46fb2f3bd5671fcf5bee687a010727b36a576c..f58293990fbad2f2df136c934bce248568759736 100644 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-stats.html >+++ b/LayoutTests/fast/mediastream/RTCPeerConnection-stats.html >@@ -32,14 +32,14 @@ > shouldBeNonNull('status'); > result = status.result(); > shouldBe('result.length', '0'); >- shouldNotThrow('getUserMedia({audio:true, video:true}, gotStream)'); >+ shouldNotThrow('getUserMedia({audio:true, video:true}).then(gotStream)'); > } > > function gotStream(s) { > testPassed('Got a stream.'); > stream = s; > >- pc.addStream(stream); >+ pc.addTrack(stream.getVideoTracks()[0]); > // FIXME: Test getStats error callback: https://webkit.org/b/129860 > shouldNotThrow('pc.getStats().then(statsHandler2, statsError)'); > } >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-statsSelector-expected.txt b/LayoutTests/fast/mediastream/RTCPeerConnection-statsSelector-expected.txt >index 654589572b3a8f7893abb6378f87c49096ab671f..3e3a3ea90b24eb6b4806ce00a904cd82d86a5245 100644 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-statsSelector-expected.txt >+++ b/LayoutTests/fast/mediastream/RTCPeerConnection-statsSelector-expected.txt >@@ -5,7 +5,7 @@ On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE > > PASS pc = new RTCPeerConnection({iceServers:[{urls:'stun:foo.com'}]}) did not throw exception. > FAIL webkitGetUserMedia threw exception :TypeError: navigator.webkitGetUserMedia is not a function. (In 'navigator.webkitGetUserMedia(dictionary, callback, error)', 'navigator.webkitGetUserMedia' is undefined) >-PASS getUserMedia({audio:true, video:true}, gotStream) did not throw exception. >+FAIL getUserMedia({audio:true, video:true}).then(gotStream) should not throw exception. Threw exception TypeError: undefined is not an object (evaluating 'getUserMedia({audio:true, video:true}).then'). > PASS successfullyParsed is true > > TEST COMPLETE >diff --git a/LayoutTests/fast/mediastream/RTCPeerConnection-statsSelector.html b/LayoutTests/fast/mediastream/RTCPeerConnection-statsSelector.html >index 60e200901f50493180cd106e05b11d4b83549edd..9bae5c94c054e5615e8fced76536984b0ef59d35 100644 >--- a/LayoutTests/fast/mediastream/RTCPeerConnection-statsSelector.html >+++ b/LayoutTests/fast/mediastream/RTCPeerConnection-statsSelector.html >@@ -36,9 +36,9 @@ > testPassed('Got a stream.'); > stream = s; > >- pc.addStream(stream); >+ pc.addTrack(stream.getVideoTracks()[0]); > // FIXME: Test getStats error callback: https://webkit.org/b/129860 >- shouldNotThrow('pc.getStats(pc.getLocalStreams()[0].getVideoTracks()[0]).then(statsHandler2, statsError)'); >+ shouldNotThrow('pc.getStats(s.getVideoTracks()[0]).then(statsHandler2, statsError)'); > } > > function statsHandler2(status) >@@ -55,7 +55,7 @@ > > var startTime = new Date().getTime(); > shouldNotThrow("pc = new RTCPeerConnection({iceServers:[{urls:'stun:foo.com'}]})"); >- shouldNotThrow('getUserMedia({audio:true, video:true}, gotStream)'); >+ shouldNotThrow('getUserMedia({audio:true, video:true}).then(gotStream)'); > > window.jsTestIsAsync = true; > window.successfullyParsed = true; >diff --git a/LayoutTests/fast/mediastream/argument-types-expected.txt b/LayoutTests/fast/mediastream/argument-types-expected.txt >deleted file mode 100644 >index de8e2cfb2b88d6404e13691ad16be382f0afcef6..0000000000000000000000000000000000000000 >--- a/LayoutTests/fast/mediastream/argument-types-expected.txt >+++ /dev/null >@@ -1,48 +0,0 @@ >-Tests the acceptable types for arguments to navigator.getUserMedia methods. >- >-On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE". >- >- >-PASS navigator.getUserMedia() threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia(undefined) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia(null) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia({ }) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia({video: true}) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia(true) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia(42) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia(Infinity) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia(-Infinity) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia(emptyFunction) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia({video: true}, emptyFunction) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia(undefined, emptyFunction) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia(null, emptyFunction) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia({ }, emptyFunction) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia(true, emptyFunction) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia(42, emptyFunction) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia(Infinity, emptyFunction) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia(-Infinity, emptyFunction) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia(emptyFunction, emptyFunction) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia({video: true}, "foobar") threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia({video: true}, undefined) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia({video: true}, null) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia({video: true}, {}) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia({video: true}, true) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia({video: true}, 42) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia({video: true}, Infinity) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia({video: true}, -Infinity) threw exception TypeError: Not enough arguments. >-PASS navigator.getUserMedia({ }, emptyFunction, emptyFunction) did not throw exception. >-PASS navigator.getUserMedia({video: true}, emptyFunction, emptyFunction) did not throw exception. >-PASS navigator.getUserMedia({video: true}, emptyFunction, undefined) threw exception TypeError: Argument 3 ('errorCallback') to Navigator.getUserMedia must be a function. >-PASS navigator.getUserMedia({audio:true, video:true}, emptyFunction, undefined) threw exception TypeError: Argument 3 ('errorCallback') to Navigator.getUserMedia must be a function. >-PASS navigator.getUserMedia({audio:true}, emptyFunction, undefined) threw exception TypeError: Argument 3 ('errorCallback') to Navigator.getUserMedia must be a function. >-PASS navigator.getUserMedia({video: true}, emptyFunction, "video") threw exception TypeError: Argument 3 ('errorCallback') to Navigator.getUserMedia must be a function. >-PASS navigator.getUserMedia({video: true}, emptyFunction, null) threw exception TypeError: Argument 3 ('errorCallback') to Navigator.getUserMedia must be a function. >-PASS navigator.getUserMedia({video: true}, emptyFunction, {}) threw exception TypeError: Argument 3 ('errorCallback') to Navigator.getUserMedia must be a function. >-PASS navigator.getUserMedia({video: true}, emptyFunction, true) threw exception TypeError: Argument 3 ('errorCallback') to Navigator.getUserMedia must be a function. >-PASS navigator.getUserMedia({video: true}, emptyFunction, 42) threw exception TypeError: Argument 3 ('errorCallback') to Navigator.getUserMedia must be a function. >-PASS navigator.getUserMedia({video: true}, emptyFunction, Infinity) threw exception TypeError: Argument 3 ('errorCallback') to Navigator.getUserMedia must be a function. >-PASS navigator.getUserMedia({video: true}, emptyFunction, -Infinity) threw exception TypeError: Argument 3 ('errorCallback') to Navigator.getUserMedia must be a function. >-PASS successfullyParsed is true >- >-TEST COMPLETE >- >diff --git a/LayoutTests/fast/mediastream/argument-types.html b/LayoutTests/fast/mediastream/argument-types.html >deleted file mode 100644 >index 06828a7d6ee0cc82469262561a0e4dc6d8a4b4f3..0000000000000000000000000000000000000000 >--- a/LayoutTests/fast/mediastream/argument-types.html >+++ /dev/null >@@ -1,81 +0,0 @@ >-<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> >-<html> >- <head> >- <script src="../../resources/js-test-pre.js"></script> >- </head> >- <body> >- <script> >- description("Tests the acceptable types for arguments to navigator.getUserMedia methods."); >- >- function test(expression, expressionShouldThrow, expectedException) { >- if (expressionShouldThrow) { >- if (expectedException) >- shouldThrow(expression, '"' + expectedException + '"'); >- else >- shouldThrow(expression, '"TypeError: Not enough arguments"'); >- } else { >- shouldNotThrow(expression); >- } >- } >- >- var errorCallbackError = new TypeError("Argument 3 ('errorCallback') to Navigator.getUserMedia must be a function") >- var invalidDictionaryError = new TypeError('First argument of getUserMedia must be a valid Dictionary') >- var notSupportedError = new Error('NotSupportedError: DOM Exception 9'); >- var successCallbackError = new TypeError("Argument 2 ('successCallback') to Navigator.getUserMedia must be a function") >- var typeError = new TypeError('Type error'); >- var typeNotAnObjectError = new TypeError('Not an object.'); >- >- var emptyFunction = function() {}; >- >- // No arguments >- test('navigator.getUserMedia()', true); >- >- // 1 Argument (Navigtor.getUserMedia requires at least 3 arguments). >- test('navigator.getUserMedia(undefined)', true); >- test('navigator.getUserMedia(null)', true); >- test('navigator.getUserMedia({ })', true); >- test('navigator.getUserMedia({video: true})', true); >- test('navigator.getUserMedia(true)', true); >- test('navigator.getUserMedia(42)', true); >- test('navigator.getUserMedia(Infinity)', true); >- test('navigator.getUserMedia(-Infinity)', true); >- test('navigator.getUserMedia(emptyFunction)', true); >- >- // 2 Arguments. >- test('navigator.getUserMedia({video: true}, emptyFunction)', true); >- test('navigator.getUserMedia(undefined, emptyFunction)', true); >- test('navigator.getUserMedia(null, emptyFunction)', true); >- test('navigator.getUserMedia({ }, emptyFunction)', true); >- test('navigator.getUserMedia(true, emptyFunction)', true); >- test('navigator.getUserMedia(42, emptyFunction)', true); >- test('navigator.getUserMedia(Infinity, emptyFunction)', true); >- test('navigator.getUserMedia(-Infinity, emptyFunction)', true); >- test('navigator.getUserMedia(emptyFunction, emptyFunction)', true); >- test('navigator.getUserMedia({video: true}, "foobar")', true); >- test('navigator.getUserMedia({video: true}, undefined)', true); >- test('navigator.getUserMedia({video: true}, null)', true); >- test('navigator.getUserMedia({video: true}, {})', true); >- test('navigator.getUserMedia({video: true}, true)', true); >- test('navigator.getUserMedia({video: true}, 42)', true); >- test('navigator.getUserMedia({video: true}, Infinity)', true); >- test('navigator.getUserMedia({video: true}, -Infinity)', true); >- >- // 3 Arguments. >- test('navigator.getUserMedia({ }, emptyFunction, emptyFunction)', false); >- test('navigator.getUserMedia({video: true}, emptyFunction, emptyFunction)', false); >- test('navigator.getUserMedia({video: true}, emptyFunction, undefined)', true, errorCallbackError); >- test('navigator.getUserMedia({audio:true, video:true}, emptyFunction, undefined)', true, errorCallbackError); >- test('navigator.getUserMedia({audio:true}, emptyFunction, undefined)', true, errorCallbackError); >- test('navigator.getUserMedia({video: true}, emptyFunction, "video")', true, errorCallbackError); >- test('navigator.getUserMedia({video: true}, emptyFunction, null)', true, errorCallbackError ); >- test('navigator.getUserMedia({video: true}, emptyFunction, {})', true, errorCallbackError); >- test('navigator.getUserMedia({video: true}, emptyFunction, true)', true, errorCallbackError); >- test('navigator.getUserMedia({video: true}, emptyFunction, 42)', true, errorCallbackError); >- test('navigator.getUserMedia({video: true}, emptyFunction, Infinity)', true, errorCallbackError); >- test('navigator.getUserMedia({video: true}, emptyFunction, -Infinity)', true, errorCallbackError); >- >- window.jsTestIsAsync = false; >- </script> >- <script src="../../resources/js-test-post.js"></script> >- </body> >-</html> >diff --git a/LayoutTests/fast/mediastream/getusermedia-expected.txt b/LayoutTests/fast/mediastream/getusermedia-expected.txt >deleted file mode 100644 >index f8383b88faf731b007dd2522bc1b5ad82d5411d6..0000000000000000000000000000000000000000 >--- a/LayoutTests/fast/mediastream/getusermedia-expected.txt >+++ /dev/null >@@ -1,41 +0,0 @@ >-Tests getUserMedia. >- >-On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE". >- >- >-PASS navigator.getUserMedia({audio:false, video:false}, error, expectedError); did not throw exception. >-PASS navigator.getUserMedia({audio:false, video:false}, error, null); threw exception TypeError: Argument 3 ('errorCallback') to Navigator.getUserMedia must be a function. >-PASS navigator.getUserMedia({audio:true}, gotStream1, error); did not throw exception. >-PASS Error callback called. >-PASS Stream generated. >-PASS stream.getAudioTracks().length is 1 >-PASS stream.getVideoTracks().length is 0 >-PASS navigator.getUserMedia({video:true}, gotStream2, null); threw exception TypeError: Argument 3 ('errorCallback') to Navigator.getUserMedia must be a function. >-PASS navigator.getUserMedia({video:true}, gotStream2, error); did not throw exception. >-PASS Stream generated. >-PASS stream.getAudioTracks().length is 0 >-PASS stream.getVideoTracks().length is 1 >-PASS navigator.getUserMedia({audio:true, video:true}, gotStream3, null); threw exception TypeError: Argument 3 ('errorCallback') to Navigator.getUserMedia must be a function. >-PASS navigator.getUserMedia({audio:true, video:true}, gotStream3, error); did not throw exception. >-PASS Stream generated. >-PASS stream.getAudioTracks().length is 1 >-PASS stream.getVideoTracks().length is 1 >-PASS navigator.getUserMedia({audio:{}, video:true}, gotStream4, null); threw exception TypeError: Argument 3 ('errorCallback') to Navigator.getUserMedia must be a function. >-PASS navigator.getUserMedia({audio:{}, video:true}, gotStream4, error); did not throw exception. >-PASS Stream generated. >-PASS stream.getAudioTracks().length is 1 >-PASS stream.getVideoTracks().length is 1 >-PASS navigator.getUserMedia({audio:true, video:{width:{exact:11}}}, gotStreamInError, null); threw exception TypeError: Argument 3 ('errorCallback') to Navigator.getUserMedia must be a function. >-PASS navigator.getUserMedia({audio:true, video:{width:{exact:11}}}, gotStreamInError, error1); did not throw exception. >-PASS Error callback called. >-FAIL errorArg.name should be OverconstrainedError. Was Error. >-PASS errorArg.message is "Invalid constraint" >-PASS navigator.getUserMedia({audio:{volume:{exact:1}}, video:true}, gotStream5, 0); threw exception TypeError: Argument 3 ('errorCallback') to Navigator.getUserMedia must be a function. >-PASS navigator.getUserMedia({audio:{volume:{exact:1}}, video:true}, gotStream5, error); did not throw exception. >-PASS Stream generated. >-PASS stream.getAudioTracks().length is 1 >-PASS stream.getVideoTracks().length is 1 >-PASS successfullyParsed is true >- >-TEST COMPLETE >- >diff --git a/LayoutTests/fast/mediastream/getusermedia.html b/LayoutTests/fast/mediastream/getusermedia.html >deleted file mode 100644 >index 1962a10962c6c9228810c85c30934b7f5491f9a1..0000000000000000000000000000000000000000 >--- a/LayoutTests/fast/mediastream/getusermedia.html >+++ /dev/null >@@ -1,105 +0,0 @@ >-<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> >-<html> >- <head> >- <script src="../../resources/js-test-pre.js"></script> >- </head> >- <body> >- <p id="description"></p> >- <div id="console"></div> >- <script> >- description("Tests getUserMedia."); >- >- function setUserMediaPermission(isGranted) { >- if (window.testRunner) >- testRunner.setUserMediaPermission(isGranted); >- else >- debug("This test can not be run without the testRunner"); >- } >- >- var stream; >- var errorArg; >- >- function error() { >- testFailed('Error callback called.'); >- finishJSTest(); >- } >- >- function expectedError() { >- testPassed('Error callback called.'); >- } >- >- function gotStreamInError(s) { >- testFailed('Stream generated.'); >- finishJSTest(); >- } >- >- function gotStream5(s) { >- stream = s; >- testPassed('Stream generated.'); >- shouldBe('stream.getAudioTracks().length', '1'); >- shouldBe('stream.getVideoTracks().length', '1'); >- finishJSTest(); >- } >- >- function error1(e) { >- errorArg = e; >- testPassed('Error callback called.'); >- shouldBeEqualToString('errorArg.name', 'OverconstrainedError'); >- shouldBeEqualToString('errorArg.message', 'Invalid constraint'); >- >- shouldThrow("navigator.getUserMedia({audio:{volume:{exact:1}}, video:true}, gotStream5, 0);"); >- shouldNotThrow("navigator.getUserMedia({audio:{volume:{exact:1}}, video:true}, gotStream5, error);"); >- } >- >- function gotStream4(s) { >- stream = s; >- testPassed('Stream generated.'); >- shouldBe('stream.getAudioTracks().length', '1'); >- shouldBe('stream.getVideoTracks().length', '1'); >- >- shouldThrow("navigator.getUserMedia({audio:true, video:{width:{exact:11}}}, gotStreamInError, null);"); >- shouldNotThrow("navigator.getUserMedia({audio:true, video:{width:{exact:11}}}, gotStreamInError, error1);"); >- } >- >- function gotStream3(s) { >- stream = s; >- testPassed('Stream generated.'); >- shouldBe('stream.getAudioTracks().length', '1'); >- shouldBe('stream.getVideoTracks().length', '1'); >- >- shouldThrow("navigator.getUserMedia({audio:{}, video:true}, gotStream4, null);"); >- shouldNotThrow("navigator.getUserMedia({audio:{}, video:true}, gotStream4, error);"); >- } >- >- function gotStream2(s) { >- stream = s; >- testPassed('Stream generated.'); >- shouldBe('stream.getAudioTracks().length', '0'); >- shouldBe('stream.getVideoTracks().length', '1'); >- >- shouldThrow("navigator.getUserMedia({audio:true, video:true}, gotStream3, null);"); >- shouldNotThrow("navigator.getUserMedia({audio:true, video:true}, gotStream3, error);"); >- } >- >- function gotStream1(s) { >- stream = s; >- testPassed('Stream generated.'); >- shouldBe('stream.getAudioTracks().length', '1'); >- shouldBe('stream.getVideoTracks().length', '0'); >- >- shouldThrow("navigator.getUserMedia({video:true}, gotStream2, null);") >- shouldNotThrow("navigator.getUserMedia({video:true}, gotStream2, error);") >- } >- >- shouldNotThrow("navigator.getUserMedia({audio:false, video:false}, error, expectedError);") >- shouldThrow("navigator.getUserMedia({audio:false, video:false}, error, null);") >- >- setUserMediaPermission(true); >- shouldNotThrow("navigator.getUserMedia({audio:true}, gotStream1, error);"); >- >- window.jsTestIsAsync = true; >- window.successfullyParsed = true; >- </script> >- <script src="../../resources/js-test-post.js"></script> >- </body> >-</html> >diff --git a/LayoutTests/fast/mediastream/webkitGetUserMedia-shadowing-then-expected.txt b/LayoutTests/fast/mediastream/webkitGetUserMedia-shadowing-then-expected.txt >deleted file mode 100644 >index 7ef22e9a431ad0272713b71fdc8794016c8ef12f..0000000000000000000000000000000000000000 >--- a/LayoutTests/fast/mediastream/webkitGetUserMedia-shadowing-then-expected.txt >+++ /dev/null >@@ -1 +0,0 @@ >-PASS >diff --git a/LayoutTests/fast/mediastream/webkitGetUserMedia-shadowing-then.html b/LayoutTests/fast/mediastream/webkitGetUserMedia-shadowing-then.html >deleted file mode 100644 >index f72a6d642e6c47f8b176b7ef95af4691f941b760..0000000000000000000000000000000000000000 >--- a/LayoutTests/fast/mediastream/webkitGetUserMedia-shadowing-then.html >+++ /dev/null >@@ -1,44 +0,0 @@ >-<!DOCTYPE html> >-<html lang="en"> >-<head> >- <meta charset="UTF-8"> >- <title>Shadowing then()</title> >-</head> >-<body> >-<!-- >-This test verifies that the implementation of navigator.getUserMedia does not use public promise APIs. >---> >-<p id="output"></p> >-<script> >- if (window.testRunner) { >- testRunner.dumpAsText(); >- testRunner.waitUntilDone(); >- } >- >- function endTest(testStatus) { >- document.getElementById("output").textContent = testStatus; >- testRunner.notifyDone(); >- } >- >- // Shadow Promise.prototype.then >- Promise.prototype.then = (function () { >- const realThen = Promise.prototype.then; >- return function () { >- endTest("FAIL: Executed shadowed, public .then()"); >- } >- })(); >- >- function gotUserMedia(mediaStream) { >- endTest("FAIL: Got user media"); >- } >- >- function userMediaError(error) { >- endTest("PASS"); >- } >- >- var options = { audio: false, video: false }; >- navigator.getUserMedia(options, gotUserMedia, userMediaError); >- >-</script> >-</body> >-</html> >diff --git a/LayoutTests/http/tests/media/media-stream/collect-media-devices.https-expected.txt b/LayoutTests/http/tests/media/media-stream/collect-media-devices.https-expected.txt >new file mode 100644 >index 0000000000000000000000000000000000000000..a0d67a3d33c79f7e4976244b5bd9ad5151821898 >--- /dev/null >+++ b/LayoutTests/http/tests/media/media-stream/collect-media-devices.https-expected.txt >@@ -0,0 +1,4 @@ >+ >+ >+PASS Ensure that the frame's document get collected after being stopped while using MediaDevices >+ >diff --git a/LayoutTests/http/tests/media/media-stream/collect-media-devices.https.html b/LayoutTests/http/tests/media/media-stream/collect-media-devices.https.html >new file mode 100644 >index 0000000000000000000000000000000000000000..b9852d02273049d7269f0c90b0c2b347ae56c819 >--- /dev/null >+++ b/LayoutTests/http/tests/media/media-stream/collect-media-devices.https.html >@@ -0,0 +1,45 @@ >+<!DOCTYPE html> >+<meta charset="utf-8"> >+<script src="/resources/testharness.js"></script> >+<script src="/resources/testharnessreport.js"></script> >+<script> >+function waitFor(duration) >+{ >+ return new Promise((resolve) => setTimeout(resolve, duration)); >+} >+ >+var resolveCallback, rejectCallback; >+var promise = new Promise((resolve, reject) => { >+ resolveCallback = resolve; >+ rejectCallback = reject; >+}); >+ >+async function done() >+{ >+ try { >+ const frameIdentifier = internals.documentIdentifier(iframe.contentDocument); >+ iframe.src = "non-existent-frame"; >+ let counter = 0; >+ while (++counter < 10) { >+ if (!internals.isDocumentAlive(frameIdentifier)) { >+ resolveCallback(); >+ return; >+ } >+ if (window.GCController) >+ GCController.collect(); >+ >+ await waitFor(50); >+ } >+ } finally { >+ rejectCallback("Test failed"); >+ } >+} >+ >+promise_test((test) => { >+ if (!window.internals) >+ rejectCallback("Test require internals API"); >+ return promise; >+}, "Ensure that the frame's document get collected after being stopped while using MediaDevices"); >+ >+</script> >+<iframe src="resources/mymediadevicesframe.htm" id="iframe"></iframe> >diff --git a/LayoutTests/http/tests/media/media-stream/resources/mymediadevicesframe.htm b/LayoutTests/http/tests/media/media-stream/resources/mymediadevicesframe.htm >new file mode 100644 >index 0000000000000000000000000000000000000000..61362277816246bad5b33ef7cd7cd7b465da2e62 >--- /dev/null >+++ b/LayoutTests/http/tests/media/media-stream/resources/mymediadevicesframe.htm >@@ -0,0 +1,5 @@ >+<!DOCTYPE html> >+<script> >+navigator.mediaDevices.ondevicechange = () => {}; >+parent.done(); >+</script> >diff --git a/LayoutTests/imported/w3c/web-platform-tests/mediacapture-streams/MediaDevices-IDL-all-expected.txt b/LayoutTests/imported/w3c/web-platform-tests/mediacapture-streams/MediaDevices-IDL-all-expected.txt >index 7ca324c443427885878491a9fb514bf3433cbebf..17006761c55c34a58726a15fced21ced32719cd6 100644 >--- a/LayoutTests/imported/w3c/web-platform-tests/mediacapture-streams/MediaDevices-IDL-all-expected.txt >+++ b/LayoutTests/imported/w3c/web-platform-tests/mediacapture-streams/MediaDevices-IDL-all-expected.txt >@@ -8,11 +8,11 @@ This test checks for the presence of the navigator.mediaDevices.getUserMedia met > PASS Test driver > PASS Navigator interface: attribute mediaDevices > PASS Unscopable handled correctly for mediaDevices property on Navigator >-PASS Navigator interface: operation getUserMedia(MediaStreamConstraints, NavigatorUserMediaSuccessCallback, NavigatorUserMediaErrorCallback) >+FAIL Navigator interface: operation getUserMedia(MediaStreamConstraints, NavigatorUserMediaSuccessCallback, NavigatorUserMediaErrorCallback) assert_own_property: interface prototype object missing non-static operation expected property "getUserMedia" missing > PASS Unscopable handled correctly for getUserMedia(MediaStreamConstraints, NavigatorUserMediaSuccessCallback, NavigatorUserMediaErrorCallback) on Navigator > PASS Navigator interface: navigator must inherit property "mediaDevices" with the proper type >-PASS Navigator interface: navigator must inherit property "getUserMedia(MediaStreamConstraints, NavigatorUserMediaSuccessCallback, NavigatorUserMediaErrorCallback)" with the proper type >-PASS Navigator interface: calling getUserMedia(MediaStreamConstraints, NavigatorUserMediaSuccessCallback, NavigatorUserMediaErrorCallback) on navigator with too few arguments must throw TypeError >+FAIL Navigator interface: navigator must inherit property "getUserMedia(MediaStreamConstraints, NavigatorUserMediaSuccessCallback, NavigatorUserMediaErrorCallback)" with the proper type assert_inherits: property "getUserMedia" not found in prototype chain >+FAIL Navigator interface: calling getUserMedia(MediaStreamConstraints, NavigatorUserMediaSuccessCallback, NavigatorUserMediaErrorCallback) on navigator with too few arguments must throw TypeError assert_inherits: property "getUserMedia" not found in prototype chain > PASS MediaStream interface: existence and properties of interface object > PASS MediaStream interface object length > PASS MediaStream interface object name >diff --git a/LayoutTests/imported/w3c/web-platform-tests/mediacapture-streams/MediaDevices-IDL-enumerateDevices-expected.txt b/LayoutTests/imported/w3c/web-platform-tests/mediacapture-streams/MediaDevices-IDL-enumerateDevices-expected.txt >index 06bb27a23b36564a13a845bc1d8a45866a7fff47..9c7dbe457ad39e1c7ed69ecfb526deceb840d419 100644 >--- a/LayoutTests/imported/w3c/web-platform-tests/mediacapture-streams/MediaDevices-IDL-enumerateDevices-expected.txt >+++ b/LayoutTests/imported/w3c/web-platform-tests/mediacapture-streams/MediaDevices-IDL-enumerateDevices-expected.txt >@@ -8,7 +8,7 @@ This test checks for the presence of the navigator.mediaDevices.enumerateDevices > PASS Test MediaDevices.enumerateDevices call and result. Types only. > PASS Navigator interface: attribute mediaDevices > PASS Unscopable handled correctly for mediaDevices property on Navigator >-PASS Navigator interface: operation getUserMedia(MediaStreamConstraints, NavigatorUserMediaSuccessCallback, NavigatorUserMediaErrorCallback) >+FAIL Navigator interface: operation getUserMedia(MediaStreamConstraints, NavigatorUserMediaSuccessCallback, NavigatorUserMediaErrorCallback) assert_own_property: interface prototype object missing non-static operation expected property "getUserMedia" missing > PASS Unscopable handled correctly for getUserMedia(MediaStreamConstraints, NavigatorUserMediaSuccessCallback, NavigatorUserMediaErrorCallback) on Navigator > FAIL MediaStream interface: existence and properties of interface object undefined is not an object (evaluating 'this.array > .members[this.base] >diff --git a/LayoutTests/imported/w3c/web-platform-tests/mediacapture-streams/MediaStream-default-feature-policy.https-expected.txt b/LayoutTests/imported/w3c/web-platform-tests/mediacapture-streams/MediaStream-default-feature-policy.https-expected.txt >index c7393c476e98260a797bb862367d8fbd9386df0c..e679572d22c734e7a9de080af00d80ffb718493e 100644 >--- a/LayoutTests/imported/w3c/web-platform-tests/mediacapture-streams/MediaStream-default-feature-policy.https-expected.txt >+++ b/LayoutTests/imported/w3c/web-platform-tests/mediacapture-streams/MediaStream-default-feature-policy.https-expected.txt >@@ -1,22 +1,15 @@ >-CONSOLE MESSAGE: line 1: The top-level frame has prevented a document with a different security origin to call getUserMedia. >-CONSOLE MESSAGE: line 1: The top-level frame has prevented a document with a different security origin to call getUserMedia. >-CONSOLE MESSAGE: line 1: The top-level frame has prevented a document with a different security origin to call getUserMedia. >-CONSOLE MESSAGE: line 1: The top-level frame has prevented a document with a different security origin to call getUserMedia. >-CONSOLE MESSAGE: line 1: The top-level frame has prevented a document with a different security origin to call getUserMedia. >-CONSOLE MESSAGE: line 1: The top-level frame has prevented a document with a different security origin to call getUserMedia. >-CONSOLE MESSAGE: line 1: The top-level frame has prevented a document with a different security origin to call getUserMedia. > > >-PASS Default "microphone" feature policy ["self"] allows the top-level document. >-PASS Default "microphone" feature policy ["self"] allows same-origin iframes. >-PASS Default "microphone" feature policy ["self"] disallows cross-origin iframes. >-FAIL Feature policy "microphone" can be enabled in cross-origin iframes using "allow" attribute. assert_equals: expected "#OK" but got "#NotAllowedError" >-PASS Default "camera" feature policy ["self"] allows the top-level document. >-PASS Default "camera" feature policy ["self"] allows same-origin iframes. >-PASS Default "camera" feature policy ["self"] disallows cross-origin iframes. >-FAIL Feature policy "camera" can be enabled in cross-origin iframes using "allow" attribute. assert_equals: expected "#OK" but got "#NotAllowedError" >-PASS Default "camera; microphone" feature policy ["self"] allows the top-level document. >-PASS Default "camera; microphone" feature policy ["self"] allows same-origin iframes. >-PASS Default "camera; microphone" feature policy ["self"] disallows cross-origin iframes. >-PASS Feature policy "camera; microphone" can be enabled in cross-origin iframes using "allow" attribute. >+FAIL Default "microphone" feature policy ["self"] allows the top-level document. promise_test: Unhandled rejection with value: object "TypeError: undefined is not a function (near '...navigator.getUserMedia...')" >+FAIL Default "microphone" feature policy ["self"] allows same-origin iframes. assert_equals: expected "#OK" but got "#TypeError" >+FAIL Default "microphone" feature policy ["self"] disallows cross-origin iframes. assert_equals: expected "#NotAllowedError" but got "#TypeError" >+FAIL Feature policy "microphone" can be enabled in cross-origin iframes using "allow" attribute. assert_equals: expected "#OK" but got "#TypeError" >+FAIL Default "camera" feature policy ["self"] allows the top-level document. promise_test: Unhandled rejection with value: object "TypeError: undefined is not a function (near '...navigator.getUserMedia...')" >+FAIL Default "camera" feature policy ["self"] allows same-origin iframes. assert_equals: expected "#OK" but got "#TypeError" >+FAIL Default "camera" feature policy ["self"] disallows cross-origin iframes. assert_equals: expected "#NotAllowedError" but got "#TypeError" >+FAIL Feature policy "camera" can be enabled in cross-origin iframes using "allow" attribute. assert_equals: expected "#OK" but got "#TypeError" >+FAIL Default "camera; microphone" feature policy ["self"] allows the top-level document. promise_test: Unhandled rejection with value: object "TypeError: undefined is not a function (near '...navigator.getUserMedia...')" >+FAIL Default "camera; microphone" feature policy ["self"] allows same-origin iframes. assert_equals: expected "#OK" but got "#TypeError" >+FAIL Default "camera; microphone" feature policy ["self"] disallows cross-origin iframes. assert_equals: expected "#NotAllowedError" but got "#TypeError" >+FAIL Feature policy "camera; microphone" can be enabled in cross-origin iframes using "allow" attribute. assert_equals: expected "#OK" but got "#TypeError" > >diff --git a/LayoutTests/imported/w3c/web-platform-tests/webrtc/historical-expected.txt b/LayoutTests/imported/w3c/web-platform-tests/webrtc/historical-expected.txt >index d20b397170ed7441474f91c9d299053c8b65f550..23219c7b79c150aed5e29a42a974dbc43f695858 100644 >--- a/LayoutTests/imported/w3c/web-platform-tests/webrtc/historical-expected.txt >+++ b/LayoutTests/imported/w3c/web-platform-tests/webrtc/historical-expected.txt >@@ -1,13 +1,13 @@ > > PASS RTCDataChannel member reliable should not exist >-FAIL RTCPeerConnection member addStream should not exist assert_false: expected false got true >+PASS RTCPeerConnection member addStream should not exist > PASS RTCPeerConnection member createDTMFSender should not exist >-FAIL RTCPeerConnection member getLocalStreams should not exist assert_false: expected false got true >-FAIL RTCPeerConnection member getRemoteStreams should not exist assert_false: expected false got true >-FAIL RTCPeerConnection member getStreamById should not exist assert_false: expected false got true >-FAIL RTCPeerConnection member onaddstream should not exist assert_false: expected false got true >+PASS RTCPeerConnection member getLocalStreams should not exist >+PASS RTCPeerConnection member getRemoteStreams should not exist >+PASS RTCPeerConnection member getStreamById should not exist >+PASS RTCPeerConnection member onaddstream should not exist > PASS RTCPeerConnection member onremovestream should not exist >-FAIL RTCPeerConnection member removeStream should not exist assert_false: expected false got true >+PASS RTCPeerConnection member removeStream should not exist > PASS RTCPeerConnection member updateIce should not exist > PASS DataChannel interface should not exist > PASS mozRTCIceCandidate interface should not exist >diff --git a/LayoutTests/imported/w3c/web-platform-tests/webrtc/no-media-call.html b/LayoutTests/imported/w3c/web-platform-tests/webrtc/no-media-call.html >index c4979e8521478a0f8175a5f945cd217f8c60d548..c973932bf2fc36529abf0fa819d019e394df6fe7 100644 >--- a/LayoutTests/imported/w3c/web-platform-tests/webrtc/no-media-call.html >+++ b/LayoutTests/imported/w3c/web-platform-tests/webrtc/no-media-call.html >@@ -37,9 +37,9 @@ This test uses the legacy callback API with no media, and thus does not require > var parsedOffer = new RTCSessionDescription({ type: 'offer', > sdp: offerSdp }); > // These functions use the legacy interface extensions to RTCPeerConnection. >- gSecondConnection.setRemoteDescription(parsedOffer, >+ gSecondConnection.setRemoteDescription(parsedOffer).then( > function() { >- gSecondConnection.createAnswer(onAnswerCreated, >+ gSecondConnection.createAnswer().then(onAnswerCreated, > failed('createAnswer')); > }, > failed('setRemoteDescription second')); >@@ -56,7 +56,7 @@ This test uses the legacy callback API with no media, and thus does not require > function handleAnswer(answerSdp) { > var parsedAnswer = new RTCSessionDescription({ type: 'answer', > sdp: answerSdp }); >- gFirstConnection.setRemoteDescription(parsedAnswer, ignoreSuccess, >+ gFirstConnection.setRemoteDescription(parsedAnswer).then(ignoreSuccess, > failed('setRemoteDescription first')); > }; > >@@ -125,7 +125,7 @@ This test uses the legacy callback API with no media, and thus does not require > > // The offerToReceiveVideo is necessary and sufficient to make > // an actual connection. >- gFirstConnection.createOffer(onOfferCreated, failed('createOffer'), >+ gFirstConnection.createOffer().then(onOfferCreated, failed('createOffer'), > {offerToReceiveVideo: true}); > }); > </script> >diff --git a/LayoutTests/imported/w3c/web-platform-tests/webrtc/rtcpeerconnection/setRemoteDescription-expected.txt b/LayoutTests/imported/w3c/web-platform-tests/webrtc/rtcpeerconnection/setRemoteDescription-expected.txt >deleted file mode 100644 >index 920894f5f73903a2d7754ba18bf4b4d63afaca1c..0000000000000000000000000000000000000000 >--- a/LayoutTests/imported/w3c/web-platform-tests/webrtc/rtcpeerconnection/setRemoteDescription-expected.txt >+++ /dev/null >@@ -1,3 +0,0 @@ >- >-PASS Triggers onaddstream when called with a remote description and the MSID is parsed. >- >diff --git a/LayoutTests/imported/w3c/web-platform-tests/webrtc/simplecall.https.html b/LayoutTests/imported/w3c/web-platform-tests/webrtc/simplecall.https.html >index 4d948ee34e37b89636b97da288bc66072b6773da..8651f54877dc55d1472386cc2b77d310674fe39d 100644 >--- a/LayoutTests/imported/w3c/web-platform-tests/webrtc/simplecall.https.html >+++ b/LayoutTests/imported/w3c/web-platform-tests/webrtc/simplecall.https.html >@@ -44,7 +44,7 @@ property to true in Firefox. > localStream.getTracks().forEach(function(track) { > gFirstConnection.addTrack(track, localStream); > }); >- gFirstConnection.createOffer(onOfferCreated, failed('createOffer')); >+ gFirstConnection.createOffer().then(onOfferCreated, failed('createOffer')); > > var videoTag = document.getElementById('local-view'); > videoTag.srcObject = localStream; >@@ -67,7 +67,7 @@ property to true in Firefox. > sdp: offerSdp }); > gSecondConnection.setRemoteDescription(parsedOffer); > >- gSecondConnection.createAnswer(onAnswerCreated, >+ gSecondConnection.createAnswer().then(onAnswerCreated, > failed('createAnswer')); > }; > >diff --git a/LayoutTests/platform/gtk/TestExpectations b/LayoutTests/platform/gtk/TestExpectations >index d36cac1fff84aaccae7e5870f9a9ef1f2b6e5f09..308ef65e7ead0e887ed9020d02172f60a20d25dc 100644 >--- a/LayoutTests/platform/gtk/TestExpectations >+++ b/LayoutTests/platform/gtk/TestExpectations >@@ -613,7 +613,6 @@ webkit.org/b/79203 fast/mediastream/mock-media-source-webaudio.html [ Timeout ] > webkit.org/b/79203 fast/mediastream/getUserMedia-webaudio.html [ Failure ] > # Crash is bug #186678 > webkit.org/b/79203 fast/mediastream/MediaStream-video-element-track-stop.html [ Timeout Crash ] >-webkit.org/b/79203 fast/mediastream/RTCPeerConnection-dtmf.html [ Timeout ] > webkit.org/b/79203 fast/mediastream/RTCPeerConnection-icecandidate-event.html [ Failure Crash ] > webkit.org/b/79203 fast/mediastream/RTCPeerConnection-media-setup-two-dialogs.html [ Pass Failure Crash ] > webkit.org/b/79203 fast/mediastream/MediaStream-video-element.html [ Pass Crash Failure ] >@@ -625,7 +624,6 @@ webkit.org/b/79203 fast/mediastream/RTCPeerConnection-ice.html [ Failure Timeout > webkit.org/b/79203 fast/mediastream/RTCPeerConnection-inspect-answer.html [ Failure ] > webkit.org/b/79203 fast/mediastream/RTCPeerConnection-inspect-offer-bundlePolicy-bundle-only.html [ Failure Crash ] > webkit.org/b/79203 fast/mediastream/RTCPeerConnection-inspect-offer.html [ Failure ] >-webkit.org/b/79203 fast/mediastream/RTCPeerConnection-legacy-stream-based-api.html [ Failure ] > webkit.org/b/79203 fast/mediastream/RTCPeerConnection-media-setup-callbacks-single-dialog.html [ Pass Crash Failure ] > webkit.org/b/79203 webaudio/mediastreamaudiosourcenode.html [ Failure ] > webkit.org/b/79203 fast/mediastream/MediaStream-video-element-video-tracks-disabled-then-enabled.html [ Timeout Failure ] >@@ -639,7 +637,6 @@ webkit.org/b/151344 fast/mediastream/MediaStream-add-ended-tracks.html [ Timeout > webkit.org/b/160996 fast/mediastream/MediaStream-video-element-video-tracks-disabled.html [ ImageOnlyFailure Crash ] > webkit.org/b/172269 fast/mediastream/media-devices-enumerate-devices.html [ Failure ] > webkit.org/b/173257 fast/mediastream/getUserMedia-grant-persistency3.html [ Pass Failure ] >-webkit.org/b/176801 fast/mediastream/argument-types.html [ Crash Pass ] > > # Canvas captureStream support is not implemented > webkit.org/b/169811 fast/mediacapturefromelement [ Skip ] >diff --git a/LayoutTests/platform/ios-wk1/TestExpectations b/LayoutTests/platform/ios-wk1/TestExpectations >index 489d48e2ec83c1534ab8dc4821abda07421481a2..76c4a00468c288af148d837d25f8deadd8681f57 100644 >--- a/LayoutTests/platform/ios-wk1/TestExpectations >+++ b/LayoutTests/platform/ios-wk1/TestExpectations >@@ -19,7 +19,6 @@ imported/w3c/web-platform-tests/fetch/cross-origin-resource-policy [ Skip ] > # Skip WebRTC for now in WK1 > imported/w3c/web-platform-tests/webrtc [ Skip ] > webrtc [ Skip ] >-fast/events/constructors/media-stream-event-constructor.html > > # Not supported on WK1 > media/no-fullscreen-when-hidden.html [ Skip ] >diff --git a/LayoutTests/platform/ios/TestExpectations b/LayoutTests/platform/ios/TestExpectations >index 3f13de8d2aa2a07ef845194fe31bdd7366dfdc49..02d705021504f86de885c8f35c846d9eec932b1e 100644 >--- a/LayoutTests/platform/ios/TestExpectations >+++ b/LayoutTests/platform/ios/TestExpectations >@@ -1061,15 +1061,12 @@ css3/color-filters/color-filter-ignore-semantic.html [ Skip ] > > # Run webrtc tests on iOS 11 > imported/w3c/web-platform-tests/webrtc [ Pass ] >-fast/events/constructors/media-stream-event-constructor.html [ Pass ] > fast/mediastream/RTCIceCandidate.html [ Pass ] > fast/mediastream/RTCPeerConnection-add-removeTrack.html [ Pass ] > fast/mediastream/RTCPeerConnection-addIceCandidate.html [ Pass ] >-fast/mediastream/RTCPeerConnection-AddRemoveStream.html [ Pass ] > fast/mediastream/RTCPeerConnection-addTrack-reuse-sender.html [ Pass ] > fast/mediastream/RTCPeerConnection-addTransceiver.html [ Pass ] > fast/mediastream/RTCPeerConnection-createAnswer.html [ Pass ] >-fast/mediastream/RTCPeerConnection-createOffer.html [ Pass ] > fast/mediastream/RTCPeerConnection-datachannel.html [ Pass ] > fast/mediastream/RTCPeerConnection-have-local-offer.html [ Pass ] > fast/mediastream/RTCPeerConnection-have-local-pranswer.html [ Pass ] >@@ -1077,7 +1074,6 @@ fast/mediastream/RTCPeerConnection-have-remote-offer.html [ Pass ] > fast/mediastream/RTCPeerConnection-have-remote-pranswer.html [ Pass ] > fast/mediastream/RTCPeerConnection-inspect-answer.html [ Pass ] > fast/mediastream/RTCPeerConnection-inspect-offer.html [ Pass ] >-fast/mediastream/RTCPeerConnection-legacy-stream-based-api.html [ Pass ] > fast/mediastream/RTCPeerConnection-localDescription.html [ Pass ] > fast/mediastream/RTCPeerConnection-media-setup-single-dialog.html [ Pass ] > fast/mediastream/RTCPeerConnection-media-setup-two-dialogs.html [ Pass ] >diff --git a/LayoutTests/platform/mac-wk1/TestExpectations b/LayoutTests/platform/mac-wk1/TestExpectations >index d26ed3b12790e175829449ab0543aadfc8289a2a..d67108cf0f221ea0dbe00eda5b4bd0a6520268cd 100644 >--- a/LayoutTests/platform/mac-wk1/TestExpectations >+++ b/LayoutTests/platform/mac-wk1/TestExpectations >@@ -138,7 +138,6 @@ fast/mediastream > imported/w3c/web-platform-tests/mediacapture-streams > http/tests/media/media-stream > http/tests/ssl/media-stream >-fast/events/constructors/media-stream-event-constructor.html > > # WK1 does not filter response headers. > http/wpt/loading/redirect-headers.html [ Skip ] >diff --git a/LayoutTests/platform/mac/TestExpectations b/LayoutTests/platform/mac/TestExpectations >index caf62e664e06f86682b043a9acb7f20d4cc7673e..32b49ddfe853edb032ba126cd1371ba6c05f73e7 100644 >--- a/LayoutTests/platform/mac/TestExpectations >+++ b/LayoutTests/platform/mac/TestExpectations >@@ -144,7 +144,6 @@ fast/forms/week > # Media Stream API is not fully supported. > fast/mediastream/MediaStream-add-ended-tracks.html > >-fast/mediastream/RTCPeerConnection-dtmf.html [ Skip ] > fast/mediastream/RTCPeerConnection-ice.html [ Skip ] > fast/mediastream/RTCPeerConnection-media-setup-callbacks-single-dialog.html [ Skip ] > fast/mediastream/RTCPeerConnection-stats.html [ Skip ] >diff --git a/LayoutTests/platform/win/TestExpectations b/LayoutTests/platform/win/TestExpectations >index 51d462ca1df562db20b7c44e42de006dd621ef01..e29a3a889eac1fe28bd864486a14019f183cc380 100644 >--- a/LayoutTests/platform/win/TestExpectations >+++ b/LayoutTests/platform/win/TestExpectations >@@ -850,7 +850,6 @@ webkit.org/b/38376 media/media-document-audio-size.html [ Skip ] > # Media Stream API is not yet enabled. > fast/mediastream [ Skip ] > imported/w3c/web-platform-tests/mediacapture-streams [ Skip ] >-fast/events/constructors/media-stream-event-constructor.html [ Skip ] > http/tests/media/media-stream [ Skip ] > > # needs enhanced eventSender.contextMenu() return value >diff --git a/LayoutTests/webrtc/legacy-api-expected.txt b/LayoutTests/webrtc/legacy-api-expected.txt >index 14eb41441664c0d7d9548fef576ae22a4438e96b..9d48484db7934a76b489d128b7dd6505ccaffdf2 100644 >--- a/LayoutTests/webrtc/legacy-api-expected.txt >+++ b/LayoutTests/webrtc/legacy-api-expected.txt >@@ -8,7 +8,7 @@ Found 1 tests > Details > > Result Test Name Message >-Pass Testing legacy API is not defined when legacy flag is turned off >+Pass Testing legacy API is not defined > >-PASS Testing legacy API is not defined when legacy flag is turned off >+PASS Testing legacy API is not defined > >diff --git a/LayoutTests/webrtc/legacy-api.html b/LayoutTests/webrtc/legacy-api.html >index 0b84495fe175948cdb7b2ec5b5ed2ae5a98acefa..e521b563a0a8b2d0d6c37bc8a2b0efcd9e3c2243 100644 >--- a/LayoutTests/webrtc/legacy-api.html >+++ b/LayoutTests/webrtc/legacy-api.html >@@ -5,9 +5,6 @@ > </head> > <body> > <script> >-if (window.testRunner) >- testRunner.setWebRTCLegacyAPIEnabled(false); >- > promise_test(function() { > var pc1 = new RTCPeerConnection({iceServers:[{urls:'stun:foo.com'}]}); > var pc2 = new RTCPeerConnection({iceServers:[{urls:'stun:foo.com'}]}); >@@ -26,7 +23,7 @@ promise_test(function() { > }).then(() => { > return pc2.createAnswer({ }, assert_unreached, assert_unreached); > }); >-}, "Testing legacy API is not defined when legacy flag is turned off"); >+}, "Testing legacy API is not defined"); > </script> > <script src="../resources/testharnessreport.js"></script> > </body>
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 189040
:
348265
|
348277
|
348298
|
348307
|
348322
|
348327
|
348393
|
348402
|
348531