Title: [118617] trunk
- Revision
- 118617
- Author
- [email protected]
- Date
- 2012-05-26 17:43:12 -0700 (Sat, 26 May 2012)
Log Message
fast/block/inline-children-root-linebox-crash.html asserts after r118567
https://bugs.webkit.org/show_bug.cgi?id=87544
Source/WebCore:
Reviewed by Darin Adler.
RenderInline::offsetFromContainer() set offsetDependsOnPoint to true based
on the container's flipped writing mode. However, offsetFromContainer() would
then overwrite that, since it only checked for columns.
Fix by having RenderInline::offsetFromContainer() check for flipping on
the container. This fixes the assertion.
The new testcase exercises fixes another issue; unlike mapLocalToAbsolute(),
RenderGeometryMap::absoluteRect() didn't pass the rect center point through
the mapping, which resulted in a different result in some flipping cases.
Test: compositing/geometry/flipped-blocks-inline-mapping.html
* rendering/RenderGeometryMap.cpp:
(WebCore::RenderGeometryMap::absoluteRect):
* rendering/RenderInline.cpp:
(WebCore::RenderInline::offsetFromContainer):
(WebCore::RenderInline::pushMappingToContainer):
LayoutTests:
Reviewed by Darin Adler.
Remove fast/block/inline-children-root-linebox-crash.html from the skipped
list.
New, more complex writing mode flipping test with compositing.
* compositing/geometry/flipped-blocks-inline-mapping-expected.txt: Added.
* compositing/geometry/flipped-blocks-inline-mapping.html: Added.
* platform/mac/Skipped:
Modified Paths
Added Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (118616 => 118617)
--- trunk/LayoutTests/ChangeLog 2012-05-26 22:40:46 UTC (rev 118616)
+++ trunk/LayoutTests/ChangeLog 2012-05-27 00:43:12 UTC (rev 118617)
@@ -1,3 +1,19 @@
+2012-05-26 Simon Fraser <[email protected]>
+
+ fast/block/inline-children-root-linebox-crash.html asserts after r118567
+ https://bugs.webkit.org/show_bug.cgi?id=87544
+
+ Reviewed by Darin Adler.
+
+ Remove fast/block/inline-children-root-linebox-crash.html from the skipped
+ list.
+
+ New, more complex writing mode flipping test with compositing.
+
+ * compositing/geometry/flipped-blocks-inline-mapping-expected.txt: Added.
+ * compositing/geometry/flipped-blocks-inline-mapping.html: Added.
+ * platform/mac/Skipped:
+
2012-05-26 David Barton <[email protected]>
My first commit - set svn:mime-type to image/png on one .png file.
Added: trunk/LayoutTests/compositing/geometry/flipped-blocks-inline-mapping-expected.txt (0 => 118617)
--- trunk/LayoutTests/compositing/geometry/flipped-blocks-inline-mapping-expected.txt (rev 0)
+++ trunk/LayoutTests/compositing/geometry/flipped-blocks-inline-mapping-expected.txt 2012-05-27 00:43:12 UTC (rev 118617)
@@ -0,0 +1 @@
+This test should not assert in debug builds
Added: trunk/LayoutTests/compositing/geometry/flipped-blocks-inline-mapping.html (0 => 118617)
--- trunk/LayoutTests/compositing/geometry/flipped-blocks-inline-mapping.html (rev 0)
+++ trunk/LayoutTests/compositing/geometry/flipped-blocks-inline-mapping.html 2012-05-27 00:43:12 UTC (rev 118617)
@@ -0,0 +1,33 @@
+<style>
+ .container {
+ -webkit-writing-mode: horizontal-bt;
+ height: 100px;
+ border: 1px solid black;
+ }
+ div {
+ height: 20px;
+ }
+ .box {
+ width: 20px;
+ height: 20px;
+ background-color: blue;
+ }
+
+ .transformed {
+ -webkit-transform: translateZ(0);
+ }
+ span {
+ opacity: 0.8;
+ }
+
+</style>
+<div class="container">
+ <span>
+ <div class="transformed box"></div>
+ <div style="display: inline-block">This test should not assert in debug builds</div>
+ </span>
+</div>
+<script>
+if (window.layoutTestController)
+ layoutTestController.dumpAsText();
+</script>
Modified: trunk/LayoutTests/platform/mac/Skipped (118616 => 118617)
--- trunk/LayoutTests/platform/mac/Skipped 2012-05-26 22:40:46 UTC (rev 118616)
+++ trunk/LayoutTests/platform/mac/Skipped 2012-05-27 00:43:12 UTC (rev 118617)
@@ -867,7 +867,3 @@
fast/canvas/webgl/tex-image-and-sub-image-2d-with-video-rgb565.html
fast/canvas/webgl/tex-image-and-sub-image-2d-with-video-rgba4444.html
fast/canvas/webgl/tex-image-and-sub-image-2d-with-video-rgba5551.html
-
-# https://bugs.webkit.org/show_bug.cgi?id=87544
-fast/block/inline-children-root-linebox-crash.html
-
Modified: trunk/Source/WebCore/ChangeLog (118616 => 118617)
--- trunk/Source/WebCore/ChangeLog 2012-05-26 22:40:46 UTC (rev 118616)
+++ trunk/Source/WebCore/ChangeLog 2012-05-27 00:43:12 UTC (rev 118617)
@@ -1,3 +1,29 @@
+2012-05-26 Simon Fraser <[email protected]>
+
+ fast/block/inline-children-root-linebox-crash.html asserts after r118567
+ https://bugs.webkit.org/show_bug.cgi?id=87544
+
+ Reviewed by Darin Adler.
+
+ RenderInline::offsetFromContainer() set offsetDependsOnPoint to true based
+ on the container's flipped writing mode. However, offsetFromContainer() would
+ then overwrite that, since it only checked for columns.
+
+ Fix by having RenderInline::offsetFromContainer() check for flipping on
+ the container. This fixes the assertion.
+
+ The new testcase exercises fixes another issue; unlike mapLocalToAbsolute(),
+ RenderGeometryMap::absoluteRect() didn't pass the rect center point through
+ the mapping, which resulted in a different result in some flipping cases.
+
+ Test: compositing/geometry/flipped-blocks-inline-mapping.html
+
+ * rendering/RenderGeometryMap.cpp:
+ (WebCore::RenderGeometryMap::absoluteRect):
+ * rendering/RenderInline.cpp:
+ (WebCore::RenderInline::offsetFromContainer):
+ (WebCore::RenderInline::pushMappingToContainer):
+
2012-05-26 Geoffrey Garen <[email protected]>
WebKit should be lazy-finalization-safe (esp. the DOM) v2
Modified: trunk/Source/WebCore/rendering/RenderGeometryMap.cpp (118616 => 118617)
--- trunk/Source/WebCore/rendering/RenderGeometryMap.cpp 2012-05-26 22:40:46 UTC (rev 118616)
+++ trunk/Source/WebCore/rendering/RenderGeometryMap.cpp 2012-05-27 00:43:12 UTC (rev 118617)
@@ -114,7 +114,7 @@
result = rect;
result.move(m_accumulatedOffset);
} else {
- TransformState transformState(TransformState::ApplyTransformDirection, rect);
+ TransformState transformState(TransformState::ApplyTransformDirection, rect.center(), rect);
mapToAbsolute(transformState);
result = transformState.lastPlanarQuad().boundingBox();
}
Modified: trunk/Source/WebCore/rendering/RenderInline.cpp (118616 => 118617)
--- trunk/Source/WebCore/rendering/RenderInline.cpp 2012-05-26 22:40:46 UTC (rev 118616)
+++ trunk/Source/WebCore/rendering/RenderInline.cpp 2012-05-27 00:43:12 UTC (rev 118617)
@@ -1080,7 +1080,7 @@
offset -= toRenderBox(container)->scrolledContentOffset();
if (offsetDependsOnPoint)
- *offsetDependsOnPoint = container->hasColumns();
+ *offsetDependsOnPoint = container->hasColumns() || (container->isBox() && container->style()->isFlippedBlocksWritingMode());
return offset;
}
@@ -1142,11 +1142,6 @@
if (!container)
return 0;
- bool offsetDependsOnPoint = false;
-
- if (container->isBox() && container->style()->isFlippedBlocksWritingMode())
- offsetDependsOnPoint = true;
-
LayoutSize adjustmentForSkippedAncestor;
if (ancestorSkipped) {
// There can't be a transform between repaintContainer and o, because transforms create containers, so it should be safe
@@ -1154,6 +1149,7 @@
adjustmentForSkippedAncestor = -ancestorToStopAt->offsetFromAncestorContainer(container);
}
+ bool offsetDependsOnPoint = false;
LayoutSize containerOffset = offsetFromContainer(container, LayoutPoint(), &offsetDependsOnPoint);
bool preserve3D = container->style()->preserves3D() || style()->preserves3D();
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes