[WPE] Do not use a sync IPC message to send the host FD to the web process
authorcarlosgc@webkit.org <carlosgc@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 11 Feb 2019 08:12:04 +0000 (08:12 +0000)
committercarlosgc@webkit.org <carlosgc@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 11 Feb 2019 08:12:04 +0000 (08:12 +0000)
https://bugs.webkit.org/show_bug.cgi?id=194216

Reviewed by Darin Adler.

It can be sent as a web page creation parameter instead.

* PlatformWPE.cmake:
* Shared/WebPageCreationParameters.cpp:
(WebKit::WebPageCreationParameters::encode const):
(WebKit::WebPageCreationParameters::decode):
* Shared/WebPageCreationParameters.h:
* SourcesWPE.txt:
* UIProcess/API/wpe/CompositingManagerProxy.cpp: Removed.
* UIProcess/API/wpe/CompositingManagerProxy.h: Removed.
* UIProcess/API/wpe/CompositingManagerProxy.messages.in: Removed.
* UIProcess/API/wpe/PageClientImpl.cpp:
(WebKit::PageClientImpl::hostFileDescriptor):
* UIProcess/API/wpe/PageClientImpl.h:
* UIProcess/API/wpe/WPEView.cpp:
(WKWPE::m_backend):
* UIProcess/API/wpe/WPEView.h:
(WKWPE::View::create):
* UIProcess/PageClient.h:
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::creationParameters):
* WebProcess/WebPage/WebPage.cpp:
(WebKit::m_hostFileDescriptor):
* WebProcess/WebPage/WebPage.h:
(WebKit::WebPage::releaseHostFileDescriptor):
* WebProcess/WebPage/wpe/AcceleratedSurfaceWPE.cpp:
(WebKit::AcceleratedSurfaceWPE::AcceleratedSurfaceWPE):
(WebKit::AcceleratedSurfaceWPE::initialize):
* WebProcess/WebPage/wpe/AcceleratedSurfaceWPE.h:
* WebProcess/WebPage/wpe/CompositingManager.cpp: Removed.
* WebProcess/WebPage/wpe/CompositingManager.h: Removed.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241260 268f45cc-cd09-0410-ab3c-d52691b4dbfc

20 files changed:
Source/WebKit/ChangeLog
Source/WebKit/PlatformWPE.cmake
Source/WebKit/Shared/WebPageCreationParameters.cpp
Source/WebKit/Shared/WebPageCreationParameters.h
Source/WebKit/SourcesWPE.txt
Source/WebKit/UIProcess/API/wpe/CompositingManagerProxy.cpp [deleted file]
Source/WebKit/UIProcess/API/wpe/CompositingManagerProxy.h [deleted file]
Source/WebKit/UIProcess/API/wpe/CompositingManagerProxy.messages.in [deleted file]
Source/WebKit/UIProcess/API/wpe/PageClientImpl.cpp
Source/WebKit/UIProcess/API/wpe/PageClientImpl.h
Source/WebKit/UIProcess/API/wpe/WPEView.cpp
Source/WebKit/UIProcess/API/wpe/WPEView.h
Source/WebKit/UIProcess/PageClient.h
Source/WebKit/UIProcess/WebPageProxy.cpp
Source/WebKit/WebProcess/WebPage/WebPage.cpp
Source/WebKit/WebProcess/WebPage/WebPage.h
Source/WebKit/WebProcess/WebPage/wpe/AcceleratedSurfaceWPE.cpp
Source/WebKit/WebProcess/WebPage/wpe/AcceleratedSurfaceWPE.h
Source/WebKit/WebProcess/WebPage/wpe/CompositingManager.cpp [deleted file]
Source/WebKit/WebProcess/WebPage/wpe/CompositingManager.h [deleted file]

