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

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

Issue 23377003: Add toSVGMissingGlyphElement(), 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
« no previous file with comments | « Source/core/svg/SVGFontElement.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/svg/SVGMissingGlyphElement.h
diff --git a/Source/core/svg/SVGMissingGlyphElement.h b/Source/core/svg/SVGMissingGlyphElement.h
index 9dfaf3ffd5db62eb6d76d67538ff1bfa16aac5dc..9437431ad913754ffd4464f37d52572eb61edf7f 100644
--- a/Source/core/svg/SVGMissingGlyphElement.h
+++ b/Source/core/svg/SVGMissingGlyphElement.h
@@ -21,6 +21,7 @@
#define SVGMissingGlyphElement_h
#if ENABLE(SVG_FONTS)
+#include "SVGNames.h"
#include "core/svg/SVGElement.h"
namespace WebCore {
@@ -35,6 +36,12 @@ private:
virtual bool rendererIsNeeded(const NodeRenderingContext&) { return false; }
};
+inline SVGMissingGlyphElement* toSVGMissingGlyphElement(Node* node)
+{
+ ASSERT_WITH_SECURITY_IMPLICATION(!node || node->hasTagName(SVGNames::missing_glyphTag));
+ return static_cast<SVGMissingGlyphElement*>(node);
+}
+
} // namespace WebCore
#endif // ENABLE(SVG_FONTS)
« no previous file with comments | « Source/core/svg/SVGFontElement.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698