Title: [291144] trunk
Revision
291144
Author
[email protected]
Date
2022-03-10 21:03:26 -0800 (Thu, 10 Mar 2022)

Log Message

EnterPictureInPictureEvent event was renamed to PictureInPictureEvent in spec
https://bugs.webkit.org/show_bug.cgi?id=221083

Reviewed by Youenn Fablet.

Source/WebCore:

Some updates based on the spec changes:
- Rename EnterPictureInPictureEvent.idl to PictureInPictureEvent.idl.
- leavepictureinpicture event should be fired with the Picture-in-Picture window.
(https://github.com/w3c/picture-in-picture/issues/188)

Covered by media/picture-in-picture/picture-in-picture-api-events.html.

* CMakeLists.txt:
* DerivedSources-input.xcfilelist:
* DerivedSources-output.xcfilelist:
* DerivedSources.make:
* Modules/pictureinpicture/HTMLVideoElementPictureInPicture.cpp:
(WebCore::HTMLVideoElementPictureInPicture::didEnterPictureInPicture):
(WebCore::HTMLVideoElementPictureInPicture::didExitPictureInPicture):
* Modules/pictureinpicture/PictureInPictureEvent.cpp: Renamed from Source/WebCore/Modules/pictureinpicture/EnterPictureInPictureEvent.cpp.
(WebCore::PictureInPictureEvent::create):
(WebCore::PictureInPictureEvent::PictureInPictureEvent):
* Modules/pictureinpicture/PictureInPictureEvent.h: Renamed from Source/WebCore/Modules/pictureinpicture/EnterPictureInPictureEvent.h.
* Modules/pictureinpicture/PictureInPictureEvent.idl: Renamed from Source/WebCore/Modules/pictureinpicture/EnterPictureInPictureEvent.idl.
* Sources.txt:
* WebCore.xcodeproj/project.pbxproj:
* bindings/js/WebCoreBuiltinNames.h:
* dom/EventNames.in:

Tools:

* TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:

LayoutTests:

* media/picture-in-picture/picture-in-picture-api-events-expected.txt:
* media/picture-in-picture/picture-in-picture-api-events.html:
Check the picture-in-picture window in the "leavepictureinpicture" event handler.

Modified Paths

Added Paths

Removed Paths

Diff

Modified: trunk/LayoutTests/ChangeLog (291143 => 291144)


--- trunk/LayoutTests/ChangeLog	2022-03-11 03:22:03 UTC (rev 291143)
+++ trunk/LayoutTests/ChangeLog	2022-03-11 05:03:26 UTC (rev 291144)
@@ -1,3 +1,14 @@
+2022-03-10  Peng Liu  <[email protected]>
+
+        EnterPictureInPictureEvent event was renamed to PictureInPictureEvent in spec
+        https://bugs.webkit.org/show_bug.cgi?id=221083
+
+        Reviewed by Youenn Fablet.
+
+        * media/picture-in-picture/picture-in-picture-api-events-expected.txt:
+        * media/picture-in-picture/picture-in-picture-api-events.html:
+        Check the picture-in-picture window in the "leavepictureinpicture" event handler.
+
 2022-03-10  Chris Dumez  <[email protected]>
 
         Main document is leaking on haaretz.co.il due to lazy image loading

Modified: trunk/LayoutTests/media/picture-in-picture/picture-in-picture-api-events-expected.txt (291143 => 291144)


--- trunk/LayoutTests/media/picture-in-picture/picture-in-picture-api-events-expected.txt	2022-03-11 03:22:03 UTC (rev 291143)
+++ trunk/LayoutTests/media/picture-in-picture/picture-in-picture-api-events-expected.txt	2022-03-11 05:03:26 UTC (rev 291144)
@@ -8,5 +8,6 @@
 EXPECTED (pipWindow.width > '0') OK
 EXPECTED (pipWindow.height > '0') OK
 EVENT(leavepictureinpicture)
+EXPECTED (pipWindow == pipWindow1 == 'true') OK
 END OF TEST
 

Modified: trunk/LayoutTests/media/picture-in-picture/picture-in-picture-api-events.html (291143 => 291144)


--- trunk/LayoutTests/media/picture-in-picture/picture-in-picture-api-events.html	2022-03-11 03:22:03 UTC (rev 291143)
+++ trunk/LayoutTests/media/picture-in-picture/picture-in-picture-api-events.html	2022-03-11 05:03:26 UTC (rev 291144)
@@ -28,7 +28,11 @@
                 testExpected('pipWindow.height', 0, '>');
 
                 document.exitPictureInPicture();
-                waitForEventAndEnd('leavepictureinpicture');
+                waitForEventOnce('leavepictureinpicture', event => {
+                    window.pipWindow1 = event.pictureInPictureWindow;
+                    testExpected('pipWindow == pipWindow1', true);
+                    endTest();
+                });
             });
         });
     </script>

Modified: trunk/Source/WebCore/CMakeLists.txt (291143 => 291144)


--- trunk/Source/WebCore/CMakeLists.txt	2022-03-11 03:22:03 UTC (rev 291143)
+++ trunk/Source/WebCore/CMakeLists.txt	2022-03-11 05:03:26 UTC (rev 291144)
@@ -513,8 +513,8 @@
 
     Modules/pictureinpicture/Document+PictureInPicture.idl
     Modules/pictureinpicture/DocumentOrShadowRoot+PictureInPicture.idl
-    Modules/pictureinpicture/EnterPictureInPictureEvent.idl
     Modules/pictureinpicture/HTMLVideoElement+PictureInPicture.idl
+    Modules/pictureinpicture/PictureInPictureEvent.idl
     Modules/pictureinpicture/PictureInPictureWindow.idl
 
     Modules/push-api/PushEncryptionKeyName.idl

Modified: trunk/Source/WebCore/ChangeLog (291143 => 291144)


--- trunk/Source/WebCore/ChangeLog	2022-03-11 03:22:03 UTC (rev 291143)
+++ trunk/Source/WebCore/ChangeLog	2022-03-11 05:03:26 UTC (rev 291144)
@@ -1,3 +1,34 @@
+2022-03-10  Peng Liu  <[email protected]>
+
+        EnterPictureInPictureEvent event was renamed to PictureInPictureEvent in spec
+        https://bugs.webkit.org/show_bug.cgi?id=221083
+
+        Reviewed by Youenn Fablet.
+
+        Some updates based on the spec changes:
+        - Rename EnterPictureInPictureEvent.idl to PictureInPictureEvent.idl.
+        - leavepictureinpicture event should be fired with the Picture-in-Picture window.
+        (https://github.com/w3c/picture-in-picture/issues/188)
+
+        Covered by media/picture-in-picture/picture-in-picture-api-events.html.
+
+        * CMakeLists.txt:
+        * DerivedSources-input.xcfilelist:
+        * DerivedSources-output.xcfilelist:
+        * DerivedSources.make:
+        * Modules/pictureinpicture/HTMLVideoElementPictureInPicture.cpp:
+        (WebCore::HTMLVideoElementPictureInPicture::didEnterPictureInPicture):
+        (WebCore::HTMLVideoElementPictureInPicture::didExitPictureInPicture):
+        * Modules/pictureinpicture/PictureInPictureEvent.cpp: Renamed from Source/WebCore/Modules/pictureinpicture/EnterPictureInPictureEvent.cpp.
+        (WebCore::PictureInPictureEvent::create):
+        (WebCore::PictureInPictureEvent::PictureInPictureEvent):
+        * Modules/pictureinpicture/PictureInPictureEvent.h: Renamed from Source/WebCore/Modules/pictureinpicture/EnterPictureInPictureEvent.h.
+        * Modules/pictureinpicture/PictureInPictureEvent.idl: Renamed from Source/WebCore/Modules/pictureinpicture/EnterPictureInPictureEvent.idl.
+        * Sources.txt:
+        * WebCore.xcodeproj/project.pbxproj:
+        * bindings/js/WebCoreBuiltinNames.h:
+        * dom/EventNames.in:
+
 2022-03-10  Lauro Moura  <[email protected]>
 
         Unreviewed, non-unified build fix after 248294@main

Modified: trunk/Source/WebCore/DerivedSources-input.xcfilelist (291143 => 291144)


--- trunk/Source/WebCore/DerivedSources-input.xcfilelist	2022-03-11 03:22:03 UTC (rev 291143)
+++ trunk/Source/WebCore/DerivedSources-input.xcfilelist	2022-03-11 05:03:26 UTC (rev 291144)
@@ -579,8 +579,8 @@
 $(PROJECT_DIR)/Modules/permissions/Permissions.idl
 $(PROJECT_DIR)/Modules/pictureinpicture/Document+PictureInPicture.idl
 $(PROJECT_DIR)/Modules/pictureinpicture/DocumentOrShadowRoot+PictureInPicture.idl
-$(PROJECT_DIR)/Modules/pictureinpicture/EnterPictureInPictureEvent.idl
 $(PROJECT_DIR)/Modules/pictureinpicture/HTMLVideoElement+PictureInPicture.idl
+$(PROJECT_DIR)/Modules/pictureinpicture/PictureInPictureEvent.idl
 $(PROJECT_DIR)/Modules/pictureinpicture/PictureInPictureWindow.idl
 $(PROJECT_DIR)/Modules/push-api/PushEncryptionKeyName.idl
 $(PROJECT_DIR)/Modules/push-api/PushEvent.idl

Modified: trunk/Source/WebCore/DerivedSources-output.xcfilelist (291143 => 291144)


--- trunk/Source/WebCore/DerivedSources-output.xcfilelist	2022-03-11 03:22:03 UTC (rev 291143)
+++ trunk/Source/WebCore/DerivedSources-output.xcfilelist	2022-03-11 05:03:26 UTC (rev 291144)
@@ -785,8 +785,6 @@
 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSElementContentEditable.h
 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSEndingType.cpp
 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSEndingType.h
-$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSEnterPictureInPictureEvent.cpp
-$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSEnterPictureInPictureEvent.h
 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSErrorCallback.cpp
 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSErrorCallback.h
 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSErrorEvent.cpp
@@ -1889,6 +1887,8 @@
 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSPermissionStatus.h
 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSPermissions.cpp
 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSPermissions.h
+$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSPictureInPictureEvent.cpp
+$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSPictureInPictureEvent.h
 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSPictureInPictureWindow.cpp
 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSPictureInPictureWindow.h
 $(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSPlaybackDirection.cpp

Modified: trunk/Source/WebCore/DerivedSources.make (291143 => 291144)


--- trunk/Source/WebCore/DerivedSources.make	2022-03-11 03:22:03 UTC (rev 291143)
+++ trunk/Source/WebCore/DerivedSources.make	2022-03-11 05:03:26 UTC (rev 291144)
@@ -499,8 +499,8 @@
     $(WebCore)/Modules/permissions/Permissions.idl \
     $(WebCore)/Modules/pictureinpicture/DocumentOrShadowRoot+PictureInPicture.idl \
     $(WebCore)/Modules/pictureinpicture/Document+PictureInPicture.idl \
-    $(WebCore)/Modules/pictureinpicture/EnterPictureInPictureEvent.idl \
     $(WebCore)/Modules/pictureinpicture/HTMLVideoElement+PictureInPicture.idl \
+    $(WebCore)/Modules/pictureinpicture/PictureInPictureEvent.idl \
     $(WebCore)/Modules/pictureinpicture/PictureInPictureWindow.idl \
     $(WebCore)/Modules/push-api/PushEncryptionKeyName.idl \
     $(WebCore)/Modules/push-api/PushEvent.idl \

Deleted: trunk/Source/WebCore/Modules/pictureinpicture/EnterPictureInPictureEvent.cpp (291143 => 291144)


--- trunk/Source/WebCore/Modules/pictureinpicture/EnterPictureInPictureEvent.cpp	2022-03-11 03:22:03 UTC (rev 291143)
+++ trunk/Source/WebCore/Modules/pictureinpicture/EnterPictureInPictureEvent.cpp	2022-03-11 05:03:26 UTC (rev 291144)
@@ -1,52 +0,0 @@
-/*
- * Copyright (C) 2019 Carlos Eduardo Ramalho <[email protected]>.
- * Copyright (C) 2019 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. 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 "EnterPictureInPictureEvent.h"
-
-#if ENABLE(PICTURE_IN_PICTURE_API)
-
-#include "PictureInPictureWindow.h"
-#include <wtf/IsoMallocInlines.h>
-
-namespace WebCore {
-
-WTF_MAKE_ISO_ALLOCATED_IMPL(EnterPictureInPictureEvent);
-
-Ref<EnterPictureInPictureEvent> EnterPictureInPictureEvent::create(const AtomString& type, Init&& init, IsTrusted isTrusted)
-{
-    return adoptRef(*new EnterPictureInPictureEvent(type, WTFMove(init), isTrusted));
-}
-
-EnterPictureInPictureEvent::EnterPictureInPictureEvent(const AtomString& type, Init&& init, IsTrusted isTrusted)
-    : Event(type, init, isTrusted)
-    , m_pictureInPictureWindow(init.pictureInPictureWindow.releaseNonNull())
-{
-}
-
-} // namespace WebCore
-
-#endif // ENABLE(PICTURE_IN_PICTURE_API)

Deleted: trunk/Source/WebCore/Modules/pictureinpicture/EnterPictureInPictureEvent.h (291143 => 291144)


--- trunk/Source/WebCore/Modules/pictureinpicture/EnterPictureInPictureEvent.h	2022-03-11 03:22:03 UTC (rev 291143)
+++ trunk/Source/WebCore/Modules/pictureinpicture/EnterPictureInPictureEvent.h	2022-03-11 05:03:26 UTC (rev 291144)
@@ -1,58 +0,0 @@
-/*
- * Copyright (C) 2019 Carlos Eduardo Ramalho <[email protected]>.
- * Copyright (C) 2019 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. 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(PICTURE_IN_PICTURE_API)
-
-#include "Event.h"
-
-namespace WebCore {
-
-class PictureInPictureWindow;
-
-class EnterPictureInPictureEvent final : public Event {
-    WTF_MAKE_ISO_ALLOCATED(EnterPictureInPictureEvent);
-public:
-    struct Init : EventInit {
-        RefPtr<PictureInPictureWindow> pictureInPictureWindow;
-    };
-
-    static Ref<EnterPictureInPictureEvent> create(const AtomString&, Init&&, IsTrusted = IsTrusted::No);
-
-    PictureInPictureWindow& pictureInPictureWindow() const { return m_pictureInPictureWindow.get(); }
-
-    EventInterface eventInterface() const final { return EnterPictureInPictureEventInterfaceType; }
-
-private:
-    EnterPictureInPictureEvent(const AtomString&, Init&&, IsTrusted = IsTrusted::No);
-
-    Ref<PictureInPictureWindow> m_pictureInPictureWindow;
-};
-
-} // namespace WebCore
-
-#endif // ENABLE(PICTURE_IN_PICTURE_API)

Deleted: trunk/Source/WebCore/Modules/pictureinpicture/EnterPictureInPictureEvent.idl (291143 => 291144)


--- trunk/Source/WebCore/Modules/pictureinpicture/EnterPictureInPictureEvent.idl	2022-03-11 03:22:03 UTC (rev 291143)
+++ trunk/Source/WebCore/Modules/pictureinpicture/EnterPictureInPictureEvent.idl	2022-03-11 05:03:26 UTC (rev 291144)
@@ -1,42 +0,0 @@
-/*
- * Copyright (C) 2019 Carlos Eduardo Ramalho <[email protected]>.
- * Copyright (C) 2019 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. 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=PICTURE_IN_PICTURE_API,
-    EnabledBySetting=PictureInPictureAPIEnabled
-] dictionary EnterPictureInPictureEventInit : EventInit {
-    required PictureInPictureWindow pictureInPictureWindow;
-};
-
-[
-    Conditional=PICTURE_IN_PICTURE_API,
-    EnabledBySetting=PictureInPictureAPIEnabled,
-    Exposed=Window
-] interface EnterPictureInPictureEvent : Event {
-    constructor(DOMString type, EnterPictureInPictureEventInit eventInitDict);
-
-    [SameObject] readonly attribute PictureInPictureWindow pictureInPictureWindow;
-};

Modified: trunk/Source/WebCore/Modules/pictureinpicture/HTMLVideoElementPictureInPicture.cpp (291143 => 291144)


--- trunk/Source/WebCore/Modules/pictureinpicture/HTMLVideoElementPictureInPicture.cpp	2022-03-11 03:22:03 UTC (rev 291143)
+++ trunk/Source/WebCore/Modules/pictureinpicture/HTMLVideoElementPictureInPicture.cpp	2022-03-11 05:03:26 UTC (rev 291144)
@@ -29,12 +29,12 @@
 
 #if ENABLE(PICTURE_IN_PICTURE_API)
 
-#include "EnterPictureInPictureEvent.h"
 #include "EventNames.h"
 #include "HTMLVideoElement.h"
 #include "JSDOMPromiseDeferred.h"
 #include "JSPictureInPictureWindow.h"
 #include "Logging.h"
+#include "PictureInPictureEvent.h"
 #include "PictureInPictureSupport.h"
 #include "PictureInPictureWindow.h"
 #include "VideoTrackList.h"
@@ -158,10 +158,10 @@
     m_videoElement.document().setPictureInPictureElement(&m_videoElement);
     m_pictureInPictureWindow->setSize(windowSize);
 
-    EnterPictureInPictureEvent::Init initializer;
+    PictureInPictureEvent::Init initializer;
     initializer.bubbles = true;
     initializer.pictureInPictureWindow = m_pictureInPictureWindow;
-    m_videoElement.scheduleEvent(EnterPictureInPictureEvent::create(eventNames().enterpictureinpictureEvent, WTFMove(initializer)));
+    m_videoElement.scheduleEvent(PictureInPictureEvent::create(eventNames().enterpictureinpictureEvent, WTFMove(initializer)));
 
     if (m_enterPictureInPicturePromise) {
         m_enterPictureInPicturePromise->resolve<IDLInterface<PictureInPictureWindow>>(*m_pictureInPictureWindow);
@@ -175,8 +175,12 @@
     m_videoElement.invalidateStyle();
     m_pictureInPictureWindow->close();
     m_videoElement.document().setPictureInPictureElement(nullptr);
-    m_videoElement.scheduleEvent(Event::create(eventNames().leavepictureinpictureEvent, Event::CanBubble::Yes, Event::IsCancelable::No));
 
+    PictureInPictureEvent::Init initializer;
+    initializer.bubbles = true;
+    initializer.pictureInPictureWindow = m_pictureInPictureWindow;
+    m_videoElement.scheduleEvent(PictureInPictureEvent::create(eventNames().leavepictureinpictureEvent, WTFMove(initializer)));
+
     if (m_exitPictureInPicturePromise) {
         m_exitPictureInPicturePromise->resolve();
         m_exitPictureInPicturePromise = nullptr;

Copied: trunk/Source/WebCore/Modules/pictureinpicture/PictureInPictureEvent.cpp (from rev 291143, trunk/Source/WebCore/Modules/pictureinpicture/EnterPictureInPictureEvent.cpp) (0 => 291144)


--- trunk/Source/WebCore/Modules/pictureinpicture/PictureInPictureEvent.cpp	                        (rev 0)
+++ trunk/Source/WebCore/Modules/pictureinpicture/PictureInPictureEvent.cpp	2022-03-11 05:03:26 UTC (rev 291144)
@@ -0,0 +1,52 @@
+/*
+ * Copyright (C) 2019 Carlos Eduardo Ramalho <[email protected]>.
+ * Copyright (C) 2019 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. 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 "PictureInPictureEvent.h"
+
+#if ENABLE(PICTURE_IN_PICTURE_API)
+
+#include "PictureInPictureWindow.h"
+#include <wtf/IsoMallocInlines.h>
+
+namespace WebCore {
+
+WTF_MAKE_ISO_ALLOCATED_IMPL(PictureInPictureEvent);
+
+Ref<PictureInPictureEvent> PictureInPictureEvent::create(const AtomString& type, Init&& init, IsTrusted isTrusted)
+{
+    return adoptRef(*new PictureInPictureEvent(type, WTFMove(init), isTrusted));
+}
+
+PictureInPictureEvent::PictureInPictureEvent(const AtomString& type, Init&& init, IsTrusted isTrusted)
+    : Event(type, init, isTrusted)
+    , m_pictureInPictureWindow(init.pictureInPictureWindow.releaseNonNull())
+{
+}
+
+} // namespace WebCore
+
+#endif // ENABLE(PICTURE_IN_PICTURE_API)

Copied: trunk/Source/WebCore/Modules/pictureinpicture/PictureInPictureEvent.h (from rev 291143, trunk/Source/WebCore/Modules/pictureinpicture/EnterPictureInPictureEvent.h) (0 => 291144)


--- trunk/Source/WebCore/Modules/pictureinpicture/PictureInPictureEvent.h	                        (rev 0)
+++ trunk/Source/WebCore/Modules/pictureinpicture/PictureInPictureEvent.h	2022-03-11 05:03:26 UTC (rev 291144)
@@ -0,0 +1,58 @@
+/*
+ * Copyright (C) 2019 Carlos Eduardo Ramalho <[email protected]>.
+ * Copyright (C) 2019 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. 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(PICTURE_IN_PICTURE_API)
+
+#include "Event.h"
+
+namespace WebCore {
+
+class PictureInPictureWindow;
+
+class PictureInPictureEvent final : public Event {
+    WTF_MAKE_ISO_ALLOCATED(PictureInPictureEvent);
+public:
+    struct Init : EventInit {
+        RefPtr<PictureInPictureWindow> pictureInPictureWindow;
+    };
+
+    static Ref<PictureInPictureEvent> create(const AtomString&, Init&&, IsTrusted = IsTrusted::No);
+
+    PictureInPictureWindow& pictureInPictureWindow() const { return m_pictureInPictureWindow.get(); }
+
+    EventInterface eventInterface() const final { return PictureInPictureEventInterfaceType; }
+
+private:
+    PictureInPictureEvent(const AtomString&, Init&&, IsTrusted = IsTrusted::No);
+
+    Ref<PictureInPictureWindow> m_pictureInPictureWindow;
+};
+
+} // namespace WebCore
+
+#endif // ENABLE(PICTURE_IN_PICTURE_API)

Copied: trunk/Source/WebCore/Modules/pictureinpicture/PictureInPictureEvent.idl (from rev 291143, trunk/Source/WebCore/Modules/pictureinpicture/EnterPictureInPictureEvent.idl) (0 => 291144)


--- trunk/Source/WebCore/Modules/pictureinpicture/PictureInPictureEvent.idl	                        (rev 0)
+++ trunk/Source/WebCore/Modules/pictureinpicture/PictureInPictureEvent.idl	2022-03-11 05:03:26 UTC (rev 291144)
@@ -0,0 +1,42 @@
+/*
+ * Copyright (C) 2019 Carlos Eduardo Ramalho <[email protected]>.
+ * Copyright (C) 2019 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. 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=PICTURE_IN_PICTURE_API,
+    EnabledBySetting=PictureInPictureAPIEnabled
+] dictionary PictureInPictureEventInit : EventInit {
+    required PictureInPictureWindow pictureInPictureWindow;
+};
+
+[
+    Conditional=PICTURE_IN_PICTURE_API,
+    EnabledBySetting=PictureInPictureAPIEnabled,
+    Exposed=Window
+] interface PictureInPictureEvent : Event {
+    constructor(DOMString type, PictureInPictureEventInit eventInitDict);
+
+    [SameObject] readonly attribute PictureInPictureWindow pictureInPictureWindow;
+};

Modified: trunk/Source/WebCore/Sources.txt (291143 => 291144)


--- trunk/Source/WebCore/Sources.txt	2022-03-11 03:22:03 UTC (rev 291143)
+++ trunk/Source/WebCore/Sources.txt	2022-03-11 05:03:26 UTC (rev 291144)
@@ -257,8 +257,8 @@
 Modules/permissions/PermissionStatus.cpp
 Modules/permissions/Permissions.cpp
 Modules/pictureinpicture/DocumentPictureInPicture.cpp
-Modules/pictureinpicture/EnterPictureInPictureEvent.cpp
 Modules/pictureinpicture/HTMLVideoElementPictureInPicture.cpp
+Modules/pictureinpicture/PictureInPictureEvent.cpp
 Modules/pictureinpicture/PictureInPictureWindow.cpp
 Modules/push-api/PushCrypto.cpp
 Modules/push-api/PushDatabase.cpp
@@ -3115,7 +3115,6 @@
 JSElement.cpp
 JSElementCSSInlineStyle.cpp
 JSEndingType.cpp
-JSEnterPictureInPictureEvent.cpp
 JSErrorCallback.cpp
 JSErrorEvent.cpp
 JSEvent.cpp
@@ -3594,6 +3593,7 @@
 JSPermissionState.cpp
 JSPermissionStatus.cpp
 JSPermissions.cpp
+JSPictureInPictureEvent.cpp
 JSPictureInPictureWindow.cpp
 JSPlaybackDirection.cpp
 JSPointerEvent.cpp

Modified: trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj (291143 => 291144)


--- trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj	2022-03-11 03:22:03 UTC (rev 291143)
+++ trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj	2022-03-11 05:03:26 UTC (rev 291144)
@@ -659,7 +659,7 @@
 		1D0026AA2374F9EA00CA6CDF /* JSEnterPictureInPictureEvent.h in Headers */ = {isa = PBXBuildFile; fileRef = 1D0026A82374F9D900CA6CDF /* JSEnterPictureInPictureEvent.h */; };
 		1D2C82B7236A3F6A0055D6C5 /* PictureInPictureSupport.h in Headers */ = {isa = PBXBuildFile; fileRef = 1D2C82B6236A3F6A0055D6C5 /* PictureInPictureSupport.h */; settings = {ATTRIBUTES = (Private, ); }; };
 		1D2F8E03234474EF00993B68 /* DocumentPictureInPicture.h in Headers */ = {isa = PBXBuildFile; fileRef = 1DEF06DD233D2E1C00EE228D /* DocumentPictureInPicture.h */; settings = {ATTRIBUTES = (Private, ); }; };
-		1D2F8E042344751600993B68 /* EnterPictureInPictureEvent.h in Headers */ = {isa = PBXBuildFile; fileRef = 1DEF06CA233C3D0B00EE228D /* EnterPictureInPictureEvent.h */; settings = {ATTRIBUTES = (Private, ); }; };
+		1D2F8E042344751600993B68 /* PictureInPictureEvent.h in Headers */ = {isa = PBXBuildFile; fileRef = 1DEF06CA233C3D0B00EE228D /* PictureInPictureEvent.h */; settings = {ATTRIBUTES = (Private, ); }; };
 		1D2F8E052344751D00993B68 /* HTMLVideoElementPictureInPicture.h in Headers */ = {isa = PBXBuildFile; fileRef = 1DEF06CC233C3D2000EE228D /* HTMLVideoElementPictureInPicture.h */; settings = {ATTRIBUTES = (Private, ); }; };
 		1D2F8E062344752300993B68 /* PictureInPictureWindow.h in Headers */ = {isa = PBXBuildFile; fileRef = 1DEF06CD233C3D2A00EE228D /* PictureInPictureWindow.h */; settings = {ATTRIBUTES = (Private, ); }; };
 		1D47658E25CCA778007AF312 /* ImageDecoderIdentifier.h in Headers */ = {isa = PBXBuildFile; fileRef = 1D47658D25CCA778007AF312 /* ImageDecoderIdentifier.h */; settings = {ATTRIBUTES = (Private, ); }; };
@@ -7788,13 +7788,13 @@
 		1DC553FF211BA841004B780E /* ShareData.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = ShareData.idl; sourceTree = "<group>"; };
 		1DC55400211BA8C8004B780E /* ShareData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ShareData.h; sourceTree = "<group>"; };
 		1DD127AC256E3A8700B227D7 /* SourceBufferPrivate.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = SourceBufferPrivate.cpp; sourceTree = "<group>"; };
-		1DEF06CA233C3D0B00EE228D /* EnterPictureInPictureEvent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = EnterPictureInPictureEvent.h; sourceTree = "<group>"; };
-		1DEF06CB233C3D1500EE228D /* EnterPictureInPictureEvent.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = EnterPictureInPictureEvent.cpp; sourceTree = "<group>"; };
+		1DEF06CA233C3D0B00EE228D /* PictureInPictureEvent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PictureInPictureEvent.h; sourceTree = "<group>"; };
+		1DEF06CB233C3D1500EE228D /* PictureInPictureEvent.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = PictureInPictureEvent.cpp; sourceTree = "<group>"; };
 		1DEF06CC233C3D2000EE228D /* HTMLVideoElementPictureInPicture.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HTMLVideoElementPictureInPicture.h; sourceTree = "<group>"; };
 		1DEF06CD233C3D2A00EE228D /* PictureInPictureWindow.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PictureInPictureWindow.h; sourceTree = "<group>"; };
 		1DEF06CE233C3D3100EE228D /* PictureInPictureWindow.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = PictureInPictureWindow.cpp; sourceTree = "<group>"; };
 		1DEF06CF233C3D3800EE228D /* HTMLVideoElement+PictureInPicture.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = "HTMLVideoElement+PictureInPicture.idl"; sourceTree = "<group>"; };
-		1DEF06D0233C3D4100EE228D /* EnterPictureInPictureEvent.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = EnterPictureInPictureEvent.idl; sourceTree = "<group>"; };
+		1DEF06D0233C3D4100EE228D /* PictureInPictureEvent.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = PictureInPictureEvent.idl; sourceTree = "<group>"; };
 		1DEF06D1233C3D4B00EE228D /* PictureInPictureWindow.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = PictureInPictureWindow.idl; sourceTree = "<group>"; };
 		1DEF06D2233C3D5600EE228D /* HTMLVideoElementPictureInPicture.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = HTMLVideoElementPictureInPicture.cpp; sourceTree = "<group>"; };
 		1DEF06DC233D2E1C00EE228D /* DocumentPictureInPicture.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = DocumentPictureInPicture.cpp; sourceTree = "<group>"; };
@@ -20534,12 +20534,12 @@
 				7C36556E2506DF9900A7882B /* DocumentOrShadowRoot+PictureInPicture.idl */,
 				1DEF06DC233D2E1C00EE228D /* DocumentPictureInPicture.cpp */,
 				1DEF06DD233D2E1C00EE228D /* DocumentPictureInPicture.h */,
-				1DEF06CB233C3D1500EE228D /* EnterPictureInPictureEvent.cpp */,
-				1DEF06CA233C3D0B00EE228D /* EnterPictureInPictureEvent.h */,
-				1DEF06D0233C3D4100EE228D /* EnterPictureInPictureEvent.idl */,
 				1DEF06CF233C3D3800EE228D /* HTMLVideoElement+PictureInPicture.idl */,
 				1DEF06D2233C3D5600EE228D /* HTMLVideoElementPictureInPicture.cpp */,
 				1DEF06CC233C3D2000EE228D /* HTMLVideoElementPictureInPicture.h */,
+				1DEF06CB233C3D1500EE228D /* PictureInPictureEvent.cpp */,
+				1DEF06CA233C3D0B00EE228D /* PictureInPictureEvent.h */,
+				1DEF06D0233C3D4100EE228D /* PictureInPictureEvent.idl */,
 				1DEF06CE233C3D3100EE228D /* PictureInPictureWindow.cpp */,
 				1DEF06CD233C3D2A00EE228D /* PictureInPictureWindow.h */,
 				1DEF06D1233C3D4B00EE228D /* PictureInPictureWindow.idl */,
@@ -34524,7 +34524,6 @@
 				93849C1F24BE404B00448D5A /* EmptyScriptExecutionContext.h in Headers */,
 				7C77C3D71DEF850A00A50BFA /* EndingType.h in Headers */,
 				F403E7872363B58C00044550 /* EnterKeyHint.h in Headers */,
-				1D2F8E042344751600993B68 /* EnterPictureInPictureEvent.h in Headers */,
 				05FD69E012845D4300B2BEB3 /* EpochTimeStamp.h in Headers */,
 				FD31609312B026F700C1A359 /* EqualPowerPanner.h in Headers */,
 				8371AC3B1F509BE400FBF284 /* ErrorCallback.h in Headers */,
@@ -36681,6 +36680,7 @@
 				93B0A65B26CDD14100AA21E4 /* PermissionState.h in Headers */,
 				93B0A65626CDD14100AA21E4 /* PermissionStatus.h in Headers */,
 				49D5DC2E0F423A73008F20FD /* PerspectiveTransformOperation.h in Headers */,
+				1D2F8E042344751600993B68 /* PictureInPictureEvent.h in Headers */,
 				1DBC1B562347B3D200B901AF /* PictureInPictureObserver.h in Headers */,
 				1D2C82B7236A3F6A0055D6C5 /* PictureInPictureSupport.h in Headers */,
 				1D2F8E062344752300993B68 /* PictureInPictureWindow.h in Headers */,

Modified: trunk/Source/WebCore/bindings/js/WebCoreBuiltinNames.h (291143 => 291144)


--- trunk/Source/WebCore/bindings/js/WebCoreBuiltinNames.h	2022-03-11 03:22:03 UTC (rev 291143)
+++ trunk/Source/WebCore/bindings/js/WebCoreBuiltinNames.h	2022-03-11 05:03:26 UTC (rev 291144)
@@ -124,7 +124,6 @@
     macro(DelayNode) \
     macro(DocumentTimeline) \
     macro(DynamicsCompressorNode) \
-    macro(EnterPictureInPictureEvent) \
     macro(ExtendableEvent) \
     macro(ExtendableMessageEvent) \
     macro(FakeXRDevice) \
@@ -253,6 +252,7 @@
     macro(PaymentRequestUpdateEvent) \
     macro(PaymentResponse) \
     macro(PerformanceNavigationTiming) \
+    macro(PictureInPictureEvent) \
     macro(PictureInPictureWindow) \
     macro(PaintWorkletGlobalScope) \
     macro(PerformanceEntry) \

Modified: trunk/Source/WebCore/dom/EventNames.in (291143 => 291144)


--- trunk/Source/WebCore/dom/EventNames.in	2022-03-11 03:22:03 UTC (rev 291143)
+++ trunk/Source/WebCore/dom/EventNames.in	2022-03-11 05:03:26 UTC (rev 291144)
@@ -93,7 +93,7 @@
 MediaEncryptedEvent conditional=ENCRYPTED_MEDIA
 MediaKeyMessageEvent conditional=ENCRYPTED_MEDIA
 PointerEvent
-EnterPictureInPictureEvent conditional=PICTURE_IN_PICTURE_API
+PictureInPictureEvent conditional=PICTURE_IN_PICTURE_API
 XRInputSourceEvent conditional=WEBXR
 XRInputSourcesChangeEvent conditional=WEBXR
 XRReferenceSpaceEvent conditional=WEBXR

Modified: trunk/Tools/ChangeLog (291143 => 291144)


--- trunk/Tools/ChangeLog	2022-03-11 03:22:03 UTC (rev 291143)
+++ trunk/Tools/ChangeLog	2022-03-11 05:03:26 UTC (rev 291144)
@@ -1,3 +1,12 @@
+2022-03-10  Peng Liu  <[email protected]>
+
+        EnterPictureInPictureEvent event was renamed to PictureInPictureEvent in spec
+        https://bugs.webkit.org/show_bug.cgi?id=221083
+
+        Reviewed by Youenn Fablet.
+
+        * TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:
+
 2022-03-10  Jonathan Bedard  <[email protected]>
 
         [git-webkit] Support multiple metadata locations

Modified: trunk/Tools/TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm (291143 => 291144)


--- trunk/Tools/TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm	2022-03-11 03:22:03 UTC (rev 291143)
+++ trunk/Tools/TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm	2022-03-11 05:03:26 UTC (rev 291144)
@@ -7822,7 +7822,7 @@
     EXPECT_EQ(runJSCheck("!!window.Gamepad"_s), shouldBeEnabled == ShouldBeEnabled::Yes); // Gamepad API.
     EXPECT_EQ(runJSCheck("!!window.RemotePlayback"_s), shouldBeEnabled == ShouldBeEnabled::Yes); // Remote Playback.
     EXPECT_EQ(runJSCheck("!!window.FileSystemHandle"_s), isShowingInitialEmptyDocument != IsShowingInitialEmptyDocument::Yes && shouldBeEnabled == ShouldBeEnabled::Yes); // File System Access.
-    EXPECT_EQ(runJSCheck("!!window.EnterPictureInPictureEvent"_s), shouldBeEnabled == ShouldBeEnabled::Yes); // Picture in Picture API.
+    EXPECT_EQ(runJSCheck("!!window.PictureInPictureEvent"_s), shouldBeEnabled == ShouldBeEnabled::Yes); // Picture in Picture API.
     EXPECT_EQ(runJSCheck("!!window.SpeechRecognitionEvent"_s), shouldBeEnabled == ShouldBeEnabled::Yes); // Speech recognition.
     EXPECT_EQ(runJSCheck("!!window.Notification"_s), shouldBeEnabled == ShouldBeEnabled::Yes); // Notification API.
     EXPECT_EQ(runJSCheck("!!window.WebXRSystem"_s), false); // WebXR (currently always disabled).
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to