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

Unified Diff: Source/core/svg/SVGGraphicsElement.h

Issue 105753003: Generate toSVGGradient|Graphics|PolyElement() (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 7 years 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/SVGGradientElement.h ('k') | Source/core/svg/SVGPolyElement.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/svg/SVGGraphicsElement.h
diff --git a/Source/core/svg/SVGGraphicsElement.h b/Source/core/svg/SVGGraphicsElement.h
index 319033496f5e5543bac763b7dc43580dcad2fac4..6bc8830c32f3359ff0b9c98b0f95621ad43291f3 100644
--- a/Source/core/svg/SVGGraphicsElement.h
+++ b/Source/core/svg/SVGGraphicsElement.h
@@ -76,13 +76,13 @@ private:
OwnPtr<AffineTransform> m_supplementalTransform;
};
-inline SVGGraphicsElement* toSVGGraphicsElement(Node* node)
+inline bool isSVGGraphicsElement(const Node& node)
{
- ASSERT_WITH_SECURITY_IMPLICATION(!node || node->isSVGElement());
- ASSERT_WITH_SECURITY_IMPLICATION(!node || toSVGElement(node)->isSVGGraphicsElement());
- return static_cast<SVGGraphicsElement*>(node);
+ return node.isSVGElement() && toSVGElement(node).isSVGGraphicsElement();
}
+DEFINE_NODE_TYPE_CASTS_WITH_FUNCTION(SVGGraphicsElement);
+
} // namespace WebCore
#endif // SVGGraphicsElement_h
« no previous file with comments | « Source/core/svg/SVGGradientElement.h ('k') | Source/core/svg/SVGPolyElement.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698