Changeset 165615 in webkit
- Timestamp:
- Mar 14, 2014 5:49:15 AM (10 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r165612 r165615 1 2014-03-14 Mihnea Ovidenie <mihnea@adobe.com> 2 3 [CSSRegions] Inline-block child of content node incorrectly clipped 4 https://bugs.webkit.org/show_bug.cgi?id=130229 5 6 Reviewed by Andrei Bucur. 7 8 * fast/regions/inlineblock-child-inlineblock-contentnode-in-region-expected.html: Added. 9 * fast/regions/inlineblock-child-inlineblock-contentnode-in-region.html: Added. 10 1 11 2014-03-14 Sergio Villar Senin <svillar@igalia.com> 2 12 -
trunk/Source/WebCore/ChangeLog
r165614 r165615 1 2014-03-14 Mihnea Ovidenie <mihnea@adobe.com> 2 3 [CSSRegions] Inline-block child of content node incorrectly clipped 4 https://bugs.webkit.org/show_bug.cgi?id=130229 5 6 Reviewed by Andrei Bucur. 7 8 Constrain the target box rect to the region box rect only if we are able 9 to determine the region range for box. If we cannot do that, getRegionRangeForBox 10 returns null values for start and end region and we should not perform the clamping. 11 12 Test: fast/regions/inlineblock-child-inlineblock-contentnode-in-region.html 13 14 * rendering/RenderRegion.cpp: 15 (WebCore::RenderRegion::rectFlowPortionForBox): 16 1 17 2014-03-14 Zan Dobersek <zdobersek@igalia.com> 2 18 -
trunk/Source/WebCore/rendering/RenderRegion.cpp
r165130 r165615 472 472 LayoutRect RenderRegion::rectFlowPortionForBox(const RenderBox* box, const LayoutRect& rect) const 473 473 { 474 LayoutRect mappedRect = m_flowThread->mapFromLocalToFlowThread(box, rect); 475 474 476 RenderRegion* startRegion = 0; 475 477 RenderRegion* endRegion = 0; 476 478 m_flowThread->getRegionRangeForBox(box, startRegion, endRegion); 477 479 478 LayoutRect mappedRect = m_flowThread->mapFromLocalToFlowThread(box, rect); 479 if (flowThread()->isHorizontalWritingMode()) { 480 if (this != startRegion) 481 mappedRect.shiftYEdgeTo(std::max<LayoutUnit>(logicalTopForFlowThreadContent(), mappedRect.y())); 482 483 if (this != endRegion) 484 mappedRect.setHeight(std::max<LayoutUnit>(0, std::min<LayoutUnit>(logicalBottomForFlowThreadContent() - mappedRect.y(), mappedRect.height()))); 485 } else { 486 if (this != startRegion) 487 mappedRect.shiftXEdgeTo(std::max<LayoutUnit>(logicalTopForFlowThreadContent(), mappedRect.x())); 488 489 if (this != endRegion) 490 mappedRect.setWidth(std::max<LayoutUnit>(0, std::min<LayoutUnit>(logicalBottomForFlowThreadContent() - mappedRect.x(), mappedRect.width()))); 480 if (startRegion && endRegion) { 481 if (flowThread()->isHorizontalWritingMode()) { 482 if (this != startRegion) 483 mappedRect.shiftYEdgeTo(std::max<LayoutUnit>(logicalTopForFlowThreadContent(), mappedRect.y())); 484 if (this != endRegion) 485 mappedRect.setHeight(std::max<LayoutUnit>(0, std::min<LayoutUnit>(logicalBottomForFlowThreadContent() - mappedRect.y(), mappedRect.height()))); 486 } else { 487 if (this != startRegion) 488 mappedRect.shiftXEdgeTo(std::max<LayoutUnit>(logicalTopForFlowThreadContent(), mappedRect.x())); 489 if (this != endRegion) 490 mappedRect.setWidth(std::max<LayoutUnit>(0, std::min<LayoutUnit>(logicalBottomForFlowThreadContent() - mappedRect.x(), mappedRect.width()))); 491 } 491 492 } 492 493
Note: See TracChangeset
for help on using the changeset viewer.