Title: [284247] trunk
- Revision
- 284247
- Author
- [email protected]
- Date
- 2021-10-15 08:25:57 -0700 (Fri, 15 Oct 2021)
Log Message
REGRESSION (r276370): Elements with animated transform property might not properly rendered
https://bugs.webkit.org/show_bug.cgi?id=230753
Reviewed by Myles C. Maxfield.
Source/WebCore:
The change in r276370 was incorrect, resulting in the geometry map being used when
an element had a transform and `transform-style: preserves-3d`.
Fix by going back to testing for the presence of the various transform properties which
affect geometry. hasTransformRelatedProperty() is still useful as a fast bit-check.
Test: fast/repaint/transform-preserve-3d-repaint.html
* rendering/RenderGeometryMap.cpp:
(WebCore::canMapBetweenRenderersViaLayers):
LayoutTests:
* fast/repaint/transform-preserve-3d-repaint-expected.txt: Added.
* fast/repaint/transform-preserve-3d-repaint.html: Added.
Modified Paths
Added Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (284246 => 284247)
--- trunk/LayoutTests/ChangeLog 2021-10-15 15:13:22 UTC (rev 284246)
+++ trunk/LayoutTests/ChangeLog 2021-10-15 15:25:57 UTC (rev 284247)
@@ -1,3 +1,13 @@
+2021-10-15 Simon Fraser <[email protected]>
+
+ REGRESSION (r276370): Elements with animated transform property might not properly rendered
+ https://bugs.webkit.org/show_bug.cgi?id=230753
+
+ Reviewed by Myles C. Maxfield.
+
+ * fast/repaint/transform-preserve-3d-repaint-expected.txt: Added.
+ * fast/repaint/transform-preserve-3d-repaint.html: Added.
+
2021-10-15 Tyler Wilcock <[email protected]>
AX: role="math" elements are no longer considered to have presentational children
Added: trunk/LayoutTests/fast/repaint/transform-preserve-3d-repaint-expected.txt (0 => 284247)
--- trunk/LayoutTests/fast/repaint/transform-preserve-3d-repaint-expected.txt (rev 0)
+++ trunk/LayoutTests/fast/repaint/transform-preserve-3d-repaint-expected.txt 2021-10-15 15:25:57 UTC (rev 284247)
@@ -0,0 +1,6 @@
+(repaint rects
+ (rect 38 20 220 150)
+ (rect 38 20 220 150)
+ (rect 28 20 220 150)
+)
+
Added: trunk/LayoutTests/fast/repaint/transform-preserve-3d-repaint.html (0 => 284247)
--- trunk/LayoutTests/fast/repaint/transform-preserve-3d-repaint.html (rev 0)
+++ trunk/LayoutTests/fast/repaint/transform-preserve-3d-repaint.html 2021-10-15 15:25:57 UTC (rev 284247)
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<html>
+<head>
+ <style>
+ .container {
+ position: relative;
+ transform-style: preserve-3d;
+ z-index: 0;
+ width: 300px;
+ margin: 20px;
+ height: 0px;
+
+ }
+ .box {
+ position: relative;
+ width: 220px;
+ height: 150px;
+ margin: 10px;
+ background-color: silver;
+ }
+
+ #console {
+ margin-top: 100px;
+ }
+ </style>
+ <script src=""
+ <script>
+ function repaintTest()
+ {
+ const container = document.querySelector('.container');
+ container.style.transform = 'translate(-10px, 0)';
+ }
+ </script>
+</head>
+<body _onload_="runRepaintTest()">
+ <div class="container">
+ <div class="box"></div>
+ </div>
+</body>
+</html>
Modified: trunk/Source/WebCore/ChangeLog (284246 => 284247)
--- trunk/Source/WebCore/ChangeLog 2021-10-15 15:13:22 UTC (rev 284246)
+++ trunk/Source/WebCore/ChangeLog 2021-10-15 15:25:57 UTC (rev 284247)
@@ -1,3 +1,21 @@
+2021-10-15 Simon Fraser <[email protected]>
+
+ REGRESSION (r276370): Elements with animated transform property might not properly rendered
+ https://bugs.webkit.org/show_bug.cgi?id=230753
+
+ Reviewed by Myles C. Maxfield.
+
+ The change in r276370 was incorrect, resulting in the geometry map being used when
+ an element had a transform and `transform-style: preserves-3d`.
+
+ Fix by going back to testing for the presence of the various transform properties which
+ affect geometry. hasTransformRelatedProperty() is still useful as a fast bit-check.
+
+ Test: fast/repaint/transform-preserve-3d-repaint.html
+
+ * rendering/RenderGeometryMap.cpp:
+ (WebCore::canMapBetweenRenderersViaLayers):
+
2021-10-15 Tyler Wilcock <[email protected]>
AX: role="math" elements are no longer considered to have presentational children
Modified: trunk/Source/WebCore/rendering/RenderGeometryMap.cpp (284246 => 284247)
--- trunk/Source/WebCore/rendering/RenderGeometryMap.cpp 2021-10-15 15:13:22 UTC (rev 284246)
+++ trunk/Source/WebCore/rendering/RenderGeometryMap.cpp 2021-10-15 15:25:57 UTC (rev 284247)
@@ -150,7 +150,7 @@
if (current->isFixedPositioned() || style.isFlippedBlocksWritingMode())
return false;
- if (current->hasTransformRelatedProperty() && !current->style().preserves3D())
+ if (current->hasTransformRelatedProperty() && (style.hasTransform() || style.translate() || style.scale() || style.rotate() || style.hasPerspective()))
return false;
if (current->isRenderFragmentedFlow())
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes