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

Unified Diff: Source/core/rendering/style/SVGRenderStyle.cpp

Issue 898873002: CL for perf tryjob (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 11 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/style/SVGRenderStyle.h ('k') | Source/core/rendering/style/SVGRenderStyleDefs.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/rendering/style/SVGRenderStyle.cpp
diff --git a/Source/core/rendering/style/SVGRenderStyle.cpp b/Source/core/rendering/style/SVGRenderStyle.cpp
index 5192620bc3baabd98a2ce7924f87b236447ccaeb..4aa4cfca4bf7fa0765fc406c84c32136e4456f2f 100644
--- a/Source/core/rendering/style/SVGRenderStyle.cpp
+++ b/Source/core/rendering/style/SVGRenderStyle.cpp
@@ -40,6 +40,7 @@ SVGRenderStyle::SVGRenderStyle()
stops = defaultStyle->stops;
misc = defaultStyle->misc;
inheritedResources = defaultStyle->inheritedResources;
+ layout = defaultStyle->layout;
resources = defaultStyle->resources;
setBitDefaults();
@@ -54,6 +55,7 @@ SVGRenderStyle::SVGRenderStyle(CreateDefaultType)
stops.init();
misc.init();
inheritedResources.init();
+ layout.init();
resources.init();
}
@@ -65,6 +67,7 @@ SVGRenderStyle::SVGRenderStyle(const SVGRenderStyle& other)
stops = other.stops;
misc = other.misc;
inheritedResources = other.inheritedResources;
+ layout = other.layout;
resources = other.resources;
svg_inherited_flags = other.svg_inherited_flags;
@@ -82,6 +85,7 @@ bool SVGRenderStyle::operator==(const SVGRenderStyle& other) const
&& stops == other.stops
&& misc == other.misc
&& inheritedResources == other.inheritedResources
+ && layout == other.layout
&& resources == other.resources
&& svg_inherited_flags == other.svg_inherited_flags
&& svg_noninherited_flags == other.svg_noninherited_flags;
@@ -112,6 +116,7 @@ void SVGRenderStyle::copyNonInheritedFrom(const SVGRenderStyle* other)
svg_noninherited_flags = other->svg_noninherited_flags;
stops = other->stops;
misc = other->misc;
+ layout = other->layout;
resources = other->resources;
}
@@ -177,6 +182,13 @@ bool SVGRenderStyle::diffNeedsLayoutAndPaintInvalidation(const SVGRenderStyle* o
return true;
}
+ // The x and y properties require a re-layout.
+ if (layout.get() != other->layout.get()) {
+ if (layout->x != other->layout->x
+ || layout->y != other->layout->y)
+ return true;
+ }
+
return false;
}
« no previous file with comments | « Source/core/rendering/style/SVGRenderStyle.h ('k') | Source/core/rendering/style/SVGRenderStyleDefs.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698