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

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

Issue 190793011: Use isSVG*Element() helpers more in SVG code (Part 4) (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 9 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/svg/SVGTextPathElement.cpp ('k') | Source/core/svg/SVGUseElement.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/svg/SVGTextPositioningElement.cpp
diff --git a/Source/core/svg/SVGTextPositioningElement.cpp b/Source/core/svg/SVGTextPositioningElement.cpp
index ee6484632d50eb19a039fee7d39150ee2d4385f6..b73b7e1db4a1ca874615cd86abe01def638db535 100644
--- a/Source/core/svg/SVGTextPositioningElement.cpp
+++ b/Source/core/svg/SVGTextPositioningElement.cpp
@@ -129,14 +129,7 @@ SVGTextPositioningElement* SVGTextPositioningElement::elementFromRenderer(Render
ASSERT(node);
ASSERT(node->isSVGElement());
- if (!node->hasTagName(SVGNames::textTag)
-#if ENABLE(SVG_FONTS)
- && !node->hasTagName(SVGNames::altGlyphTag)
-#endif
- && !node->hasTagName(SVGNames::tspanTag))
- return 0;
-
- return toSVGTextPositioningElement(node);
+ return isSVGTextPositioningElement(*node) ? toSVGTextPositioningElement(node) : 0;
}
}
« no previous file with comments | « Source/core/svg/SVGTextPathElement.cpp ('k') | Source/core/svg/SVGUseElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698