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

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

Issue 22897011: Introduce toSVGRadialGradientElement(), and use it (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 7 years, 4 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
Index: Source/core/rendering/svg/SVGRenderTreeAsText.cpp
diff --git a/Source/core/rendering/svg/SVGRenderTreeAsText.cpp b/Source/core/rendering/svg/SVGRenderTreeAsText.cpp
index 5838081a05813bfc4fec1e998c24edcc91d7a07a..f117b1df157b81408478e4d708844a8373e3cbd2 100644
--- a/Source/core/rendering/svg/SVGRenderTreeAsText.cpp
+++ b/Source/core/rendering/svg/SVGRenderTreeAsText.cpp
@@ -551,10 +551,8 @@ void writeSVGResourceContainer(TextStream& ts, const RenderObject& object, int i
// Dump final results that are used for rendering. No use in asking SVGGradientElement for its gradientUnits(), as it may
// link to other gradients using xlink:href, we need to build the full inheritance chain, aka. collectGradientProperties()
- SVGRadialGradientElement* radialGradientElement = static_cast<SVGRadialGradientElement*>(gradient->node());
-
RadialGradientAttributes attributes;
- radialGradientElement->collectGradientAttributes(attributes);
+ toSVGRadialGradientElement(gradient->node())->collectGradientAttributes(attributes);
writeCommonGradientProperties(ts, attributes.spreadMethod(), attributes.gradientTransform(), attributes.gradientUnits());
FloatPoint focalPoint = gradient->focalPoint(attributes);
« no previous file with comments | « Source/core/rendering/svg/RenderSVGResourceRadialGradient.cpp ('k') | Source/core/svg/SVGRadialGradientElement.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698