Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1662)

Unified Diff: Source/core/rendering/svg/RenderSVGModelObject.cpp

Issue 535633002: Common invalidateTreeIfNeeded() (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Remove the ASSERT Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/rendering/svg/RenderSVGModelObject.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/rendering/svg/RenderSVGModelObject.cpp
diff --git a/Source/core/rendering/svg/RenderSVGModelObject.cpp b/Source/core/rendering/svg/RenderSVGModelObject.cpp
index bf4a8307f91d6f608f566e319f8b07fda03d8459..daeb2eedbac4cead26264887a974a5195655608a 100644
--- a/Source/core/rendering/svg/RenderSVGModelObject.cpp
+++ b/Source/core/rendering/svg/RenderSVGModelObject.cpp
@@ -125,37 +125,11 @@ void RenderSVGModelObject::absoluteFocusRingQuads(Vector<FloatQuad>& quads)
quads.append(localToAbsoluteQuad(FloatQuad(paintInvalidationRectInLocalCoordinates())));
}
-void RenderSVGModelObject::invalidateTreeIfNeeded(const PaintInvalidationState& paintInvalidationState)
-{
- // Note: This is a reduced version of RenderBox::invalidateTreeIfNeeded().
- // FIXME: Should share code with RenderBox::invalidateTreeIfNeeded().
- ASSERT(!needsLayout());
-
- if (!shouldCheckForPaintInvalidation(paintInvalidationState))
- return;
-
- invalidatePaintIfNeeded(paintInvalidationState);
-
- RenderObject::invalidateTreeIfNeeded(paintInvalidationState);
-}
-
-void RenderSVGModelObject::invalidatePaintIfNeeded(const PaintInvalidationState& paintInvalidationState)
+InvalidationReason RenderSVGModelObject::invalidatePaintIfNeeded(const PaintInvalidationState& paintInvalidationState, const RenderLayerModelObject& paintInvalidationContainer)
{
ForceHorriblySlowRectMapping slowRectMapping(&paintInvalidationState);
- const LayoutRect oldPaintInvalidationRect = previousPaintInvalidationRect();
- const LayoutPoint oldPositionFromPaintInvalidationContainer = previousPositionFromPaintInvalidationContainer();
- ASSERT(paintInvalidationState.paintInvalidationContainer() == containerForPaintInvalidation());
- setPreviousPaintInvalidationRect(boundsRectForPaintInvalidation(&paintInvalidationState.paintInvalidationContainer(), &paintInvalidationState));
- setPreviousPositionFromPaintInvalidationContainer(RenderLayer::positionFromPaintInvalidationContainer(this, &paintInvalidationState.paintInvalidationContainer(), &paintInvalidationState));
-
- // If we are set to do a full paint invalidation that means the RenderView will be
- // issue paint invalidations. We can then skip issuing of paint invalidations for the child
- // renderers as they'll be covered by the RenderView.
- if (view()->doingFullPaintInvalidation())
- return;
-
- RenderObject::invalidatePaintIfNeeded(paintInvalidationState.paintInvalidationContainer(), oldPaintInvalidationRect, oldPositionFromPaintInvalidationContainer, paintInvalidationState);
+ return RenderObject::invalidatePaintIfNeeded(paintInvalidationState, paintInvalidationContainer);
}
} // namespace blink
« no previous file with comments | « Source/core/rendering/svg/RenderSVGModelObject.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698