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

Unified Diff: Source/core/dom/CustomElementRegistry.cpp

Issue 23717043: Implement Custom Elements 'extends' option. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 3 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/dom/CustomElementException.cpp ('k') | Source/core/scripts/make_names.pl » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/CustomElementRegistry.cpp
diff --git a/Source/core/dom/CustomElementRegistry.cpp b/Source/core/dom/CustomElementRegistry.cpp
index b734c82a94060ef722df0b1be55276ad6768be78..00d6d71b81a83c162260942c46d270913c9cd859 100644
--- a/Source/core/dom/CustomElementRegistry.cpp
+++ b/Source/core/dom/CustomElementRegistry.cpp
@@ -78,16 +78,13 @@ CustomElementDefinition* CustomElementRegistry::registerElement(Document* docume
return 0;
}
- if (!constructorBuilder->validateOptions(type, es))
- return 0;
-
QualifiedName tagName = nullQName();
- if (!constructorBuilder->findTagName(type, tagName)) {
- CustomElementException::throwException(CustomElementException::PrototypeDoesNotExtendHTMLElementSVGElementNamespace, type, es);
+ if (!constructorBuilder->validateOptions(type, tagName, es))
return 0;
- }
+
ASSERT(tagName.namespaceURI() == HTMLNames::xhtmlNamespaceURI || tagName.namespaceURI() == SVGNames::svgNamespaceURI);
+ // FIXME: This should be done earlier in validateOptions.
if (m_registeredTypeNames.contains(type)) {
CustomElementException::throwException(CustomElementException::TypeAlreadyRegistered, type, es);
return 0;
« no previous file with comments | « Source/core/dom/CustomElementException.cpp ('k') | Source/core/scripts/make_names.pl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698