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

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

Issue 23886003: Have HTMLElements / SVGElements constructors take a Document reference in argument (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Another Android build fix 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/html/HTMLTextAreaElement.h ('k') | Source/core/html/HTMLTextFormControlElement.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/HTMLTextAreaElement.cpp
diff --git a/Source/core/html/HTMLTextAreaElement.cpp b/Source/core/html/HTMLTextAreaElement.cpp
index 8b87e238164fe04f59def98d621b237f861972ab..3ef62fe20e0b02152e9d51fad3754988dd14ee6d 100644
--- a/Source/core/html/HTMLTextAreaElement.cpp
+++ b/Source/core/html/HTMLTextAreaElement.cpp
@@ -79,7 +79,7 @@ static inline unsigned computeLengthForSubmission(const String& text)
return text.length() + numberOfLineBreaks(text);
}
-HTMLTextAreaElement::HTMLTextAreaElement(const QualifiedName& tagName, Document* document, HTMLFormElement* form)
+HTMLTextAreaElement::HTMLTextAreaElement(const QualifiedName& tagName, Document& document, HTMLFormElement* form)
: HTMLTextFormControlElement(tagName, document, form)
, m_rows(defaultRows)
, m_cols(defaultCols)
@@ -93,7 +93,7 @@ HTMLTextAreaElement::HTMLTextAreaElement(const QualifiedName& tagName, Document*
ScriptWrappable::init(this);
}
-PassRefPtr<HTMLTextAreaElement> HTMLTextAreaElement::create(const QualifiedName& tagName, Document* document, HTMLFormElement* form)
+PassRefPtr<HTMLTextAreaElement> HTMLTextAreaElement::create(const QualifiedName& tagName, Document& document, HTMLFormElement* form)
{
RefPtr<HTMLTextAreaElement> textArea = adoptRef(new HTMLTextAreaElement(tagName, document, form));
textArea->ensureUserAgentShadowRoot();
@@ -102,7 +102,7 @@ PassRefPtr<HTMLTextAreaElement> HTMLTextAreaElement::create(const QualifiedName&
void HTMLTextAreaElement::didAddUserAgentShadowRoot(ShadowRoot* root)
{
- root->appendChild(TextControlInnerTextElement::create(&document()));
+ root->appendChild(TextControlInnerTextElement::create(document()));
}
const AtomicString& HTMLTextAreaElement::formControlType() const
@@ -540,7 +540,7 @@ void HTMLTextAreaElement::updatePlaceholderText()
return;
}
if (!m_placeholder) {
- RefPtr<HTMLDivElement> placeholder = HTMLDivElement::create(&document());
+ RefPtr<HTMLDivElement> placeholder = HTMLDivElement::create(document());
m_placeholder = placeholder.get();
m_placeholder->setPart(AtomicString("-webkit-input-placeholder", AtomicString::ConstructFromLiteral));
userAgentShadowRoot()->insertBefore(m_placeholder, innerTextElement()->nextSibling());
« no previous file with comments | « Source/core/html/HTMLTextAreaElement.h ('k') | Source/core/html/HTMLTextFormControlElement.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698