Title: [218569] releases/WebKitGTK/webkit-2.16
Revision
218569
Author
[email protected]
Date
2017-06-20 01:34:43 -0700 (Tue, 20 Jun 2017)

Log Message

Merge r217848 - Safari doesn't load newest The Order of the Stick comic.
https://bugs.webkit.org/show_bug.cgi?id=172949
<rdar://problem/32389730>

Reviewed by Antti Koivisto.

Source/WebCore:

As part of the table layout, RenderTableSection::layoutRows calls the RenderTableCell's layout() directly
(skipping the RenderTableRow parent). If during this call the RenderTableCell (or any of its descendant) marks the ancestor
chain dirty, this dirty flag on the RenderTableRows will never be cleared and we'll end up early returning from RenderTableSection::paint.
For certain type of float objects, we need to invalidate the line layout path during layout (and we mark the ancestors dirty).
This patch takes a conservative approach and marks the ancestors dirty only when the renderer is not dirty yet, but
as part of webkit.org/b/172947 we should revisit and validate whether the setNeedsLayout() is required at all.

Test: fast/table/floating-table-sibling-is-invisible.html

* rendering/RenderBlockFlow.cpp:
(WebCore::RenderBlockFlow::invalidateLineLayoutPath):

LayoutTests:

* fast/table/floating-table-sibling-is-invisible-expected.html: Added.
* fast/table/floating-table-sibling-is-invisible.html: Added.

Modified Paths

Added Paths

Diff

Modified: releases/WebKitGTK/webkit-2.16/LayoutTests/ChangeLog (218568 => 218569)


--- releases/WebKitGTK/webkit-2.16/LayoutTests/ChangeLog	2017-06-20 08:31:56 UTC (rev 218568)
+++ releases/WebKitGTK/webkit-2.16/LayoutTests/ChangeLog	2017-06-20 08:34:43 UTC (rev 218569)
@@ -1,3 +1,14 @@
+2017-06-06  Zalan Bujtas  <[email protected]>
+
+        Safari doesn't load newest The Order of the Stick comic.
+        https://bugs.webkit.org/show_bug.cgi?id=172949
+        <rdar://problem/32389730>
+
+        Reviewed by Antti Koivisto.
+
+        * fast/table/floating-table-sibling-is-invisible-expected.html: Added.
+        * fast/table/floating-table-sibling-is-invisible.html: Added.
+
 2017-06-05  Chris Dumez  <[email protected]>
 
         ASSERTION FAILED: RunLoop::isMain() in com.apple.WebKit: IPC::Connection::sendSyncMessage + 128

Added: releases/WebKitGTK/webkit-2.16/LayoutTests/fast/table/floating-table-sibling-is-invisible-expected.html (0 => 218569)


--- releases/WebKitGTK/webkit-2.16/LayoutTests/fast/table/floating-table-sibling-is-invisible-expected.html	                        (rev 0)
+++ releases/WebKitGTK/webkit-2.16/LayoutTests/fast/table/floating-table-sibling-is-invisible-expected.html	2017-06-20 08:34:43 UTC (rev 218569)
@@ -0,0 +1,16 @@
+<html>
+<head>
+<title>This tests if we paint sibling content of a floating table</title>
+<style>
+div {
+    position: absolute;
+    left: 2px;
+    top: 2px;
+    width: 196px;
+    height: 196px;
+    background-color: green;
+}
+</style>
+</head>
+<body><div></div></body>
+</html>

Added: releases/WebKitGTK/webkit-2.16/LayoutTests/fast/table/floating-table-sibling-is-invisible.html (0 => 218569)


--- releases/WebKitGTK/webkit-2.16/LayoutTests/fast/table/floating-table-sibling-is-invisible.html	                        (rev 0)
+++ releases/WebKitGTK/webkit-2.16/LayoutTests/fast/table/floating-table-sibling-is-invisible.html	2017-06-20 08:34:43 UTC (rev 218569)
@@ -0,0 +1,27 @@
+<html>
+<head>
+<title>This tests if we paint sibling content of a floating table</title>
+<style>
+.container {
+	position: absolute;
+	left: 0px;
+	top: 0px;
+}
+
+td {
+    color: transparent;
+	font-size: 10px;
+    padding: 0px;
+}
+
+tr {
+    background-color: green;
+}
+
+</style>
+</head>
+<body>
+<!-- PASS if the green box is visible above -->
+<table class=container width="200px" height="200px"><tr><td><table align="left"><tr><td>&nbsp</td></tr></table><p>foobar</p></td></tr></table>
+</body>
+</html>
\ No newline at end of file

Modified: releases/WebKitGTK/webkit-2.16/Source/WebCore/ChangeLog (218568 => 218569)


--- releases/WebKitGTK/webkit-2.16/Source/WebCore/ChangeLog	2017-06-20 08:31:56 UTC (rev 218568)
+++ releases/WebKitGTK/webkit-2.16/Source/WebCore/ChangeLog	2017-06-20 08:34:43 UTC (rev 218569)
@@ -1,3 +1,23 @@
+2017-06-06  Zalan Bujtas  <[email protected]>
+
+        Safari doesn't load newest The Order of the Stick comic.
+        https://bugs.webkit.org/show_bug.cgi?id=172949
+        <rdar://problem/32389730>
+
+        Reviewed by Antti Koivisto.
+
+        As part of the table layout, RenderTableSection::layoutRows calls the RenderTableCell's layout() directly
+        (skipping the RenderTableRow parent). If during this call the RenderTableCell (or any of its descendant) marks the ancestor
+        chain dirty, this dirty flag on the RenderTableRows will never be cleared and we'll end up early returning from RenderTableSection::paint.
+        For certain type of float objects, we need to invalidate the line layout path during layout (and we mark the ancestors dirty).
+        This patch takes a conservative approach and marks the ancestors dirty only when the renderer is not dirty yet, but
+        as part of webkit.org/b/172947 we should revisit and validate whether the setNeedsLayout() is required at all.
+
+        Test: fast/table/floating-table-sibling-is-invisible.html
+
+        * rendering/RenderBlockFlow.cpp:
+        (WebCore::RenderBlockFlow::invalidateLineLayoutPath):
+
 2017-06-05  Zalan Bujtas  <[email protected]>
 
         Destroy the associated renderer subtree when display: contents node is deleted.

Modified: releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/RenderBlockFlow.cpp (218568 => 218569)


--- releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/RenderBlockFlow.cpp	2017-06-20 08:31:56 UTC (rev 218568)
+++ releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/RenderBlockFlow.cpp	2017-06-20 08:34:43 UTC (rev 218569)
@@ -3666,8 +3666,11 @@
     case SimpleLinesPath:
         // The simple line layout may have become invalid.
         m_simpleLineLayout = nullptr;
+        setLineLayoutPath(UndeterminedPath);
+        if (needsLayout())
+            return;
+        // FIXME: We should just kick off a subtree layout here (if needed at all) see webkit.org/b/172947.
         setNeedsLayout();
-        setLineLayoutPath(UndeterminedPath);
         return;
     }
     ASSERT_NOT_REACHED();
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to