Title: [231969] releases/WebKitGTK/webkit-2.20
Revision
231969
Author
[email protected]
Date
2018-05-18 11:42:18 -0700 (Fri, 18 May 2018)

Log Message

Merge r231917 - [WPE] Implement and enable FULLSCREEN_API
https://bugs.webkit.org/show_bug.cgi?id=185676

Reviewed by Žan Doberšek.

.:

Remove the CMake option to disable this option for WPE.
This feature gets enabled now via Source/cmake/WebKitFeatures.cmake

* Source/cmake/OptionsWPE.cmake:

Source/WebKit:

Do the initial implementation of FULLSCREEN_API for WPE and
enable the CMake option by default.

Most of the layout tests (55 of 58) are passing and the feature
seems to work fine on different websites that use it.

* UIProcess/API/wpe/PageClientImpl.cpp:
(WebKit::PageClientImpl::fullScreenManagerProxyClient):
(WebKit::PageClientImpl::closeFullScreenManager):
(WebKit::PageClientImpl::isFullScreen):
(WebKit::PageClientImpl::enterFullScreen):
(WebKit::PageClientImpl::exitFullScreen):
(WebKit::PageClientImpl::beganEnterFullScreen):
(WebKit::PageClientImpl::beganExitFullScreen):
* UIProcess/API/wpe/PageClientImpl.h:
* UIProcess/API/wpe/WPEView.h:
(WKWPE::View::isFullScreen):
(WKWPE::View::setFullScreen):

Tools:

* TestWebKitAPI/Tests/WebKitGLib/TestWebKitWebView.cpp:
(testWebViewFullScreen):

LayoutTests:

Enable all the 58 fullscreen related tests.
Are all passing but 3.

* platform/wpe/TestExpectations:
* platform/wpe/fullscreen/full-screen-placeholder-expected.txt: Added. Copied baseline from WebKitGTK+ port.

Modified Paths

Added Paths

Diff

Modified: releases/WebKitGTK/webkit-2.20/ChangeLog (231968 => 231969)


--- releases/WebKitGTK/webkit-2.20/ChangeLog	2018-05-18 18:28:37 UTC (rev 231968)
+++ releases/WebKitGTK/webkit-2.20/ChangeLog	2018-05-18 18:42:18 UTC (rev 231969)
@@ -1,3 +1,15 @@
+2018-05-17  Carlos Alberto Lopez Perez  <[email protected]>
+
+        [WPE] Implement and enable FULLSCREEN_API
+        https://bugs.webkit.org/show_bug.cgi?id=185676
+
+        Reviewed by Žan Doberšek.
+
+        Remove the CMake option to disable this option for WPE.
+        This feature gets enabled now via Source/cmake/WebKitFeatures.cmake
+
+        * Source/cmake/OptionsWPE.cmake:
+
 2018-05-10  Michael Catanzaro  <[email protected]>
 
         Unreviewed. Update OptionsWPE.cmake and NEWS for 2.19.93 release.

Modified: releases/WebKitGTK/webkit-2.20/LayoutTests/ChangeLog (231968 => 231969)


--- releases/WebKitGTK/webkit-2.20/LayoutTests/ChangeLog	2018-05-18 18:28:37 UTC (rev 231968)
+++ releases/WebKitGTK/webkit-2.20/LayoutTests/ChangeLog	2018-05-18 18:42:18 UTC (rev 231969)
@@ -1,3 +1,16 @@
+2018-05-17  Carlos Alberto Lopez Perez  <[email protected]>
+
+        [WPE] Implement and enable FULLSCREEN_API
+        https://bugs.webkit.org/show_bug.cgi?id=185676
+
+        Reviewed by Žan Doberšek.
+
+        Enable all the 58 fullscreen related tests.
+        Are all passing but 3.
+
+        * platform/wpe/TestExpectations:
+        * platform/wpe/fullscreen/full-screen-placeholder-expected.txt: Added. Copied baseline from WebKitGTK+ port.
+
 2018-04-24  Tadeu Zagallo  <[email protected]>
 
         REGRESSION(r221839): Fix requests with FormData containing empty files

Modified: releases/WebKitGTK/webkit-2.20/LayoutTests/platform/wpe/TestExpectations (231968 => 231969)