index 4cddacd..9f28c33 100644 (file)
@@ -1,3 +1,42 @@
+2019-02-10  Carlos Garcia Campos  <cgarcia@igalia.com>
+
+        [WPE] Do not use a sync IPC message to send the host FD to the web process
+        https://bugs.webkit.org/show_bug.cgi?id=194216
+
+        Reviewed by Darin Adler.
+
+        It can be sent as a web page creation parameter instead.
+
+        * PlatformWPE.cmake:
+        * Shared/WebPageCreationParameters.cpp:
+        (WebKit::WebPageCreationParameters::encode const):
+        (WebKit::WebPageCreationParameters::decode):
+        * Shared/WebPageCreationParameters.h:
+        * SourcesWPE.txt:
+        * UIProcess/API/wpe/CompositingManagerProxy.cpp: Removed.
+        * UIProcess/API/wpe/CompositingManagerProxy.h: Removed.
+        * UIProcess/API/wpe/CompositingManagerProxy.messages.in: Removed.
+        * UIProcess/API/wpe/PageClientImpl.cpp:
+        (WebKit::PageClientImpl::hostFileDescriptor):
+        * UIProcess/API/wpe/PageClientImpl.h:
+        * UIProcess/API/wpe/WPEView.cpp:
+        (WKWPE::m_backend):
+        * UIProcess/API/wpe/WPEView.h:
+        (WKWPE::View::create):
+        * UIProcess/PageClient.h:
+        * UIProcess/WebPageProxy.cpp:
+        (WebKit::WebPageProxy::creationParameters):
+        * WebProcess/WebPage/WebPage.cpp:
+        (WebKit::m_hostFileDescriptor):
+        * WebProcess/WebPage/WebPage.h:
+        (WebKit::WebPage::releaseHostFileDescriptor):
+        * WebProcess/WebPage/wpe/AcceleratedSurfaceWPE.cpp:
+        (WebKit::AcceleratedSurfaceWPE::AcceleratedSurfaceWPE):
+        (WebKit::AcceleratedSurfaceWPE::initialize):
+        * WebProcess/WebPage/wpe/AcceleratedSurfaceWPE.h:
+        * WebProcess/WebPage/wpe/CompositingManager.cpp: Removed.
+        * WebProcess/WebPage/wpe/CompositingManager.h: Removed.
+
 2019-02-04  Carlos Garcia Campos  <cgarcia@igalia.com>
 
         [GTK][WPE] Add enable-javascript-markup setting
