Chromium Code Reviews| Index: third_party/WebKit/Source/core/layout/PaintInvalidationState.cpp |
| diff --git a/third_party/WebKit/Source/core/layout/PaintInvalidationState.cpp b/third_party/WebKit/Source/core/layout/PaintInvalidationState.cpp |
| index 4ba7f63c8f90aac44e0554d93c6ec335be1f8e18..984fc3dc30d68897abfc3cbf453fa74bf2941a45 100644 |
| --- a/third_party/WebKit/Source/core/layout/PaintInvalidationState.cpp |
| +++ b/third_party/WebKit/Source/core/layout/PaintInvalidationState.cpp |
| @@ -373,10 +373,7 @@ LayoutRect PaintInvalidationState::computePaintInvalidationRectInBackingForSVG() |
| if (m_clipped) |
| rect.intersect(m_clipRect); |
| #if ASSERT_SAME_RESULT_SLOW_AND_FAST_PATH |
| - // TODO(crbug.com/597902): Slow path misses clipping of paintInvalidationContainer. |
| LayoutRect slowPathRect = SVGLayoutSupport::clippedOverflowRectForPaintInvalidation(m_currentObject, *m_paintInvalidationContainer); |
| - if (m_clipped) |
| - slowPathRect.intersect(m_clipRect); |
| assertRectsEqual(m_currentObject, m_paintInvalidationContainer, rect, slowPathRect); |
| #endif |
| } else { |
| @@ -397,6 +394,10 @@ static void slowMapToVisualRectInAncestorSpace(const LayoutObject& object, const |
| } else { |
| object.mapToVisualRectInAncestorSpace(&ancestor, rect); |
| } |
| + |
| + // LayoutObject::mapToVisualRectInAncestorSpace() doesn't apply overflow clip of ancestor. |
|
chrishtr
2016/04/06 23:18:19
Do any other call sites of mapToVisualRectInAncest
Xianzhu
2016/04/06 23:37:33
Didn't think of this. Just looked at several calls
|
| + if (ancestor.isBox() && !ancestor.isLayoutView() && !toLayoutBox(ancestor).scrollsOverflow()) |
| + rect.intersect(toLayoutBox(ancestor).overflowClipRect(LayoutPoint())); |
| } |
| void PaintInvalidationState::mapLocalRectToPaintInvalidationBacking(LayoutRect& rect) const |
| @@ -412,9 +413,6 @@ void PaintInvalidationState::mapLocalRectToPaintInvalidationBacking(LayoutRect& |
| if (m_clipped) |
| rect.intersect(m_clipRect); |
| #if ASSERT_SAME_RESULT_SLOW_AND_FAST_PATH |
| - // TODO(crbug.com/597902): Slow path misses clipping of paintInvalidationContainer. |
| - if (m_clipped) |
| - slowPathRect.intersect(m_clipRect); |
| assertRectsEqual(m_currentObject, *m_paintInvalidationContainer, rect, slowPathRect); |
| #endif |
| } else { |