Title: [122343] trunk/Source/WebCore
- Revision
- 122343
- Author
- [email protected]
- Date
- 2012-07-11 11:00:29 -0700 (Wed, 11 Jul 2012)
Log Message
RenderView layer is marked as fixed position container in the scrolling tree if page scale != 1
https://bugs.webkit.org/show_bug.cgi?id=89216
Patch by Sami Kyostila <[email protected]> on 2012-07-11
Reviewed by Simon Fraser.
Render layers with CSS transforms should become containers for any fixed
positioned descendants. However, because this check is done with
RenderLayer::hasTransform(), we also end up marking the RenderLayer for the
RenderView as fixed position container if a non-identity page scale factor is
used. This is because page scale is applied as a transform for that layer.
This breaks fixed position layers, because they become fixed relative to the
RenderView layer instead of outer scroll clip layer.
The fix is to avoid marking any root layers as fixed position containers.
No new test because the scrolling tree isn't currently testable.
* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (122342 => 122343)
--- trunk/Source/WebCore/ChangeLog 2012-07-11 17:50:47 UTC (rev 122342)
+++ trunk/Source/WebCore/ChangeLog 2012-07-11 18:00:29 UTC (rev 122343)
@@ -1,3 +1,26 @@
+2012-07-11 Sami Kyostila <[email protected]>
+
+ RenderView layer is marked as fixed position container in the scrolling tree if page scale != 1
+ https://bugs.webkit.org/show_bug.cgi?id=89216
+
+ Reviewed by Simon Fraser.
+
+ Render layers with CSS transforms should become containers for any fixed
+ positioned descendants. However, because this check is done with
+ RenderLayer::hasTransform(), we also end up marking the RenderLayer for the
+ RenderView as fixed position container if a non-identity page scale factor is
+ used. This is because page scale is applied as a transform for that layer.
+
+ This breaks fixed position layers, because they become fixed relative to the
+ RenderView layer instead of outer scroll clip layer.
+
+ The fix is to avoid marking any root layers as fixed position containers.
+
+ No new test because the scrolling tree isn't currently testable.
+
+ * rendering/RenderLayerBacking.cpp:
+ (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
+
2012-07-11 Julien Chaffraix <[email protected]>
REGRESSION (r116203): overflow sections don't have scrollbars
Modified: trunk/Source/WebCore/rendering/RenderLayerBacking.cpp (122342 => 122343)
--- trunk/Source/WebCore/rendering/RenderLayerBacking.cpp 2012-07-11 17:50:47 UTC (rev 122342)
+++ trunk/Source/WebCore/rendering/RenderLayerBacking.cpp 2012-07-11 18:00:29 UTC (rev 122343)
@@ -471,7 +471,10 @@
scrollingCoordinator->setLayerIsFixedToContainerLayer(m_ancestorClippingLayer.get(), false);
scrollingCoordinator->setLayerIsFixedToContainerLayer(m_graphicsLayer.get(), false);
}
- bool isContainer = m_owningLayer->hasTransform();
+ // Page scale is applied as a transform on the root render view layer. Because the scroll
+ // layer is further up in the hierarchy, we need to avoid marking the root render view
+ // layer as a container.
+ bool isContainer = m_owningLayer->hasTransform() && !m_owningLayer->isRootLayer();
scrollingCoordinator->setLayerIsContainerForFixedPositionLayers(childForSuperlayers(), isContainer);
}
}
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo/webkit-changes