Title: [216130] trunk/Source/WebCore
Revision
216130
Author
commit-qu...@webkit.org
Date
2017-05-03 12:02:44 -0700 (Wed, 03 May 2017)

Log Message

Remove ScrollingCoordinator::supportsFixedPositionLayers()
https://bugs.webkit.org/show_bug.cgi?id=171557

Patch by Frederic Wang <fw...@igalia.com> on 2017-05-03
Reviewed by Simon Fraser.

No new tests, behavior is not changed.

* page/FrameView.cpp:
(WebCore::FrameView::shouldUpdateCompositingLayersAfterScrolling):
* page/scrolling/AsyncScrollingCoordinator.cpp:
(WebCore::AsyncScrollingCoordinator::updateViewportConstrainedNode):
* page/scrolling/AsyncScrollingCoordinator.h:
* page/scrolling/ScrollingCoordinator.cpp:
(WebCore::ScrollingCoordinator::synchronousScrollingReasons):
* page/scrolling/ScrollingCoordinator.h:
(WebCore::ScrollingCoordinator::supportsFixedPositionLayers): Deleted.
* page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.cpp:
(WebCore::ScrollingCoordinatorCoordinatedGraphics::updateViewportConstrainedNode):
* page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.h:
(): Deleted.
* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (216129 => 216130)


--- trunk/Source/WebCore/ChangeLog	2017-05-03 18:54:37 UTC (rev 216129)
+++ trunk/Source/WebCore/ChangeLog	2017-05-03 19:02:44 UTC (rev 216130)
@@ -1,3 +1,28 @@
+2017-05-03  Frederic Wang  <fw...@igalia.com>
+
+        Remove ScrollingCoordinator::supportsFixedPositionLayers()
+        https://bugs.webkit.org/show_bug.cgi?id=171557
+
+        Reviewed by Simon Fraser.
+
+        No new tests, behavior is not changed.
+
+        * page/FrameView.cpp:
+        (WebCore::FrameView::shouldUpdateCompositingLayersAfterScrolling):
+        * page/scrolling/AsyncScrollingCoordinator.cpp:
+        (WebCore::AsyncScrollingCoordinator::updateViewportConstrainedNode):
+        * page/scrolling/AsyncScrollingCoordinator.h:
+        * page/scrolling/ScrollingCoordinator.cpp:
+        (WebCore::ScrollingCoordinator::synchronousScrollingReasons):
+        * page/scrolling/ScrollingCoordinator.h:
+        (WebCore::ScrollingCoordinator::supportsFixedPositionLayers): Deleted.
+        * page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.cpp:
+        (WebCore::ScrollingCoordinatorCoordinatedGraphics::updateViewportConstrainedNode):
+        * page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.h:
+        (): Deleted.
+        * rendering/RenderLayerCompositor.cpp:
+        (WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):
+
 2017-05-03  Chris Dumez  <cdu...@apple.com>
 
         Use PassRefPtr less in CompositeEditCommand

Modified: trunk/Source/WebCore/page/FrameView.cpp (216129 => 216130)


--- trunk/Source/WebCore/page/FrameView.cpp	2017-05-03 18:54:37 UTC (rev 216129)
+++ trunk/Source/WebCore/page/FrameView.cpp	2017-05-03 19:02:44 UTC (rev 216130)
@@ -2615,9 +2615,6 @@
     if (!scrollingCoordinator)
         return true;
 
-    if (!scrollingCoordinator->supportsFixedPositionLayers())
-        return true;
-
     if (scrollingCoordinator->shouldUpdateScrollLayerPositionSynchronously(*this))
         return true;
 

Modified: trunk/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.cpp (216129 => 216130)


--- trunk/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.cpp	2017-05-03 18:54:37 UTC (rev 216129)
+++ trunk/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.cpp	2017-05-03 19:02:44 UTC (rev 216130)
@@ -561,8 +561,6 @@
 
 void AsyncScrollingCoordinator::updateViewportConstrainedNode(ScrollingNodeID nodeID, const ViewportConstraints& constraints, GraphicsLayer* graphicsLayer)
 {
-    ASSERT(supportsFixedPositionLayers());
-
     ScrollingStateNode* node = m_scrollingStateTree->stateNodeForID(nodeID);
     if (!node)
         return;

Modified: trunk/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.h (216129 => 216130)


--- trunk/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.h	2017-05-03 18:54:37 UTC (rev 216129)
+++ trunk/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.h	2017-05-03 19:02:44 UTC (rev 216130)
@@ -84,7 +84,6 @@
 private:
     bool isAsyncScrollingCoordinator() const override { return true; }
 
-    bool supportsFixedPositionLayers() const override { return true; }
     bool hasVisibleSlowRepaintViewportConstrainedObjects(const FrameView&) const override { return false; }
     
     bool visualViewportEnabled() const;

Modified: trunk/Source/WebCore/page/scrolling/ScrollingCoordinator.cpp (216129 => 216130)


--- trunk/Source/WebCore/page/scrolling/ScrollingCoordinator.cpp	2017-05-03 18:54:37 UTC (rev 216129)
+++ trunk/Source/WebCore/page/scrolling/ScrollingCoordinator.cpp	2017-05-03 19:02:44 UTC (rev 216130)
@@ -335,9 +335,7 @@
 #endif
     if (frameView.hasSlowRepaintObjects())
         synchronousScrollingReasons |= HasSlowRepaintObjects;
-    if (!supportsFixedPositionLayers() && frameView.hasViewportConstrainedObjects())
-        synchronousScrollingReasons |= HasViewportConstrainedObjectsWithoutSupportingFixedLayers;
-    if (supportsFixedPositionLayers() && hasVisibleSlowRepaintViewportConstrainedObjects(frameView))
+    if (hasVisibleSlowRepaintViewportConstrainedObjects(frameView))
         synchronousScrollingReasons |= HasNonLayerViewportConstrainedObjects;
     if (frameView.frame().mainFrame().document() && frameView.frame().document()->isImageDocument())
         synchronousScrollingReasons |= IsImageDocument;

Modified: trunk/Source/WebCore/page/scrolling/ScrollingCoordinator.h (216129 => 216130)


--- trunk/Source/WebCore/page/scrolling/ScrollingCoordinator.h	2017-05-03 18:54:37 UTC (rev 216129)
+++ trunk/Source/WebCore/page/scrolling/ScrollingCoordinator.h	2017-05-03 19:02:44 UTC (rev 216130)
@@ -144,10 +144,6 @@
     // Should be called whenever the root layer for the given frame view changes.
     virtual void frameViewRootLayerDidChange(FrameView&);
 
-    // Return whether this scrolling coordinator can keep fixed position layers fixed to their
-    // containers while scrolling.
-    virtual bool supportsFixedPositionLayers() const { return false; }
-
 #if PLATFORM(COCOA)
     // Dispatched by the scrolling tree during handleWheelEvent. This is required as long as scrollbars are painted on the main thread.
     void handleWheelEventPhase(PlatformWheelEventPhase);

Modified: trunk/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.cpp (216129 => 216130)


--- trunk/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.cpp	2017-05-03 18:54:37 UTC (rev 216129)
+++ trunk/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.cpp	2017-05-03 19:02:44 UTC (rev 216130)
@@ -74,8 +74,6 @@
 
 void ScrollingCoordinatorCoordinatedGraphics::updateViewportConstrainedNode(ScrollingNodeID nodeID, const ViewportConstraints& constraints, GraphicsLayer* graphicsLayer)
 {
-    ASSERT(supportsFixedPositionLayers());
-
     ScrollingStateNode* node = m_scrollingStateTree->stateNodeForID(nodeID);
     if (!node)
         return;

Modified: trunk/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.h (216129 => 216130)


--- trunk/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.h	2017-05-03 18:54:37 UTC (rev 216129)
+++ trunk/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.h	2017-05-03 19:02:44 UTC (rev 216130)
@@ -38,8 +38,6 @@
     explicit ScrollingCoordinatorCoordinatedGraphics(Page*);
     virtual ~ScrollingCoordinatorCoordinatedGraphics();
 
-    bool supportsFixedPositionLayers() const override { return true; }
-
     ScrollingNodeID attachToStateTree(ScrollingNodeType, ScrollingNodeID newNodeID, ScrollingNodeID parentID) override;
     void detachFromStateTree(ScrollingNodeID) override;
     void clearStateTree() override;

Modified: trunk/Source/WebCore/rendering/RenderLayerCompositor.cpp (216129 => 216130)


--- trunk/Source/WebCore/rendering/RenderLayerCompositor.cpp	2017-05-03 18:54:37 UTC (rev 216129)
+++ trunk/Source/WebCore/rendering/RenderLayerCompositor.cpp	2017-05-03 19:02:44 UTC (rev 216130)
@@ -3865,8 +3865,7 @@
 
     bool isRootLayer = &layer == m_renderView.layer();
 
-    // FIXME: Remove supportsFixedPositionLayers() since all platforms support them now.
-    if (!scrollingCoordinator->supportsFixedPositionLayers() || (!layer.parent() && !isRootLayer))
+    if (!layer.parent() && !isRootLayer)
         return;
 
     ASSERT(m_scrollCoordinatedLayers.contains(&layer));
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to