WebKit Bugzilla
Attachment 358311 Details for
Bug 193133
: [Nicosia] Take over CoordinatedGraphics-named implementation of async scrolling classes
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-193133-20190104091817.patch (text/plain), 67.89 KB, created by
Zan Dobersek
on 2019-01-04 00:18:19 PST
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Zan Dobersek
Created:
2019-01-04 00:18:19 PST
Size:
67.89 KB
patch
obsolete
>Subversion Revision: 239605 >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index a3920592b9bfc7162155886a8cb9413b43718659..60e415f91572df7aeff7a817273cbc0318d37371 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,32 @@ >+2019-01-03 Zan Dobersek <zdobersek@igalia.com> >+ >+ [Nicosia] Take over CoordinatedGraphics-named implementation of async scrolling classes >+ https://bugs.webkit.org/show_bug.cgi?id=193133 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Move the CoordinatedGraphics-specific files under >+ page/scrolling/coordinatedgraphics/ to page/scrolling/nicosia/, along >+ with renaming the files and classes accordingly. Implementation will >+ only depend on the Nicosia-specific layer structure and is not specific >+ to the CoordinatedGraphics system. >+ >+ * PlatformPlayStation.cmake: >+ * SourcesGTK.txt: >+ * SourcesWPE.txt: >+ * page/scrolling/nicosia/ScrollingCoordinatorNicosia.cpp: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.cpp. >+ * page/scrolling/nicosia/ScrollingCoordinatorNicosia.h: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.h. >+ * page/scrolling/nicosia/ScrollingStateNodeNicosia.cpp: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingStateNodeCoordinatedGraphics.cpp. >+ * page/scrolling/nicosia/ScrollingTreeFixedNode.cpp: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeFixedNode.cpp. >+ * page/scrolling/nicosia/ScrollingTreeFixedNode.h: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeFixedNode.h. >+ * page/scrolling/nicosia/ScrollingTreeFrameScrollingNodeNicosia.cpp: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeFrameScrollingNodeCoordinatedGraphics.cpp. >+ * page/scrolling/nicosia/ScrollingTreeFrameScrollingNodeNicosia.h: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeFrameScrollingNodeCoordinatedGraphics.h. >+ * page/scrolling/nicosia/ScrollingTreeNicosia.cpp: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeCoordinatedGraphics.cpp. >+ * page/scrolling/nicosia/ScrollingTreeNicosia.h: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeCoordinatedGraphics.h. >+ * page/scrolling/nicosia/ScrollingTreeStickyNode.cpp: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeStickyNode.cpp. >+ * page/scrolling/nicosia/ScrollingTreeStickyNode.h: Renamed from Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeStickyNode.h. >+ * platform/TextureMapper.cmake: >+ > 2019-01-03 Zalan Bujtas <zalan@apple.com> > > REGRESSION: -webkit-appearance test case crashes >diff --git a/Source/WebCore/PlatformPlayStation.cmake b/Source/WebCore/PlatformPlayStation.cmake >index 184363f1c17d03867fc366f7bd4d23272e502f6a..90376039b9696e13f9debc9c4730a79039979551 100644 >--- a/Source/WebCore/PlatformPlayStation.cmake >+++ b/Source/WebCore/PlatformPlayStation.cmake >@@ -18,12 +18,12 @@ list(APPEND WebCore_INCLUDE_DIRECTORIES > list(APPEND WebCore_SOURCES > editing/libwpe/EditorLibWPE.cpp > >- page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.cpp >- page/scrolling/coordinatedgraphics/ScrollingStateNodeCoordinatedGraphics.cpp >- page/scrolling/coordinatedgraphics/ScrollingTreeCoordinatedGraphics.cpp >- page/scrolling/coordinatedgraphics/ScrollingTreeFixedNode.cpp >- page/scrolling/coordinatedgraphics/ScrollingTreeFrameScrollingNodeCoordinatedGraphics.cpp >- page/scrolling/coordinatedgraphics/ScrollingTreeStickyNode.cpp >+ page/scrolling/nicosia/ScrollingCoordinatorNicosia.cpp >+ page/scrolling/nicosia/ScrollingStateNodeNicosia.cpp >+ page/scrolling/nicosia/ScrollingTreeFixedNode.cpp >+ page/scrolling/nicosia/ScrollingTreeFrameScrollingNodeNicosia.cpp >+ page/scrolling/nicosia/ScrollingTreeNicosia.cpp >+ page/scrolling/nicosia/ScrollingTreeStickyNode.cpp > > page/scrolling/generic/ScrollingThreadGeneric.cpp > >diff --git a/Source/WebCore/SourcesGTK.txt b/Source/WebCore/SourcesGTK.txt >index 5e2356dbb66b2b052b69e4668a375dcfdd74b866..15a0ba83ff7897cdd690833970cdd5af87bf711e 100644 >--- a/Source/WebCore/SourcesGTK.txt >+++ b/Source/WebCore/SourcesGTK.txt >@@ -46,12 +46,12 @@ loader/soup/ResourceLoaderSoup.cpp > page/linux/ResourceUsageOverlayLinux.cpp > page/linux/ResourceUsageThreadLinux.cpp > >-page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.cpp >-page/scrolling/coordinatedgraphics/ScrollingTreeCoordinatedGraphics.cpp >-page/scrolling/coordinatedgraphics/ScrollingTreeFixedNode.cpp >-page/scrolling/coordinatedgraphics/ScrollingTreeFrameScrollingNodeCoordinatedGraphics.cpp >-page/scrolling/coordinatedgraphics/ScrollingTreeStickyNode.cpp >-page/scrolling/coordinatedgraphics/ScrollingStateNodeCoordinatedGraphics.cpp >+page/scrolling/nicosia/ScrollingCoordinatorNicosia.cpp >+page/scrolling/nicosia/ScrollingStateNodeNicosia.cpp >+page/scrolling/nicosia/ScrollingTreeFixedNode.cpp >+page/scrolling/nicosia/ScrollingTreeFrameScrollingNodeNicosia.cpp >+page/scrolling/nicosia/ScrollingTreeNicosia.cpp >+page/scrolling/nicosia/ScrollingTreeStickyNode.cpp > > page/scrolling/generic/ScrollingThreadGeneric.cpp > >diff --git a/Source/WebCore/SourcesWPE.txt b/Source/WebCore/SourcesWPE.txt >index 381e585a17761a1f6073842e4cdc5953e28739ed..3c32d895505c419bca2c5feb42e2e6544e97ca7a 100644 >--- a/Source/WebCore/SourcesWPE.txt >+++ b/Source/WebCore/SourcesWPE.txt >@@ -31,12 +31,12 @@ loader/soup/ResourceLoaderSoup.cpp > page/linux/ResourceUsageOverlayLinux.cpp > page/linux/ResourceUsageThreadLinux.cpp > >-page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.cpp >-page/scrolling/coordinatedgraphics/ScrollingTreeCoordinatedGraphics.cpp >-page/scrolling/coordinatedgraphics/ScrollingTreeFixedNode.cpp >-page/scrolling/coordinatedgraphics/ScrollingTreeFrameScrollingNodeCoordinatedGraphics.cpp >-page/scrolling/coordinatedgraphics/ScrollingTreeStickyNode.cpp >-page/scrolling/coordinatedgraphics/ScrollingStateNodeCoordinatedGraphics.cpp >+page/scrolling/nicosia/ScrollingCoordinatorNicosia.cpp >+page/scrolling/nicosia/ScrollingStateNodeNicosia.cpp >+page/scrolling/nicosia/ScrollingTreeFixedNode.cpp >+page/scrolling/nicosia/ScrollingTreeFrameScrollingNodeNicosia.cpp >+page/scrolling/nicosia/ScrollingTreeNicosia.cpp >+page/scrolling/nicosia/ScrollingTreeStickyNode.cpp > > page/scrolling/generic/ScrollingThreadGeneric.cpp > >diff --git a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.cpp b/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.cpp >deleted file mode 100644 >index 830353648ce06a867780ea26c41865cc3579a8e9..0000000000000000000000000000000000000000 >--- a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.cpp >+++ /dev/null >@@ -1,96 +0,0 @@ >-/* >- * Copyright (C) 2018 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 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 >- * HOLDER 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. >- */ >- >-#include "config.h" >-#include "ScrollingCoordinatorCoordinatedGraphics.h" >- >-#if ENABLE(ASYNC_SCROLLING) && USE(COORDINATED_GRAPHICS) >- >-#include "ScrollingThread.h" >-#include "ScrollingTreeCoordinatedGraphics.h" >- >-namespace WebCore { >- >-Ref<ScrollingCoordinator> ScrollingCoordinator::create(Page* page) >-{ >- return adoptRef(*new ScrollingCoordinatorCoordinatedGraphics(page)); >-} >- >-ScrollingCoordinatorCoordinatedGraphics::ScrollingCoordinatorCoordinatedGraphics(Page* page) >- : AsyncScrollingCoordinator(page) >- , m_scrollingStateTreeCommitterTimer(RunLoop::main(), this, &ScrollingCoordinatorCoordinatedGraphics::commitTreeState) >-{ >- setScrollingTree(ScrollingTreeCoordinatedGraphics::create(*this)); >-} >- >-ScrollingCoordinatorCoordinatedGraphics::~ScrollingCoordinatorCoordinatedGraphics() >-{ >- ASSERT(!scrollingTree()); >-} >- >-void ScrollingCoordinatorCoordinatedGraphics::pageDestroyed() >-{ >- AsyncScrollingCoordinator::pageDestroyed(); >- >- m_scrollingStateTreeCommitterTimer.stop(); >- >- releaseScrollingTree(); >-} >- >-void ScrollingCoordinatorCoordinatedGraphics::commitTreeStateIfNeeded() >-{ >- commitTreeState(); >- m_scrollingStateTreeCommitterTimer.stop(); >-} >- >-bool ScrollingCoordinatorCoordinatedGraphics::handleWheelEvent(FrameView&, const PlatformWheelEvent&) >-{ >- return false; >-} >- >-void ScrollingCoordinatorCoordinatedGraphics::scheduleTreeStateCommit() >-{ >- if (!m_scrollingStateTreeCommitterTimer.isActive()) >- m_scrollingStateTreeCommitterTimer.startOneShot(0_s); >-} >- >-void ScrollingCoordinatorCoordinatedGraphics::commitTreeState() >-{ >- if (!scrollingStateTree()->hasChangedProperties()) >- return; >- >- RefPtr<ThreadedScrollingTree> threadedScrollingTree = downcast<ThreadedScrollingTree>(scrollingTree()); >- >- auto treeState = scrollingStateTree()->commit(LayerRepresentation::PlatformLayerRepresentation); >- ScrollingThread::dispatch([threadedScrollingTree, treeState = WTFMove(treeState)]() mutable { >- threadedScrollingTree->commitTreeState(WTFMove(treeState)); >- }); >-} >- >-} // namespace WebCore >- >-#endif // ENABLE(ASYNC_SCROLLING) && USE(COORDINATED_GRAPHICS) >diff --git a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.h b/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.h >deleted file mode 100644 >index 8257422ec9eda0657712f5c626e11ef3345b4633..0000000000000000000000000000000000000000 >--- a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.h >+++ /dev/null >@@ -1,59 +0,0 @@ >-/* >- * Copyright (C) 2018 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 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 >- * HOLDER 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. >- */ >- >-#pragma once >- >-#if ENABLE(ASYNC_SCROLLING) && USE(COORDINATED_GRAPHICS) >- >-#include "AsyncScrollingCoordinator.h" >- >-#include <wtf/RunLoop.h> >- >-namespace WebCore { >- >-class ScrollingCoordinatorCoordinatedGraphics final : public AsyncScrollingCoordinator { >-public: >- explicit ScrollingCoordinatorCoordinatedGraphics(Page*); >- virtual ~ScrollingCoordinatorCoordinatedGraphics(); >- >- void pageDestroyed() override; >- >- void commitTreeStateIfNeeded() override; >- >- bool handleWheelEvent(FrameView&, const PlatformWheelEvent&) override; >- >-private: >- void scheduleTreeStateCommit() override; >- >- void commitTreeState(); >- >- RunLoop::Timer<ScrollingCoordinatorCoordinatedGraphics> m_scrollingStateTreeCommitterTimer; >-}; >- >-} // namespace WebCore >- >-#endif // ENABLE(ASYNC_SCROLLING) && USE(COORDINATED_GRAPHICS) >diff --git a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingStateNodeCoordinatedGraphics.cpp b/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingStateNodeCoordinatedGraphics.cpp >deleted file mode 100644 >index 3d68ae66a8fb6f19e859d7b9aa5080b0b1e6fc13..0000000000000000000000000000000000000000 >--- a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingStateNodeCoordinatedGraphics.cpp >+++ /dev/null >@@ -1,59 +0,0 @@ >-/* >- * Copyright (C) 2013 Intel Corporation. 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 "ScrollingStateNode.h" >- >-#include "GraphicsLayer.h" >-#include "NotImplemented.h" >-#include "ScrollingStateTree.h" >- >-#if USE(COORDINATED_GRAPHICS) >- >-namespace WebCore { >- >-void LayerRepresentation::retainPlatformLayer(void*) >-{ >- notImplemented(); >-} >- >-void LayerRepresentation::releasePlatformLayer(void*) >-{ >- notImplemented(); >-} >- >-PlatformLayer* LayerRepresentation::makePlatformLayerTyped(void* typelessLayer) >-{ >- return static_cast<PlatformLayer*>(typelessLayer); >-} >- >-void* LayerRepresentation::makePlatformLayerTypeless(PlatformLayer* layer) >-{ >- return layer; >-} >- >-} // namespace WebCore >- >-#endif // USE(COORDINATED_GRAPHICS) >diff --git a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeCoordinatedGraphics.cpp b/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeCoordinatedGraphics.cpp >deleted file mode 100644 >index 88d69ab74c40d39313cd1bd5469fea0d26bf279b..0000000000000000000000000000000000000000 >--- a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeCoordinatedGraphics.cpp >+++ /dev/null >@@ -1,69 +0,0 @@ >-/* >- * Copyright (C) 2018 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 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 >- * HOLDER 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. >- */ >- >-#include "config.h" >-#include "ScrollingTreeCoordinatedGraphics.h" >- >-#if ENABLE(ASYNC_SCROLLING) && USE(COORDINATED_GRAPHICS) >- >-#include "ScrollingTreeFixedNode.h" >-#include "ScrollingTreeFrameScrollingNodeCoordinatedGraphics.h" >-#include "ScrollingTreeStickyNode.h" >- >-namespace WebCore { >- >-Ref<ScrollingTreeCoordinatedGraphics> ScrollingTreeCoordinatedGraphics::create(AsyncScrollingCoordinator& scrollingCoordinator) >-{ >- return adoptRef(*new ScrollingTreeCoordinatedGraphics(scrollingCoordinator)); >-} >- >-ScrollingTreeCoordinatedGraphics::ScrollingTreeCoordinatedGraphics(AsyncScrollingCoordinator& scrollingCoordinator) >- : ThreadedScrollingTree(scrollingCoordinator) >-{ >-} >- >-Ref<ScrollingTreeNode> ScrollingTreeCoordinatedGraphics::createScrollingTreeNode(ScrollingNodeType nodeType, ScrollingNodeID nodeID) >-{ >- switch (nodeType) { >- case ScrollingNodeType::MainFrame: >- case ScrollingNodeType::Subframe: >- return ScrollingTreeFrameScrollingNodeCoordinatedGraphics::create(*this, nodeType, nodeID); >- case ScrollingNodeType::Overflow: >- // Should not be reached -- caught by ASSERT_NOT_REACHED() below. >- break; >- case ScrollingNodeType::Fixed: >- return ScrollingTreeFixedNode::create(*this, nodeID); >- case ScrollingNodeType::Sticky: >- return ScrollingTreeStickyNode::create(*this, nodeID); >- } >- >- RELEASE_ASSERT_NOT_REACHED(); >-} >- >-} // namespace WebCore >- >-#endif // ENABLE(ASYNC_SCROLLING) && USE(COORDINATED_GRAPHICS) >diff --git a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeCoordinatedGraphics.h b/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeCoordinatedGraphics.h >deleted file mode 100644 >index 45bb645eb3b6b6265658370051b28217cb49e780..0000000000000000000000000000000000000000 >--- a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeCoordinatedGraphics.h >+++ /dev/null >@@ -1,48 +0,0 @@ >-/* >- * Copyright (C) 2018 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 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 >- * HOLDER 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. >- */ >- >-#pragma once >- >-#if ENABLE(ASYNC_SCROLLING) && USE(COORDINATED_GRAPHICS) >- >-#include "ThreadedScrollingTree.h" >- >-namespace WebCore { >- >-class ScrollingTreeCoordinatedGraphics final : public ThreadedScrollingTree { >-public: >- static Ref<ScrollingTreeCoordinatedGraphics> create(AsyncScrollingCoordinator&); >- >-private: >- explicit ScrollingTreeCoordinatedGraphics(AsyncScrollingCoordinator&); >- >- Ref<ScrollingTreeNode> createScrollingTreeNode(ScrollingNodeType, ScrollingNodeID) override; >-}; >- >-} // namespace WebCore >- >-#endif // ENABLE(ASYNC_SCROLLING) && USE(COORDINATED_GRAPHICS) >diff --git a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeFixedNode.cpp b/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeFixedNode.cpp >deleted file mode 100644 >index 21db0afc1744de1f336cb4d042e829f1c059060d..0000000000000000000000000000000000000000 >--- a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeFixedNode.cpp >+++ /dev/null >@@ -1,63 +0,0 @@ >-/* >- * Copyright (C) 2018 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 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 >- * HOLDER 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. >- */ >- >-#include "config.h" >-#include "ScrollingTreeFixedNode.h" >- >-#if ENABLE(ASYNC_SCROLLING) && USE(COORDINATED_GRAPHICS) >- >-#include "ScrollingTree.h" >- >-namespace WebCore { >- >-Ref<ScrollingTreeFixedNode> ScrollingTreeFixedNode::create(ScrollingTree& scrollingTree, ScrollingNodeID nodeID) >-{ >- return adoptRef(*new ScrollingTreeFixedNode(scrollingTree, nodeID)); >-} >- >-ScrollingTreeFixedNode::ScrollingTreeFixedNode(ScrollingTree& scrollingTree, ScrollingNodeID nodeID) >- : ScrollingTreeNode(scrollingTree, ScrollingNodeType::Fixed, nodeID) >-{ >- scrollingTree.fixedOrStickyNodeAdded(); >-} >- >-ScrollingTreeFixedNode::~ScrollingTreeFixedNode() >-{ >- scrollingTree().fixedOrStickyNodeRemoved(); >-} >- >-void ScrollingTreeFixedNode::commitStateBeforeChildren(const ScrollingStateNode&) >-{ >-} >- >-void ScrollingTreeFixedNode::updateLayersAfterAncestorChange(const ScrollingTreeNode&, const FloatRect&, const FloatSize&) >-{ >-} >- >-} // namespace WebCore >- >-#endif // ENABLE(ASYNC_SCROLLING) && USE(COORDINATED_GRAPHICS) >diff --git a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeFixedNode.h b/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeFixedNode.h >deleted file mode 100644 >index d0aa8792422230cece2e63ff4f16bf779fe88a87..0000000000000000000000000000000000000000 >--- a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeFixedNode.h >+++ /dev/null >@@ -1,50 +0,0 @@ >-/* >- * Copyright (C) 2018 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 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 >- * HOLDER 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. >- */ >- >-#pragma once >- >-#if ENABLE(ASYNC_SCROLLING) && USE(COORDINATED_GRAPHICS) >- >-#include "ScrollingTreeNode.h" >- >-namespace WebCore { >- >-class ScrollingTreeFixedNode final : public ScrollingTreeNode { >-public: >- static Ref<ScrollingTreeFixedNode> create(ScrollingTree&, ScrollingNodeID); >- virtual ~ScrollingTreeFixedNode(); >- >-private: >- ScrollingTreeFixedNode(ScrollingTree&, ScrollingNodeID); >- >- void commitStateBeforeChildren(const ScrollingStateNode&) override; >- void updateLayersAfterAncestorChange(const ScrollingTreeNode&, const FloatRect&, const FloatSize&) override; >-}; >- >-} // namespace WebCore >- >-#endif // ENABLE(ASYNC_SCROLLING) && USE(COORDINATED_GRAPHICS) >diff --git a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeFrameScrollingNodeCoordinatedGraphics.cpp b/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeFrameScrollingNodeCoordinatedGraphics.cpp >deleted file mode 100644 >index ecc6f31730616030da865ffc9b8e0b93b8666362..0000000000000000000000000000000000000000 >--- a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeFrameScrollingNodeCoordinatedGraphics.cpp >+++ /dev/null >@@ -1,74 +0,0 @@ >-/* >- * Copyright (C) 2018 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 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 >- * HOLDER 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. >- */ >- >-#include "config.h" >-#include "ScrollingTreeFrameScrollingNodeCoordinatedGraphics.h" >- >-#if ENABLE(ASYNC_SCROLLING) && USE(COORDINATED_GRAPHICS) >- >-namespace WebCore { >- >-Ref<ScrollingTreeFrameScrollingNode> ScrollingTreeFrameScrollingNodeCoordinatedGraphics::create(ScrollingTree& scrollingTree, ScrollingNodeType nodeType, ScrollingNodeID nodeID) >-{ >- return adoptRef(*new ScrollingTreeFrameScrollingNodeCoordinatedGraphics(scrollingTree, nodeType, nodeID)); >-} >- >-ScrollingTreeFrameScrollingNodeCoordinatedGraphics::ScrollingTreeFrameScrollingNodeCoordinatedGraphics(ScrollingTree& scrollingTree, ScrollingNodeType nodeType, ScrollingNodeID nodeID) >- : ScrollingTreeFrameScrollingNode(scrollingTree, nodeType, nodeID) >-{ >-} >- >-ScrollingTreeFrameScrollingNodeCoordinatedGraphics::~ScrollingTreeFrameScrollingNodeCoordinatedGraphics() = default; >- >-void ScrollingTreeFrameScrollingNodeCoordinatedGraphics::handleWheelEvent(const PlatformWheelEvent&) >-{ >-} >- >-FloatPoint ScrollingTreeFrameScrollingNodeCoordinatedGraphics::scrollPosition() const >-{ >- return { }; >-} >- >-void ScrollingTreeFrameScrollingNodeCoordinatedGraphics::setScrollPosition(const FloatPoint&) >-{ >-} >- >-void ScrollingTreeFrameScrollingNodeCoordinatedGraphics::setScrollPositionWithoutContentEdgeConstraints(const FloatPoint&) >-{ >-} >- >-void ScrollingTreeFrameScrollingNodeCoordinatedGraphics::setScrollLayerPosition(const FloatPoint&, const FloatRect&) >-{ >-} >- >-void ScrollingTreeFrameScrollingNodeCoordinatedGraphics::updateLayersAfterViewportChange(const FloatRect&, double) >-{ >-} >- >-} // namespace WebCore >- >-#endif // ENABLE(ASYNC_SCROLLING) && USE(COORDINATED_GRAPHICS) >diff --git a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeFrameScrollingNodeCoordinatedGraphics.h b/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeFrameScrollingNodeCoordinatedGraphics.h >deleted file mode 100644 >index 65086cc92bdfde8d4a506671277875e3be32593f..0000000000000000000000000000000000000000 >--- a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeFrameScrollingNodeCoordinatedGraphics.h >+++ /dev/null >@@ -1,56 +0,0 @@ >-/* >- * Copyright (C) 2018 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 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 >- * HOLDER 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. >- */ >- >-#pragma once >- >-#if ENABLE(ASYNC_SCROLLING) && USE(COORDINATED_GRAPHICS) >- >-#include "ScrollingTreeFrameScrollingNode.h" >- >-namespace WebCore { >- >-class ScrollingTreeFrameScrollingNodeCoordinatedGraphics final : public ScrollingTreeFrameScrollingNode { >-public: >- static Ref<ScrollingTreeFrameScrollingNode> create(ScrollingTree&, ScrollingNodeType, ScrollingNodeID); >- virtual ~ScrollingTreeFrameScrollingNodeCoordinatedGraphics(); >- >-private: >- ScrollingTreeFrameScrollingNodeCoordinatedGraphics(ScrollingTree&, ScrollingNodeType, ScrollingNodeID); >- >- void handleWheelEvent(const PlatformWheelEvent&) override; >- >- FloatPoint scrollPosition() const override; >- void setScrollPosition(const FloatPoint&) override; >- void setScrollPositionWithoutContentEdgeConstraints(const FloatPoint&) override; >- void setScrollLayerPosition(const FloatPoint&, const FloatRect&) override; >- >- void updateLayersAfterViewportChange(const FloatRect&, double) override; >-}; >- >-} // namespace WebCore >- >-#endif // ENABLE(ASYNC_SCROLLING) && USE(COORDINATED_GRAPHICS) >diff --git a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeStickyNode.cpp b/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeStickyNode.cpp >deleted file mode 100644 >index d130de36a3b4ba3e141bb5ffc90980b0fe278421..0000000000000000000000000000000000000000 >--- a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeStickyNode.cpp >+++ /dev/null >@@ -1,63 +0,0 @@ >-/* >- * Copyright (C) 2018 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 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 >- * HOLDER 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. >- */ >- >-#include "config.h" >-#include "ScrollingTreeStickyNode.h" >- >-#if ENABLE(ASYNC_SCROLLING) && USE(COORDINATED_GRAPHICS) >- >-#include "ScrollingTree.h" >- >-namespace WebCore { >- >-Ref<ScrollingTreeStickyNode> ScrollingTreeStickyNode::create(ScrollingTree& scrollingTree, ScrollingNodeID nodeID) >-{ >- return adoptRef(*new ScrollingTreeStickyNode(scrollingTree, nodeID)); >-} >- >-ScrollingTreeStickyNode::ScrollingTreeStickyNode(ScrollingTree& scrollingTree, ScrollingNodeID nodeID) >- : ScrollingTreeNode(scrollingTree, ScrollingNodeType::Sticky, nodeID) >-{ >- scrollingTree.fixedOrStickyNodeAdded(); >-} >- >-ScrollingTreeStickyNode::~ScrollingTreeStickyNode() >-{ >- scrollingTree().fixedOrStickyNodeRemoved(); >-} >- >-void ScrollingTreeStickyNode::commitStateBeforeChildren(const ScrollingStateNode&) >-{ >-} >- >-void ScrollingTreeStickyNode::updateLayersAfterAncestorChange(const ScrollingTreeNode&, const FloatRect&, const FloatSize&) >-{ >-} >- >-} // namespace WebCore >- >-#endif // ENABLE(ASYNC_SCROLLING) && USE(COORDINATED_GRAPHICS) >diff --git a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeStickyNode.h b/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeStickyNode.h >deleted file mode 100644 >index f3133a708c7a6c3a545eff879a7a0df15c7b53e8..0000000000000000000000000000000000000000 >--- a/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingTreeStickyNode.h >+++ /dev/null >@@ -1,50 +0,0 @@ >-/* >- * Copyright (C) 2018 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 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 >- * HOLDER 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. >- */ >- >-#pragma once >- >-#if ENABLE(ASYNC_SCROLLING) && USE(COORDINATED_GRAPHICS) >- >-#include "ScrollingTreeNode.h" >- >-namespace WebCore { >- >-class ScrollingTreeStickyNode final : public ScrollingTreeNode { >-public: >- static Ref<ScrollingTreeStickyNode> create(ScrollingTree&, ScrollingNodeID); >- virtual ~ScrollingTreeStickyNode(); >- >-private: >- ScrollingTreeStickyNode(ScrollingTree&, ScrollingNodeID); >- >- void commitStateBeforeChildren(const ScrollingStateNode&) override; >- void updateLayersAfterAncestorChange(const ScrollingTreeNode&, const FloatRect&, const FloatSize&) override; >-}; >- >-} // namespace WebCore >- >-#endif // ENABLE(ASYNC_SCROLLING) && USE(COORDINATED_GRAPHICS) >diff --git a/Source/WebCore/page/scrolling/nicosia/ScrollingCoordinatorNicosia.cpp b/Source/WebCore/page/scrolling/nicosia/ScrollingCoordinatorNicosia.cpp >new file mode 100644 >index 0000000000000000000000000000000000000000..68eaa980107bbdd0a57fbe0f059ea84e26baa5eb >--- /dev/null >+++ b/Source/WebCore/page/scrolling/nicosia/ScrollingCoordinatorNicosia.cpp >@@ -0,0 +1,96 @@ >+/* >+ * Copyright (C) 2018 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 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 >+ * HOLDER 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. >+ */ >+ >+#include "config.h" >+#include "ScrollingCoordinatorNicosia.h" >+ >+#if ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >+ >+#include "ScrollingThread.h" >+#include "ScrollingTreeNicosia.h" >+ >+namespace WebCore { >+ >+Ref<ScrollingCoordinator> ScrollingCoordinator::create(Page* page) >+{ >+ return adoptRef(*new ScrollingCoordinatorNicosia(page)); >+} >+ >+ScrollingCoordinatorNicosia::ScrollingCoordinatorNicosia(Page* page) >+ : AsyncScrollingCoordinator(page) >+ , m_scrollingStateTreeCommitterTimer(RunLoop::main(), this, &ScrollingCoordinatorNicosia::commitTreeState) >+{ >+ setScrollingTree(ScrollingTreeNicosia::create(*this)); >+} >+ >+ScrollingCoordinatorNicosia::~ScrollingCoordinatorNicosia() >+{ >+ ASSERT(!scrollingTree()); >+} >+ >+void ScrollingCoordinatorNicosia::pageDestroyed() >+{ >+ AsyncScrollingCoordinator::pageDestroyed(); >+ >+ m_scrollingStateTreeCommitterTimer.stop(); >+ >+ releaseScrollingTree(); >+} >+ >+void ScrollingCoordinatorNicosia::commitTreeStateIfNeeded() >+{ >+ commitTreeState(); >+ m_scrollingStateTreeCommitterTimer.stop(); >+} >+ >+bool ScrollingCoordinatorNicosia::handleWheelEvent(FrameView&, const PlatformWheelEvent&) >+{ >+ return false; >+} >+ >+void ScrollingCoordinatorNicosia::scheduleTreeStateCommit() >+{ >+ if (!m_scrollingStateTreeCommitterTimer.isActive()) >+ m_scrollingStateTreeCommitterTimer.startOneShot(0_s); >+} >+ >+void ScrollingCoordinatorNicosia::commitTreeState() >+{ >+ if (!scrollingStateTree()->hasChangedProperties()) >+ return; >+ >+ RefPtr<ThreadedScrollingTree> threadedScrollingTree = downcast<ThreadedScrollingTree>(scrollingTree()); >+ >+ auto treeState = scrollingStateTree()->commit(LayerRepresentation::PlatformLayerRepresentation); >+ ScrollingThread::dispatch([threadedScrollingTree, treeState = WTFMove(treeState)]() mutable { >+ threadedScrollingTree->commitTreeState(WTFMove(treeState)); >+ }); >+} >+ >+} // namespace WebCore >+ >+#endif // ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >diff --git a/Source/WebCore/page/scrolling/nicosia/ScrollingCoordinatorNicosia.h b/Source/WebCore/page/scrolling/nicosia/ScrollingCoordinatorNicosia.h >new file mode 100644 >index 0000000000000000000000000000000000000000..71cc9fa5240c6aa70b897097b9b4cf83fff5cbd9 >--- /dev/null >+++ b/Source/WebCore/page/scrolling/nicosia/ScrollingCoordinatorNicosia.h >@@ -0,0 +1,59 @@ >+/* >+ * Copyright (C) 2018 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 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 >+ * HOLDER 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. >+ */ >+ >+#pragma once >+ >+#if ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >+ >+#include "AsyncScrollingCoordinator.h" >+ >+#include <wtf/RunLoop.h> >+ >+namespace WebCore { >+ >+class ScrollingCoordinatorNicosia final : public AsyncScrollingCoordinator { >+public: >+ explicit ScrollingCoordinatorNicosia(Page*); >+ virtual ~ScrollingCoordinatorNicosia(); >+ >+ void pageDestroyed() override; >+ >+ void commitTreeStateIfNeeded() override; >+ >+ bool handleWheelEvent(FrameView&, const PlatformWheelEvent&) override; >+ >+private: >+ void scheduleTreeStateCommit() override; >+ >+ void commitTreeState(); >+ >+ RunLoop::Timer<ScrollingCoordinatorNicosia> m_scrollingStateTreeCommitterTimer; >+}; >+ >+} // namespace WebCore >+ >+#endif // ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >diff --git a/Source/WebCore/page/scrolling/nicosia/ScrollingStateNodeNicosia.cpp b/Source/WebCore/page/scrolling/nicosia/ScrollingStateNodeNicosia.cpp >new file mode 100644 >index 0000000000000000000000000000000000000000..b5328eb4372331839248b8a7c86f116716b118db >--- /dev/null >+++ b/Source/WebCore/page/scrolling/nicosia/ScrollingStateNodeNicosia.cpp >@@ -0,0 +1,58 @@ >+/* >+ * Copyright (C) 2013 Intel Corporation. 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 "ScrollingStateNode.h" >+ >+#include "GraphicsLayer.h" >+#include "NotImplemented.h" >+ >+#if ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >+ >+namespace WebCore { >+ >+void LayerRepresentation::retainPlatformLayer(void*) >+{ >+ notImplemented(); >+} >+ >+void LayerRepresentation::releasePlatformLayer(void*) >+{ >+ notImplemented(); >+} >+ >+PlatformLayer* LayerRepresentation::makePlatformLayerTyped(void* typelessLayer) >+{ >+ return static_cast<PlatformLayer*>(typelessLayer); >+} >+ >+void* LayerRepresentation::makePlatformLayerTypeless(PlatformLayer* layer) >+{ >+ return layer; >+} >+ >+} // namespace WebCore >+ >+#endif // ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >diff --git a/Source/WebCore/page/scrolling/nicosia/ScrollingTreeFixedNode.cpp b/Source/WebCore/page/scrolling/nicosia/ScrollingTreeFixedNode.cpp >new file mode 100644 >index 0000000000000000000000000000000000000000..62a6b0bd33abc5e80ddb85d9c750f9cf27ce990b >--- /dev/null >+++ b/Source/WebCore/page/scrolling/nicosia/ScrollingTreeFixedNode.cpp >@@ -0,0 +1,63 @@ >+/* >+ * Copyright (C) 2018 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 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 >+ * HOLDER 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. >+ */ >+ >+#include "config.h" >+#include "ScrollingTreeFixedNode.h" >+ >+#if ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >+ >+#include "ScrollingTree.h" >+ >+namespace WebCore { >+ >+Ref<ScrollingTreeFixedNode> ScrollingTreeFixedNode::create(ScrollingTree& scrollingTree, ScrollingNodeID nodeID) >+{ >+ return adoptRef(*new ScrollingTreeFixedNode(scrollingTree, nodeID)); >+} >+ >+ScrollingTreeFixedNode::ScrollingTreeFixedNode(ScrollingTree& scrollingTree, ScrollingNodeID nodeID) >+ : ScrollingTreeNode(scrollingTree, ScrollingNodeType::Fixed, nodeID) >+{ >+ scrollingTree.fixedOrStickyNodeAdded(); >+} >+ >+ScrollingTreeFixedNode::~ScrollingTreeFixedNode() >+{ >+ scrollingTree().fixedOrStickyNodeRemoved(); >+} >+ >+void ScrollingTreeFixedNode::commitStateBeforeChildren(const ScrollingStateNode&) >+{ >+} >+ >+void ScrollingTreeFixedNode::updateLayersAfterAncestorChange(const ScrollingTreeNode&, const FloatRect&, const FloatSize&) >+{ >+} >+ >+} // namespace WebCore >+ >+#endif // ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >diff --git a/Source/WebCore/page/scrolling/nicosia/ScrollingTreeFixedNode.h b/Source/WebCore/page/scrolling/nicosia/ScrollingTreeFixedNode.h >new file mode 100644 >index 0000000000000000000000000000000000000000..85edd0ff716dd9c0f9c0c70a5850214ef9a0ff08 >--- /dev/null >+++ b/Source/WebCore/page/scrolling/nicosia/ScrollingTreeFixedNode.h >@@ -0,0 +1,50 @@ >+/* >+ * Copyright (C) 2018 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 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 >+ * HOLDER 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. >+ */ >+ >+#pragma once >+ >+#if ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >+ >+#include "ScrollingTreeNode.h" >+ >+namespace WebCore { >+ >+class ScrollingTreeFixedNode final : public ScrollingTreeNode { >+public: >+ static Ref<ScrollingTreeFixedNode> create(ScrollingTree&, ScrollingNodeID); >+ virtual ~ScrollingTreeFixedNode(); >+ >+private: >+ ScrollingTreeFixedNode(ScrollingTree&, ScrollingNodeID); >+ >+ void commitStateBeforeChildren(const ScrollingStateNode&) override; >+ void updateLayersAfterAncestorChange(const ScrollingTreeNode&, const FloatRect&, const FloatSize&) override; >+}; >+ >+} // namespace WebCore >+ >+#endif // ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >diff --git a/Source/WebCore/page/scrolling/nicosia/ScrollingTreeFrameScrollingNodeNicosia.cpp b/Source/WebCore/page/scrolling/nicosia/ScrollingTreeFrameScrollingNodeNicosia.cpp >new file mode 100644 >index 0000000000000000000000000000000000000000..9b049b807921d744b0bf2cc5d7477ab6fc6acb5d >--- /dev/null >+++ b/Source/WebCore/page/scrolling/nicosia/ScrollingTreeFrameScrollingNodeNicosia.cpp >@@ -0,0 +1,74 @@ >+/* >+ * Copyright (C) 2018 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 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 >+ * HOLDER 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. >+ */ >+ >+#include "config.h" >+#include "ScrollingTreeFrameScrollingNodeNicosia.h" >+ >+#if ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >+ >+namespace WebCore { >+ >+Ref<ScrollingTreeFrameScrollingNode> ScrollingTreeFrameScrollingNodeNicosia::create(ScrollingTree& scrollingTree, ScrollingNodeType nodeType, ScrollingNodeID nodeID) >+{ >+ return adoptRef(*new ScrollingTreeFrameScrollingNodeNicosia(scrollingTree, nodeType, nodeID)); >+} >+ >+ScrollingTreeFrameScrollingNodeNicosia::ScrollingTreeFrameScrollingNodeNicosia(ScrollingTree& scrollingTree, ScrollingNodeType nodeType, ScrollingNodeID nodeID) >+ : ScrollingTreeFrameScrollingNode(scrollingTree, nodeType, nodeID) >+{ >+} >+ >+ScrollingTreeFrameScrollingNodeNicosia::~ScrollingTreeFrameScrollingNodeNicosia() = default; >+ >+void ScrollingTreeFrameScrollingNodeNicosia::handleWheelEvent(const PlatformWheelEvent&) >+{ >+} >+ >+FloatPoint ScrollingTreeFrameScrollingNodeNicosia::scrollPosition() const >+{ >+ return { }; >+} >+ >+void ScrollingTreeFrameScrollingNodeNicosia::setScrollPosition(const FloatPoint&) >+{ >+} >+ >+void ScrollingTreeFrameScrollingNodeNicosia::setScrollPositionWithoutContentEdgeConstraints(const FloatPoint&) >+{ >+} >+ >+void ScrollingTreeFrameScrollingNodeNicosia::setScrollLayerPosition(const FloatPoint&, const FloatRect&) >+{ >+} >+ >+void ScrollingTreeFrameScrollingNodeNicosia::updateLayersAfterViewportChange(const FloatRect&, double) >+{ >+} >+ >+} // namespace WebCore >+ >+#endif // ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >diff --git a/Source/WebCore/page/scrolling/nicosia/ScrollingTreeFrameScrollingNodeNicosia.h b/Source/WebCore/page/scrolling/nicosia/ScrollingTreeFrameScrollingNodeNicosia.h >new file mode 100644 >index 0000000000000000000000000000000000000000..2dc4823626a1f29dcb4c8005deb5a8654ba940fd >--- /dev/null >+++ b/Source/WebCore/page/scrolling/nicosia/ScrollingTreeFrameScrollingNodeNicosia.h >@@ -0,0 +1,56 @@ >+/* >+ * Copyright (C) 2018 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 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 >+ * HOLDER 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. >+ */ >+ >+#pragma once >+ >+#if ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >+ >+#include "ScrollingTreeFrameScrollingNode.h" >+ >+namespace WebCore { >+ >+class ScrollingTreeFrameScrollingNodeNicosia final : public ScrollingTreeFrameScrollingNode { >+public: >+ static Ref<ScrollingTreeFrameScrollingNode> create(ScrollingTree&, ScrollingNodeType, ScrollingNodeID); >+ virtual ~ScrollingTreeFrameScrollingNodeNicosia(); >+ >+private: >+ ScrollingTreeFrameScrollingNodeNicosia(ScrollingTree&, ScrollingNodeType, ScrollingNodeID); >+ >+ void handleWheelEvent(const PlatformWheelEvent&) override; >+ >+ FloatPoint scrollPosition() const override; >+ void setScrollPosition(const FloatPoint&) override; >+ void setScrollPositionWithoutContentEdgeConstraints(const FloatPoint&) override; >+ void setScrollLayerPosition(const FloatPoint&, const FloatRect&) override; >+ >+ void updateLayersAfterViewportChange(const FloatRect&, double) override; >+}; >+ >+} // namespace WebCore >+ >+#endif // ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >diff --git a/Source/WebCore/page/scrolling/nicosia/ScrollingTreeNicosia.cpp b/Source/WebCore/page/scrolling/nicosia/ScrollingTreeNicosia.cpp >new file mode 100644 >index 0000000000000000000000000000000000000000..98a42226af8ca85dc65c99c6e2515f9039298524 >--- /dev/null >+++ b/Source/WebCore/page/scrolling/nicosia/ScrollingTreeNicosia.cpp >@@ -0,0 +1,69 @@ >+/* >+ * Copyright (C) 2018 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 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 >+ * HOLDER 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. >+ */ >+ >+#include "config.h" >+#include "ScrollingTreeNicosia.h" >+ >+#if ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >+ >+#include "ScrollingTreeFixedNode.h" >+#include "ScrollingTreeFrameScrollingNodeNicosia.h" >+#include "ScrollingTreeStickyNode.h" >+ >+namespace WebCore { >+ >+Ref<ScrollingTreeNicosia> ScrollingTreeNicosia::create(AsyncScrollingCoordinator& scrollingCoordinator) >+{ >+ return adoptRef(*new ScrollingTreeNicosia(scrollingCoordinator)); >+} >+ >+ScrollingTreeNicosia::ScrollingTreeNicosia(AsyncScrollingCoordinator& scrollingCoordinator) >+ : ThreadedScrollingTree(scrollingCoordinator) >+{ >+} >+ >+Ref<ScrollingTreeNode> ScrollingTreeNicosia::createScrollingTreeNode(ScrollingNodeType nodeType, ScrollingNodeID nodeID) >+{ >+ switch (nodeType) { >+ case ScrollingNodeType::MainFrame: >+ case ScrollingNodeType::Subframe: >+ return ScrollingTreeFrameScrollingNodeNicosia::create(*this, nodeType, nodeID); >+ case ScrollingNodeType::Overflow: >+ // Should not be reached -- caught by ASSERT_NOT_REACHED() below. >+ break; >+ case ScrollingNodeType::Fixed: >+ return ScrollingTreeFixedNode::create(*this, nodeID); >+ case ScrollingNodeType::Sticky: >+ return ScrollingTreeStickyNode::create(*this, nodeID); >+ } >+ >+ RELEASE_ASSERT_NOT_REACHED(); >+} >+ >+} // namespace WebCore >+ >+#endif // ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >diff --git a/Source/WebCore/page/scrolling/nicosia/ScrollingTreeNicosia.h b/Source/WebCore/page/scrolling/nicosia/ScrollingTreeNicosia.h >new file mode 100644 >index 0000000000000000000000000000000000000000..5b826cc6a78cb80a1293b5d55f0f0eb2ab4c7d38 >--- /dev/null >+++ b/Source/WebCore/page/scrolling/nicosia/ScrollingTreeNicosia.h >@@ -0,0 +1,48 @@ >+/* >+ * Copyright (C) 2018 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 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 >+ * HOLDER 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. >+ */ >+ >+#pragma once >+ >+#if ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >+ >+#include "ThreadedScrollingTree.h" >+ >+namespace WebCore { >+ >+class ScrollingTreeNicosia final : public ThreadedScrollingTree { >+public: >+ static Ref<ScrollingTreeNicosia> create(AsyncScrollingCoordinator&); >+ >+private: >+ explicit ScrollingTreeNicosia(AsyncScrollingCoordinator&); >+ >+ Ref<ScrollingTreeNode> createScrollingTreeNode(ScrollingNodeType, ScrollingNodeID) override; >+}; >+ >+} // namespace WebCore >+ >+#endif // ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >diff --git a/Source/WebCore/page/scrolling/nicosia/ScrollingTreeStickyNode.cpp b/Source/WebCore/page/scrolling/nicosia/ScrollingTreeStickyNode.cpp >new file mode 100644 >index 0000000000000000000000000000000000000000..5636b1fdc9822e8e56a325c024f3aad8f8393a52 >--- /dev/null >+++ b/Source/WebCore/page/scrolling/nicosia/ScrollingTreeStickyNode.cpp >@@ -0,0 +1,63 @@ >+/* >+ * Copyright (C) 2018 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 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 >+ * HOLDER 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. >+ */ >+ >+#include "config.h" >+#include "ScrollingTreeStickyNode.h" >+ >+#if ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >+ >+#include "ScrollingTree.h" >+ >+namespace WebCore { >+ >+Ref<ScrollingTreeStickyNode> ScrollingTreeStickyNode::create(ScrollingTree& scrollingTree, ScrollingNodeID nodeID) >+{ >+ return adoptRef(*new ScrollingTreeStickyNode(scrollingTree, nodeID)); >+} >+ >+ScrollingTreeStickyNode::ScrollingTreeStickyNode(ScrollingTree& scrollingTree, ScrollingNodeID nodeID) >+ : ScrollingTreeNode(scrollingTree, ScrollingNodeType::Sticky, nodeID) >+{ >+ scrollingTree.fixedOrStickyNodeAdded(); >+} >+ >+ScrollingTreeStickyNode::~ScrollingTreeStickyNode() >+{ >+ scrollingTree().fixedOrStickyNodeRemoved(); >+} >+ >+void ScrollingTreeStickyNode::commitStateBeforeChildren(const ScrollingStateNode&) >+{ >+} >+ >+void ScrollingTreeStickyNode::updateLayersAfterAncestorChange(const ScrollingTreeNode&, const FloatRect&, const FloatSize&) >+{ >+} >+ >+} // namespace WebCore >+ >+#endif // ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >diff --git a/Source/WebCore/page/scrolling/nicosia/ScrollingTreeStickyNode.h b/Source/WebCore/page/scrolling/nicosia/ScrollingTreeStickyNode.h >new file mode 100644 >index 0000000000000000000000000000000000000000..bc01d347c8d6f4a03d3aa5eb9efa75904ccc7d20 >--- /dev/null >+++ b/Source/WebCore/page/scrolling/nicosia/ScrollingTreeStickyNode.h >@@ -0,0 +1,50 @@ >+/* >+ * Copyright (C) 2018 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 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 >+ * HOLDER 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. >+ */ >+ >+#pragma once >+ >+#if ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >+ >+#include "ScrollingTreeNode.h" >+ >+namespace WebCore { >+ >+class ScrollingTreeStickyNode final : public ScrollingTreeNode { >+public: >+ static Ref<ScrollingTreeStickyNode> create(ScrollingTree&, ScrollingNodeID); >+ virtual ~ScrollingTreeStickyNode(); >+ >+private: >+ ScrollingTreeStickyNode(ScrollingTree&, ScrollingNodeID); >+ >+ void commitStateBeforeChildren(const ScrollingStateNode&) override; >+ void updateLayersAfterAncestorChange(const ScrollingTreeNode&, const FloatRect&, const FloatSize&) override; >+}; >+ >+} // namespace WebCore >+ >+#endif // ENABLE(ASYNC_SCROLLING) && USE(NICOSIA) >diff --git a/Source/WebCore/platform/TextureMapper.cmake b/Source/WebCore/platform/TextureMapper.cmake >index bfe44f9242acd7a80c80f1135d3e063199e82da7..0ce6d6abcd6bdd2392aaa50b92bea549d8cff873 100644 >--- a/Source/WebCore/platform/TextureMapper.cmake >+++ b/Source/WebCore/platform/TextureMapper.cmake >@@ -26,7 +26,7 @@ endif () > > if (USE_COORDINATED_GRAPHICS) > list(APPEND WebCore_INCLUDE_DIRECTORIES >- "${WEBCORE_DIR}/page/scrolling/coordinatedgraphics" >+ "${WEBCORE_DIR}/page/scrolling/nicosia" > "${WEBCORE_DIR}/platform/graphics/texmap/coordinated" > ) > list(APPEND WebCore_SOURCES
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 193133
: 358311