Chromium Code Reviews| Index: third_party/WebKit/Source/core/style/SVGComputedStyle.cpp |
| diff --git a/third_party/WebKit/Source/core/style/SVGComputedStyle.cpp b/third_party/WebKit/Source/core/style/SVGComputedStyle.cpp |
| index 35be21707f76ed749c2ba59a24e98fc38fc29988..1034cbcb90a6331a44cd31bdc9c9fbbc4787c701 100644 |
| --- a/third_party/WebKit/Source/core/style/SVGComputedStyle.cpp |
| +++ b/third_party/WebKit/Source/core/style/SVGComputedStyle.cpp |
| @@ -80,23 +80,25 @@ SVGComputedStyle::~SVGComputedStyle() |
| bool SVGComputedStyle::operator==(const SVGComputedStyle& other) const |
| { |
| + return inheritedEqual(other) |
|
sashab
2016/07/01 06:59:51
This is identical to the comparisons before, I jus
|
| + && nonInheritedEqual(other); |
| +} |
| + |
| +bool SVGComputedStyle::inheritedEqual(const SVGComputedStyle& other) const |
| +{ |
| return fill == other.fill |
| && stroke == other.stroke |
| - && stops == other.stops |
| - && misc == other.misc |
| && inheritedResources == other.inheritedResources |
| - && geometry == other.geometry |
| - && resources == other.resources |
| - && svg_inherited_flags == other.svg_inherited_flags |
| - && svg_noninherited_flags == other.svg_noninherited_flags; |
| + && svg_inherited_flags == other.svg_inherited_flags; |
| } |
| -bool SVGComputedStyle::inheritedNotEqual(const SVGComputedStyle* other) const |
| +bool SVGComputedStyle::nonInheritedEqual(const SVGComputedStyle& other) const |
| { |
| - return fill != other->fill |
| - || stroke != other->stroke |
| - || inheritedResources != other->inheritedResources |
| - || svg_inherited_flags != other->svg_inherited_flags; |
| + return stops == other.stops |
| + && misc == other.misc |
| + && geometry == other.geometry |
| + && resources == other.resources |
| + && svg_noninherited_flags == other.svg_noninherited_flags; |
| } |
| void SVGComputedStyle::inheritFrom(const SVGComputedStyle* svgInheritParent) |