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

Unified Diff: Source/core/svg/SVGElement.cpp

Issue 1111223002: Invalidate ancestor resources in when relative lengths change (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Add test. Created 5 years, 7 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 | « LayoutTests/svg/custom/viewport-clippath-invalidation-expected.html ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/svg/SVGElement.cpp
diff --git a/Source/core/svg/SVGElement.cpp b/Source/core/svg/SVGElement.cpp
index c3e1e220fba2765be4ffafe1048dde5d442b76da..a44ca471303d9e65d50c58719178d010fffaed64 100644
--- a/Source/core/svg/SVGElement.cpp
+++ b/Source/core/svg/SVGElement.cpp
@@ -418,11 +418,10 @@ void SVGElement::invalidateRelativeLengthClients(SubtreeLayoutScope* layoutScope
TemporaryChange<bool> inRelativeLengthClientsInvalidationChange(m_inRelativeLengthClientsInvalidation, true);
#endif
- LayoutObject* layoutObject = this->layoutObject();
- if (layoutObject && selfHasRelativeLengths()) {
- if (layoutObject->isSVGResourceContainer())
+ if (LayoutObject* layoutObject = this->layoutObject()) {
+ if (hasRelativeLengths() && layoutObject->isSVGResourceContainer())
toLayoutSVGResourceContainer(layoutObject)->invalidateCacheAndMarkForLayout(layoutScope);
- else
+ else if (selfHasRelativeLengths())
layoutObject->setNeedsLayoutAndFullPaintInvalidation(LayoutInvalidationReason::Unknown, MarkContainerChain, layoutScope);
}
« no previous file with comments | « LayoutTests/svg/custom/viewport-clippath-invalidation-expected.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698