index df1594f..0fbe5e2 100644 (file)
@@ -77,8 +77,6 @@ list(APPEND WebKit_UNIFIED_SOURCE_LIST_FILES
 list(APPEND WebKit_MESSAGES_IN_FILES
     NetworkProcess/CustomProtocols/LegacyCustomProtocolManager.messages.in
 
-    UIProcess/API/wpe/CompositingManagerProxy.messages.in
-
     UIProcess/Network/CustomProtocols/LegacyCustomProtocolManagerProxy.messages.in
 )
 
index b164cad..a249a66 100644 (file)
@@ -98,6 +98,9 @@ void WebPageCreationParameters::encode(IPC::Encoder& encoder) const
     encoder << smartInsertDeleteEnabled;
     encoder << additionalSupportedImageTypes;
 #endif
+#if PLATFORM(WPE)
+    encoder << hostFileDescriptor;
+#endif
     encoder << appleMailPaginationQuirkEnabled;
     encoder << appleMailLinesClampEnabled;
     encoder << shouldScaleViewToFitDocument;
@@ -275,6 +278,11 @@ Optional<WebPageCreationParameters> WebPageCreationParameters::decode(IPC::Decod
         return WTF::nullopt;
 #endif
 
+#if PLATFORM(WPE)
+    if (!decoder.decode(parameters.hostFileDescriptor))
+        return WTF::nullopt;
+#endif
+
     if (!decoder.decode(parameters.appleMailPaginationQuirkEnabled))
         return WTF::nullopt;
 
index d1b0303..21cae2e 100644 (file)
@@ -156,6 +156,9 @@ struct WebPageCreationParameters {
     bool smartInsertDeleteEnabled;
     Vector<String> additionalSupportedImageTypes;
 #endif
+#if PLATFORM(WPE)
+    IPC::Attachment hostFileDescriptor;
+#endif
     bool appleMailPaginationQuirkEnabled;
     bool appleMailLinesClampEnabled;
     bool shouldScaleViewToFitDocument;
index aa82fa3..4dc0f3c 100644 (file)
@@ -167,7 +167,6 @@ UIProcess/API/glib/WebKitWebsiteData.cpp @no-unify
 UIProcess/API/glib/WebKitWebsiteDataManager.cpp @no-unify
 UIProcess/API/glib/WebKitWindowProperties.cpp @no-unify
 
-UIProcess/API/wpe/CompositingManagerProxy.cpp @no-unify
 UIProcess/API/wpe/PageClientImpl.cpp @no-unify
 UIProcess/API/wpe/ScrollGestureController.cpp @no-unify
 UIProcess/API/wpe/WebKitScriptDialogWPE.cpp @no-unify
@@ -249,7 +248,6 @@ WebProcess/WebPage/CoordinatedGraphics/ThreadedCoordinatedLayerTreeHost.cpp
 WebProcess/WebPage/gstreamer/WebPageGStreamer.cpp
 
 WebProcess/WebPage/wpe/AcceleratedSurfaceWPE.cpp @no-unify
-WebProcess/WebPage/wpe/CompositingManager.cpp
 WebProcess/WebPage/wpe/WebInspectorUIWPE.cpp
 WebProcess/WebPage/wpe/WebPageWPE.cpp
 
diff --git a/Source/WebKit/UIProcess/API/wpe/CompositingManagerProxy.cpp b/Source/WebKit/UIProcess/API/wpe/CompositingManagerProxy.cpp
deleted file mode 100644 (file)
index f15547d..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-/*
- * Copyright (C) 2015 Igalia S.L.
- *
- * 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 "CompositingManagerProxy.h"
-
-#include "Attachment.h"
-#include "CompositingManagerProxyMessages.h"
-#include "WPEView.h"
-#include "WebProcessPool.h"
-#include "WebProcessProxy.h"
-#include <wpe/wpe.h>
-
-namespace WebKit {
-
-CompositingManagerProxy::CompositingManagerProxy(WKWPE::View& view)
-    : m_view(view)
-{
-}
-
-CompositingManagerProxy::~CompositingManagerProxy() = default;
-
-void CompositingManagerProxy::initialize()
-{
-    m_view.page().process().processPool().addMessageReceiver(Messages::CompositingManagerProxy::messageReceiverName(), m_view.page().pageID(), *this);
-}
-
-void CompositingManagerProxy::finalize()
-{
-    m_view.page().process().processPool().removeMessageReceiver(Messages::CompositingManagerProxy::messageReceiverName(), m_view.page().pageID());
-}
-
-void CompositingManagerProxy::establishConnection(IPC::Attachment& connectionHandle)
-{
-    connectionHandle = IPC::Attachment(wpe_view_backend_get_renderer_host_fd(m_view.backend()));
-}
-
-} // namespace WebKit
diff --git a/Source/WebKit/UIProcess/API/wpe/CompositingManagerProxy.h b/Source/WebKit/UIProcess/API/wpe/CompositingManagerProxy.h
deleted file mode 100644 (file)
index 22c2dfc..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-/*
- * Copyright (C) 2015 Igalia S.L.
- *
- * 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
-
-#include "MessageReceiver.h"
-#include <wtf/Noncopyable.h>
-
-namespace IPC {
-class Attachment;
-}
-
-namespace WKWPE {
-class View;
-}
-
-namespace WebKit {
-
-class CompositingManagerProxy final : public IPC::MessageReceiver {
-    WTF_MAKE_NONCOPYABLE(CompositingManagerProxy);
-public:
-    CompositingManagerProxy(WKWPE::View&);
-    virtual ~CompositingManagerProxy();
-
-    void initialize();
-    void finalize();
-
-private:
-    // IPC::MessageReceiver
-    void didReceiveMessage(IPC::Connection&, IPC::Decoder&) override { }
-    void didReceiveSyncMessage(IPC::Connection&, IPC::Decoder&, std::unique_ptr<IPC::Encoder>& replyEncoder) override;
-
-    void establishConnection(IPC::Attachment&);
-
-    WKWPE::View& m_view;
-};
-
-} // namespace WebKit
diff --git a/Source/WebKit/UIProcess/API/wpe/CompositingManagerProxy.messages.in b/Source/WebKit/UIProcess/API/wpe/CompositingManagerProxy.messages.in
deleted file mode 100644 (file)
index b30ef91..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-# Copyright (C) 2015 Igalia S.L.
-#
-# 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.
-
-messages -> CompositingManagerProxy {
-    EstablishConnection() -> (IPC::Attachment connectionHandle) LegacySync
-}
index 2233615..c34810e 100644 (file)
@@ -51,6 +51,11 @@ struct wpe_view_backend* PageClientImpl::viewBackend()
     return m_view.backend();
 }
 
+IPC::Attachment PageClientImpl::hostFileDescriptor()
+{
+    return wpe_view_backend_get_renderer_host_fd(m_view.backend());
+}
+
 std::unique_ptr<DrawingAreaProxy> PageClientImpl::createDrawingAreaProxy(WebProcessProxy& process)
 {
     return std::make_unique<AcceleratedDrawingAreaProxy>(m_view.page(), process);
index b699f29..f9e25b7 100644 (file)
@@ -143,6 +143,8 @@ private:
 
     void didFinishProcessingAllPendingMouseEvents() final { }
 
+    IPC::Attachment hostFileDescriptor() final;
+
     WebCore::UserInterfaceLayoutDirection userInterfaceLayoutDirection() override;
 
     WKWPE::View& m_view;
index afdbd07..eb13b43 100644 (file)
@@ -48,7 +48,6 @@ View::View(struct wpe_view_backend* backend, const API::PageConfiguration& baseC
 #if !defined(WPE_BACKEND_CHECK_VERSION) || !WPE_BACKEND_CHECK_VERSION(1, 1, 0)
     , m_viewStateFlags { WebCore::ActivityState::WindowIsActive, WebCore::ActivityState::IsFocused, WebCore::ActivityState::IsVisible, WebCore::ActivityState::IsInWindow }
 #endif
-    , m_compositingManagerProxy(*this)
     , m_backend(backend)
 {
     ASSERT(m_backend);
@@ -75,8 +74,6 @@ View::View(struct wpe_view_backend* backend, const API::PageConfiguration& baseC
         pool->startMemorySampler(0);
 #endif
 
-    m_compositingManagerProxy.initialize();
-
     static struct wpe_view_backend_client s_backendClient = {
         // set_size
         [](void* data, uint32_t width, uint32_t height)
@@ -162,11 +159,6 @@ View::View(struct wpe_view_backend* backend, const API::PageConfiguration& baseC
     m_pageProxy->initializeWebPage();
 }
 
-View::~View()
-{
-    m_compositingManagerProxy.finalize();
-}
-
 void View::setClient(std::unique_ptr<API::ViewClient>&& client)
 {
     if (!client)
index 99bf278..0dfc42f 100644 (file)
@@ -26,7 +26,6 @@
 #pragma once
 
 #include "APIObject.h"
-#include "CompositingManagerProxy.h"
 #include "PageClientImpl.h"
 #include "WebPageProxy.h"
 #include <WebCore/ActivityState.h>
@@ -55,7 +54,6 @@ public:
     {
         return new View(backend, configuration);
     }
-    virtual ~View();
 
     // Client methods
     void setClient(std::unique_ptr<API::ViewClient>&&);
@@ -90,7 +88,6 @@ private:
     WebCore::IntSize m_size;
     OptionSet<WebCore::ActivityState::Flag> m_viewStateFlags;
 
-    WebKit::CompositingManagerProxy m_compositingManagerProxy;
     struct wpe_view_backend* m_backend;
 
 #if ENABLE(FULLSCREEN_API)
index 3961ed4..3c2dc01 100644 (file)
@@ -483,6 +483,9 @@ public:
     virtual void cancelPointersForGestureRecognizer(UIGestureRecognizer*) { }
 #endif
 
+#if PLATFORM(WPE)
+    virtual IPC::Attachment hostFileDescriptor() = 0;
+#endif
 };
 
 } // namespace WebKit
index 779264d..94bb07b 100644 (file)
@@ -6869,6 +6869,10 @@ WebPageCreationParameters WebPageProxy::creationParameters(WebProcessProxy& proc
     parameters.overrideContentSecurityPolicy = m_overrideContentSecurityPolicy;
     parameters.cpuLimit = m_cpuLimit;
 
+#if PLATFORM(WPE)
+    parameters.hostFileDescriptor = pageClient().hostFileDescriptor();
+#endif
+
     for (auto& iterator : m_urlSchemeHandlersByScheme)
         parameters.urlSchemeHandlers.set(iterator.key, iterator.value->identifier());
 
index 2023fe4..dfefe43 100644 (file)
@@ -404,6 +404,9 @@ WebPage::WebPage(uint64_t pageID, WebPageCreationParameters&& parameters)
     , m_userInterfaceLayoutDirection(parameters.userInterfaceLayoutDirection)
     , m_overrideContentSecurityPolicy { parameters.overrideContentSecurityPolicy }
     , m_cpuLimit(parameters.cpuLimit)
+#if PLATFORM(WPE)
+    , m_hostFileDescriptor(WTFMove(parameters.hostFileDescriptor))
+#endif
 {
     ASSERT(m_pageID);
 
index e2460cb..b913332 100644 (file)
@@ -1129,6 +1129,10 @@ public:
     void didFinishLoadingApplicationManifest(uint64_t, const Optional<WebCore::ApplicationManifest>&);
 #endif
 
+#if PLATFORM(WPE)
+    int releaseHostFileDescriptor() { return m_hostFileDescriptor.releaseFileDescriptor(); }
+#endif
+
     void updateCurrentModifierState(OptionSet<WebCore::PlatformEvent::Modifier> modifiers);
 
     UserContentControllerIdentifier userContentControllerIdentifier() const { return m_userContentController->identifier(); }
@@ -1821,6 +1825,10 @@ private:
     const String m_overrideContentSecurityPolicy;
     const Optional<double> m_cpuLimit;
 
+#if PLATFORM(WPE)
+    IPC::Attachment m_hostFileDescriptor;
+#endif
+
     HashMap<String, RefPtr<WebURLSchemeHandlerProxy>> m_schemeToURLSchemeHandlerProxyMap;
     HashMap<uint64_t, WebURLSchemeHandlerProxy*> m_identifierToURLSchemeHandlerProxyMap;
 
index e953bc3..9b8ccbc 100644 (file)
@@ -41,7 +41,6 @@ std::unique_ptr<AcceleratedSurfaceWPE> AcceleratedSurfaceWPE::create(WebPage& we
 AcceleratedSurfaceWPE::AcceleratedSurfaceWPE(WebPage& webPage, Client& client)
     : AcceleratedSurface(webPage, client)
 {
-    m_compositingManager.establishConnection(webPage);
 }
 
 AcceleratedSurfaceWPE::~AcceleratedSurfaceWPE()
@@ -51,7 +50,7 @@ AcceleratedSurfaceWPE::~AcceleratedSurfaceWPE()
 
 void AcceleratedSurfaceWPE::initialize()
 {
-    m_backend = wpe_renderer_backend_egl_target_create(m_compositingManager.releaseConnectionFd());
+    m_backend = wpe_renderer_backend_egl_target_create(m_webPage.releaseHostFileDescriptor());
     static struct wpe_renderer_backend_egl_target_client s_client = {
         // frame_complete
         [](void* data)
index 69e5c26..18fc9d5 100644 (file)
@@ -28,7 +28,6 @@
 #if PLATFORM(WPE)
 
 #include "AcceleratedSurface.h"
-#include "CompositingManager.h"
 
 struct wpe_renderer_backend_egl_target;
 
@@ -55,7 +54,6 @@ public:
 private:
     AcceleratedSurfaceWPE(WebPage&, Client&);
 
-    CompositingManager m_compositingManager;
     struct wpe_renderer_backend_egl_target* m_backend { nullptr };
 };
 
diff --git a/Source/WebKit/WebProcess/WebPage/wpe/CompositingManager.cpp b/Source/WebKit/WebProcess/WebPage/wpe/CompositingManager.cpp
deleted file mode 100644 (file)
index d515a0b..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Copyright (C) 2015 Igalia S.L.
- *
- * 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 "CompositingManager.h"
-
-#include "CompositingManagerProxyMessages.h"
-#include "WebPage.h"
-
-namespace WebKit {
-
-CompositingManager::~CompositingManager()
-{
-    ASSERT(!m_connectionFd);
-}
-
-void CompositingManager::establishConnection(WebPage& webPage)
-{
-    IPC::Attachment connectionHandle;
-    webPage.sendSync(Messages::CompositingManagerProxy::EstablishConnection(),
-        Messages::CompositingManagerProxy::EstablishConnection::Reply(connectionHandle));
-
-    m_connectionFd = connectionHandle.releaseFileDescriptor();
-}
-
-int CompositingManager::releaseConnectionFd()
-{
-    int fd = m_connectionFd.valueOr(-1);
-    m_connectionFd = WTF::nullopt;
-    return fd;
-}
-
-} // namespace WebKit
diff --git a/Source/WebKit/WebProcess/WebPage/wpe/CompositingManager.h b/Source/WebKit/WebProcess/WebPage/wpe/CompositingManager.h
deleted file mode 100644 (file)
index d6adf2c..0000000
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Copyright (C) 2015 Igalia S.L.
- *
- * 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
-
-#include <wtf/Noncopyable.h>
-#include <wtf/Optional.h>
-
-namespace WebKit {
-
-class WebPage;
-
-class CompositingManager final {
-    WTF_MAKE_NONCOPYABLE(CompositingManager);
-public:
-    CompositingManager() = default;
-    ~CompositingManager();
-
-    void establishConnection(WebPage&);
-    int releaseConnectionFd();
-
-private:
-    Optional<int> m_connectionFd;
-};
-
-} // namespace WebKit