--- releases/WebKitGTK/webkit-2.20/LayoutTests/platform/wpe/TestExpectations	2018-05-18 18:28:37 UTC (rev 231968)
+++ releases/WebKitGTK/webkit-2.20/LayoutTests/platform/wpe/TestExpectations	2018-05-18 18:42:18 UTC (rev 231969)
@@ -1,7 +1,6 @@
 Bug(WPE) compositing/ [ Skip ]
 Bug(WPE) editing/ [ Skip ]
 Bug(WPE) fonts/ [ Skip ]
-Bug(WPE) fullscreen/ [ Skip ]
 Bug(WPE) gamepad/ [ Skip ]
 Bug(WPE) inspector/ [ Skip ]
 Bug(WPE) mathml/ [ Skip ]
@@ -1031,7 +1030,6 @@
 http/tests/download [ Skip ]
 http/tests/fileapi [ Skip ]
 http/tests/frame-throttling [ Skip ]
-http/tests/fullscreen [ Skip ]
 http/tests/globalhistory [ Skip ]
 http/tests/history [ Skip ]
 http/tests/inspector [ Skip ]
@@ -1173,3 +1171,8 @@
 webkit.org/b/182244 http/tests/appcache/fail-on-update-2.html [ Failure ]
 
 webkit.org/b/181139 imported/w3c/web-platform-tests/WebCryptoAPI/encrypt_decrypt/test_rsa_oaep.https.html [ Pass Failure ]
+
+# This 3 fullscreen tests are still not passing.
+webkit.org/b/185676 fullscreen/requestFullscreen-escape-key.html [ Failure ]
+webkit.org/b/185676 fullscreen/video-controls-rtl.html [ Failure ]
+webkit.org/b/185676 fullscreen/full-screen-plugin.html [ Timeout ]

Added: releases/WebKitGTK/webkit-2.20/LayoutTests/platform/wpe/fullscreen/full-screen-placeholder-expected.txt (0 => 231969)


--- releases/WebKitGTK/webkit-2.20/LayoutTests/platform/wpe/fullscreen/full-screen-placeholder-expected.txt	                        (rev 0)
+++ releases/WebKitGTK/webkit-2.20/LayoutTests/platform/wpe/fullscreen/full-screen-placeholder-expected.txt	2018-05-18 18:42:18 UTC (rev 231969)
@@ -0,0 +1,17 @@
+This layout test checks that the offset positions of the blue and green divs does not change when the red div enters full-screen mode. Press go full-screen to begin.
+One
+Two
+EVENT(webkitfullscreenchange)
+EXPECTED (document.webkitCurrentFullScreenElement == '[object HTMLDivElement]') OK
+EXPECTED (one.offsetLeft == '68') OK
+EXPECTED (one.offsetTop == '57') OK
+EXPECTED (two.offsetLeft == '8') OK
+EXPECTED (two.offsetTop == '117') OK
+EVENT(webkitfullscreenchange)
+EXPECTED (document.webkitCurrentFullScreenElement == 'null') OK
+EXPECTED (one.offsetLeft == '68') OK
+EXPECTED (one.offsetTop == '57') OK
+EXPECTED (two.offsetLeft == '8') OK
+EXPECTED (two.offsetTop == '117') OK
+END OF TEST
+

Modified: releases/WebKitGTK/webkit-2.20/Source/WebKit/ChangeLog (231968 => 231969)


--- releases/WebKitGTK/webkit-2.20/Source/WebKit/ChangeLog	2018-05-18 18:28:37 UTC (rev 231968)
+++ releases/WebKitGTK/webkit-2.20/Source/WebKit/ChangeLog	2018-05-18 18:42:18 UTC (rev 231969)
@@ -1,3 +1,29 @@
+2018-05-17  Carlos Alberto Lopez Perez  <[email protected]>
+
+        [WPE] Implement and enable FULLSCREEN_API
+        https://bugs.webkit.org/show_bug.cgi?id=185676
+
+        Reviewed by Žan Doberšek.
+
+        Do the initial implementation of FULLSCREEN_API for WPE and
+        enable the CMake option by default.
+
+        Most of the layout tests (55 of 58) are passing and the feature
+        seems to work fine on different websites that use it.
+
+        * UIProcess/API/wpe/PageClientImpl.cpp:
+        (WebKit::PageClientImpl::fullScreenManagerProxyClient):
+        (WebKit::PageClientImpl::closeFullScreenManager):
+        (WebKit::PageClientImpl::isFullScreen):
+        (WebKit::PageClientImpl::enterFullScreen):
+        (WebKit::PageClientImpl::exitFullScreen):
+        (WebKit::PageClientImpl::beganEnterFullScreen):
+        (WebKit::PageClientImpl::beganExitFullScreen):
+        * UIProcess/API/wpe/PageClientImpl.h:
+        * UIProcess/API/wpe/WPEView.h:
+        (WKWPE::View::isFullScreen):
+        (WKWPE::View::setFullScreen):
+
 2018-05-10  Michael Catanzaro  <[email protected]>
 
         Unreviewed. Update OptionsWPE.cmake and NEWS for 2.19.93 release.

