Index: Source/core/rendering/svg/RenderSVGResourceFilterPrimitive.cpp |
diff --git a/Source/core/rendering/svg/RenderSVGResourceFilterPrimitive.cpp b/Source/core/rendering/svg/RenderSVGResourceFilterPrimitive.cpp |
index e34449d35eaaedcb4080832d671d31327d580323..f7073cad183dd354a8077c338373e2c6d7f99e10 100644 |
--- a/Source/core/rendering/svg/RenderSVGResourceFilterPrimitive.cpp |
+++ b/Source/core/rendering/svg/RenderSVGResourceFilterPrimitive.cpp |
@@ -44,12 +44,13 @@ void RenderSVGResourceFilterPrimitive::styleDidChange(StyleDifference diff, cons |
return; |
const SVGRenderStyle* newStyle = this->style()->svgStyle(); |
- if (element()->hasTagName(SVGNames::feFloodTag)) { |
+ ASSERT(element()); |
+ if (isSVGFEFloodElement(*element())) { |
if (newStyle->floodColor() != oldStyle->svgStyle()->floodColor()) |
toRenderSVGResourceFilter(filter)->primitiveAttributeChanged(this, SVGNames::flood_colorAttr); |
if (newStyle->floodOpacity() != oldStyle->svgStyle()->floodOpacity()) |
toRenderSVGResourceFilter(filter)->primitiveAttributeChanged(this, SVGNames::flood_opacityAttr); |
- } else if (element()->hasTagName(SVGNames::feDiffuseLightingTag) || element()->hasTagName(SVGNames::feSpecularLightingTag)) { |
+ } else if (isSVGFEDiffuseLightingElement(*element()) || isSVGFESpecularLightingElement(*element())) { |
if (newStyle->lightingColor() != oldStyle->svgStyle()->lightingColor()) |
toRenderSVGResourceFilter(filter)->primitiveAttributeChanged(this, SVGNames::lighting_colorAttr); |
} |