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

Unified Diff: Source/core/html/HTMLKeygenElement.cpp

Issue 304003002: Don't mutate the DOM from inside an Element's constructor (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Fix includes Created 6 years, 7 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/html/HTMLKeygenElement.h ('k') | Source/core/html/HTMLMediaElement.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/HTMLKeygenElement.cpp
diff --git a/Source/core/html/HTMLKeygenElement.cpp b/Source/core/html/HTMLKeygenElement.cpp
index 73a58342093b9ded1d4c7f1cc82223cb4883d56c..909bb0e9930fc4c0215a6cf36350203d99470c7b 100644
--- a/Source/core/html/HTMLKeygenElement.cpp
+++ b/Source/core/html/HTMLKeygenElement.cpp
@@ -46,7 +46,13 @@ HTMLKeygenElement::HTMLKeygenElement(Document& document, HTMLFormElement* form)
: HTMLFormControlElementWithState(keygenTag, document, form)
{
ScriptWrappable::init(this);
- ensureUserAgentShadowRoot();
+}
+
+PassRefPtrWillBeRawPtr<HTMLKeygenElement> HTMLKeygenElement::create(Document& document, HTMLFormElement* form)
+{
+ RefPtrWillBeRawPtr<HTMLKeygenElement> keygen = adoptRefWillBeRefCountedGarbageCollected(new HTMLKeygenElement(document, form));
+ keygen->ensureUserAgentShadowRoot();
+ return keygen.release();
}
void HTMLKeygenElement::didAddUserAgentShadowRoot(ShadowRoot& root)
« no previous file with comments | « Source/core/html/HTMLKeygenElement.h ('k') | Source/core/html/HTMLMediaElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698