Modified: releases/WebKitGTK/webkit-2.20/Source/WebKit/UIProcess/API/wpe/PageClientImpl.cpp (231968 => 231969)


--- releases/WebKitGTK/webkit-2.20/Source/WebKit/UIProcess/API/wpe/PageClientImpl.cpp	2018-05-18 18:28:37 UTC (rev 231968)
+++ releases/WebKitGTK/webkit-2.20/Source/WebKit/UIProcess/API/wpe/PageClientImpl.cpp	2018-05-18 18:42:18 UTC (rev 231969)
@@ -326,4 +326,58 @@
     return m_view._javascript_GlobalContext();
 }
 
+#if ENABLE(FULLSCREEN_API)
+WebFullScreenManagerProxyClient& PageClientImpl::fullScreenManagerProxyClient()
+{
+    return *this;
+}
+
+void PageClientImpl::closeFullScreenManager()
+{
+    notImplemented();
+}
+
+bool PageClientImpl::isFullScreen()
+{
+    return m_view.isFullScreen();
+}
+
+void PageClientImpl::enterFullScreen()
+{
+    if (isFullScreen())
+        return;
+
+    WebFullScreenManagerProxy* fullScreenManagerProxy = m_view.page().fullScreenManager();
+    if (fullScreenManagerProxy) {
+        fullScreenManagerProxy->willEnterFullScreen();
+        m_view.setFullScreen(true);
+        fullScreenManagerProxy->didEnterFullScreen();
+    }
+}
+
+void PageClientImpl::exitFullScreen()
+{
+    if (!isFullScreen())
+        return;
+
+    WebFullScreenManagerProxy* fullScreenManagerProxy = m_view.page().fullScreenManager();
+    if (fullScreenManagerProxy) {
+        fullScreenManagerProxy->willExitFullScreen();
+        m_view.setFullScreen(false);
+        fullScreenManagerProxy->didExitFullScreen();
+    }
+}
+
+void PageClientImpl::beganEnterFullScreen(const WebCore::IntRect& /* initialFrame */, const WebCore::IntRect& /* finalFrame */)
+{
+    notImplemented();
+}
+
+void PageClientImpl::beganExitFullScreen(const WebCore::IntRect& /* initialFrame */, const WebCore::IntRect& /* finalFrame */)
+{
+    notImplemented();
+}
+
+#endif // ENABLE(FULLSCREEN_API)
+
 } // namespace WebKit

Modified: releases/WebKitGTK/webkit-2.20/Source/WebKit/UIProcess/API/wpe/PageClientImpl.h (231968 => 231969)


--- releases/WebKitGTK/webkit-2.20/Source/WebKit/UIProcess/API/wpe/PageClientImpl.h	2018-05-18 18:28:37 UTC (rev 231968)
+++ releases/WebKitGTK/webkit-2.20/Source/WebKit/UIProcess/API/wpe/PageClientImpl.h	2018-05-18 18:42:18 UTC (rev 231969)
@@ -26,6 +26,7 @@
 #pragma once
 
 #include "PageClient.h"
