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

Unified Diff: Source/bindings/dart/DartCustomElementConstructorBuilder.cpp

Issue 188083002: Dartium support for manual custom element upgrades. (Closed) Base URL: svn://svn.chromium.org/blink/branches/dart/1750
Patch Set: Created 6 years, 8 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
Index: Source/bindings/dart/DartCustomElementConstructorBuilder.cpp
diff --git a/Source/bindings/dart/DartCustomElementConstructorBuilder.cpp b/Source/bindings/dart/DartCustomElementConstructorBuilder.cpp
index fd4dbf748625b6a55379bebac057aba9ea6a1856..77e04afb97d796ac36fef736659a8f2009f69639 100644
--- a/Source/bindings/dart/DartCustomElementConstructorBuilder.cpp
+++ b/Source/bindings/dart/DartCustomElementConstructorBuilder.cpp
@@ -91,15 +91,14 @@ bool DartCustomElementConstructorBuilder::validateOptions(const AtomicString& ty
m_nativeClassId = reinterpret_cast<intptr_t>(DartDOMWrapper::readNativePointer(nativeElement, DartDOMWrapper::kNativeTypeIndex));
- // TODO: enable once we pick up Blink version 31
- // if (!Document::isValidName(localName)) {
- // CustomElementException::throwException(CustomElementException::ExtendsIsInvalidName, type, es);
- // return false;
- // }
- // if (CustomElement::isValidName(localName)) {
- // CustomElementException::throwException(CustomElementException::ExtendsIsCustomElementName, type, es);
- // return false;
- // }
+ if (!Document::isValidName(localName)) {
+ CustomElementException::throwException(CustomElementException::ExtendsIsInvalidName, type, es);
+ return false;
+ }
+ if (CustomElement::isValidName(localName)) {
+ CustomElementException::throwException(CustomElementException::ExtendsIsCustomElementName, type, es);
+ return false;
+ }
} else {
localName = type;
m_nativeClassId = DartHTMLElement::dartClassId;
« no previous file with comments | « no previous file | Source/bindings/dart/DartCustomElementWrapper.h » ('j') | Source/bindings/dart/DartCustomElementWrapper.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698