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

Unified Diff: third_party/WebKit/Source/core/dom/Document.cpp

Issue 2443543002: createElement should not transmit exceptions but report them. (Closed)
Patch Set: Rebaseline tests. Created 4 years, 2 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: third_party/WebKit/Source/core/dom/Document.cpp
diff --git a/third_party/WebKit/Source/core/dom/Document.cpp b/third_party/WebKit/Source/core/dom/Document.cpp
index a1f92e74158c37a6663c43c8ed9ca84239aefff6..3ee106f070bc46b6199665830726783ead72d2ef 100644
--- a/third_party/WebKit/Source/core/dom/Document.cpp
+++ b/third_party/WebKit/Source/core/dom/Document.cpp
@@ -658,8 +658,7 @@ Element* Document::createElement(const AtomicString& name,
// converted to ASCII lowercase.
AtomicString localName = convertLocalName(name);
if (CustomElement::shouldCreateCustomElement(localName))
- return CustomElement::createCustomElementSync(*this, localName,
- exceptionState);
+ return CustomElement::createCustomElementSync(*this, localName);
return HTMLElementFactory::createHTMLElement(localName, *this, 0,
CreatedByCreateElement);
}
@@ -681,7 +680,7 @@ Element* Document::createElement(const AtomicString& localName,
if (CustomElement::shouldCreateCustomElement(convertLocalName(localName))) {
element = CustomElement::createCustomElementSync(
- *this, convertLocalName(localName), exceptionState);
+ *this, convertLocalName(localName));
} else if (V0CustomElement::isValidName(localName) && registrationContext()) {
element = registrationContext()->createCustomTagElement(
*this, QualifiedName(nullAtom, convertLocalName(localName),
@@ -730,7 +729,7 @@ Element* Document::createElementNS(const AtomicString& namespaceURI,
return nullptr;
if (CustomElement::shouldCreateCustomElement(qName))
- return CustomElement::createCustomElementSync(*this, qName, exceptionState);
+ return CustomElement::createCustomElementSync(*this, qName);
return createElement(qName, CreatedByCreateElement);
}
@@ -745,8 +744,7 @@ Element* Document::createElementNS(const AtomicString& namespaceURI,
Element* element;
if (CustomElement::shouldCreateCustomElement(qName))
- element =
- CustomElement::createCustomElementSync(*this, qName, exceptionState);
+ element = CustomElement::createCustomElementSync(*this, qName);
else if (V0CustomElement::isValidName(qName.localName()) &&
registrationContext())
element = registrationContext()->createCustomTagElement(*this, qName);

Powered by Google App Engine
This is Rietveld 408576698