+#include "WebFullScreenManagerProxy.h"
 
 namespace WKWPE {
 class View;
@@ -35,7 +36,11 @@
 
 class ScrollGestureController;
 
-class PageClientImpl final : public PageClient {
+class PageClientImpl final : public PageClient
+#if ENABLE(FULLSCREEN_API)
+    , public WebFullScreenManagerProxyClient
+#endif
+{
 public:
     PageClientImpl(WKWPE::View&);
     virtual ~PageClientImpl();
@@ -117,6 +122,17 @@
 
     void didRestoreScrollPosition() override;
 
+#if ENABLE(FULLSCREEN_API)
+    WebFullScreenManagerProxyClient& fullScreenManagerProxyClient() final;
+
+    void closeFullScreenManager() override;
+    bool isFullScreen() override;
+    void enterFullScreen() override;
+    void exitFullScreen() override;
+    void beganEnterFullScreen(const WebCore::IntRect& initialFrame, const WebCore::IntRect& finalFrame) override;
+    void beganExitFullScreen(const WebCore::IntRect& initialFrame, const WebCore::IntRect& finalFrame) override;
+#endif
+
     WebCore::UserInterfaceLayoutDirection userInterfaceLayoutDirection() override;
 
     JSGlobalContextRef _javascript_GlobalContext() override;

Modified: releases/WebKitGTK/webkit-2.20/Source/WebKit/UIProcess/API/wpe/WPEView.h (231968 => 231969)


--- releases/WebKitGTK/webkit-2.20/Source/WebKit/UIProcess/API/wpe/WPEView.h	2018-05-18 18:28:37 UTC (rev 231968)
+++ releases/WebKitGTK/webkit-2.20/Source/WebKit/UIProcess/API/wpe/WPEView.h	2018-05-18 18:42:18 UTC (rev 231969)
@@ -73,6 +73,11 @@
 
     void close();
 
+#if ENABLE(FULLSCREEN_API)
+    bool isFullScreen() { return m_fullScreenModeActive; };
+    void setFullScreen(bool fullScreenState) { m_fullScreenModeActive = fullScreenState; };
+#endif
+
 private:
     View(struct wpe_view_backend*, const API::PageConfiguration&);
 
@@ -87,6 +92,10 @@
 
     WebKit::CompositingManagerProxy m_compositingManagerProxy;
     struct wpe_view_backend* m_backend;
+
+#if ENABLE(FULLSCREEN_API)
+    bool m_fullScreenModeActive { false };
+#endif
 };
 
 } // namespace WKWPE

Modified: releases/WebKitGTK/webkit-2.20/Source/cmake/OptionsWPE.cmake (231968 => 231969)


--- releases/WebKitGTK/webkit-2.20/Source/cmake/OptionsWPE.cmake	2018-05-18 18:28:37 UTC (rev 231968)
+++ releases/WebKitGTK/webkit-2.20/Source/cmake/OptionsWPE.cmake	2018-05-18 18:42:18 UTC (rev 231969)
@@ -30,7 +30,6 @@
 # Private options shared with other WebKit ports. Add options here only if
 # we need a value different from the default defined in WebKitFeatures.cmake.
 # Changing these options is completely unsupported.
-WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_FULLSCREEN_API PRIVATE OFF)
 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_GEOLOCATION PRIVATE OFF)
 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_MHTML PRIVATE ON)
 WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_NETSCAPE_PLUGIN_API PRIVATE OFF)

Modified: releases/WebKitGTK/webkit-2.20/Tools/ChangeLog (231968 => 231969)


--- releases/WebKitGTK/webkit-2.20/Tools/ChangeLog	2018-05-18 18:28:37 UTC (rev 231968)
+++ releases/WebKitGTK/webkit-2.20/Tools/ChangeLog	2018-05-18 18:42:18 UTC (rev 231969)
@@ -1,3 +1,13 @@
+2018-05-17  Carlos Alberto Lopez Perez  <[email protected]>
+
+        [WPE] Implement and enable FULLSCREEN_API
+        https://bugs.webkit.org/show_bug.cgi?id=185676
+
+        Reviewed by Žan Doberšek.
+
+        * TestWebKitAPI/Tests/WebKitGLib/TestWebKitWebView.cpp:
+        (testWebViewFullScreen):
+
 2018-05-10  Michael Catanzaro  <[email protected]>
 
         Fix some -Wstring-op-truncation warnings

Modified: releases/WebKitGTK/webkit-2.20/Tools/TestWebKitAPI/Tests/WebKitGLib/TestWebKitWebView.cpp (231968 => 231969)


--- releases/WebKitGTK/webkit-2.20/Tools/TestWebKitAPI/Tests/WebKitGLib/TestWebKitWebView.cpp	2018-05-18 18:28:37 UTC (rev 231968)
+++ releases/WebKitGTK/webkit-2.20/Tools/TestWebKitAPI/Tests/WebKitGLib/TestWebKitWebView.cpp	2018-05-18 18:42:18 UTC (rev 231969)
@@ -433,7 +433,9 @@
 #if ENABLE(FULLSCREEN_API)
 static void testWebViewFullScreen(FullScreenClientTest* test, gconstpointer)
 {
+#if PLATFORM(GTK)
     test->showInWindowAndWaitUntilMapped();
+#endif
     test->loadHtml("<html><body>FullScreen test</body></html>", 0);
     test->waitUntilLoadFinished();
     test->requestFullScreenAndWaitUntilEnteredFullScreen();
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to