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

Unified Diff: Source/core/html/forms/BaseButtonInputType.cpp

Issue 27746003: Have InputType factories take an HTMLInputElement reference in parameter (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase on master Created 7 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
« no previous file with comments | « Source/core/html/forms/BaseButtonInputType.h ('k') | Source/core/html/forms/BaseCheckableInputType.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/forms/BaseButtonInputType.cpp
diff --git a/Source/core/html/forms/BaseButtonInputType.cpp b/Source/core/html/forms/BaseButtonInputType.cpp
index 3ea90b5398e5d680b2fd52764ff9e1be95bf5d9a..5f2af456653b34312b0a16c5302693bf3aaadf43 100644
--- a/Source/core/html/forms/BaseButtonInputType.cpp
+++ b/Source/core/html/forms/BaseButtonInputType.cpp
@@ -65,14 +65,14 @@ public:
void BaseButtonInputType::createShadowSubtree()
{
- ASSERT(element()->userAgentShadowRoot());
- RefPtr<Text> text = NonSelectableText::create(element()->document(), element()->valueWithDefault());
- element()->userAgentShadowRoot()->appendChild(text);
+ ASSERT(element().userAgentShadowRoot());
+ RefPtr<Text> text = NonSelectableText::create(element().document(), element().valueWithDefault());
+ element().userAgentShadowRoot()->appendChild(text);
}
void BaseButtonInputType::valueAttributeChanged()
{
- toText(element()->userAgentShadowRoot()->firstChild())->setData(element()->valueWithDefault());
+ toText(element().userAgentShadowRoot()->firstChild())->setData(element().valueWithDefault());
}
bool BaseButtonInputType::shouldSaveAndRestoreFormControlState() const
@@ -88,7 +88,7 @@ bool BaseButtonInputType::appendFormData(FormDataList&, bool) const
RenderObject* BaseButtonInputType::createRenderer(RenderStyle*) const
{
- return new RenderButton(element());
+ return new RenderButton(&element());
}
bool BaseButtonInputType::storesValueSeparateFromAttribute()
@@ -98,7 +98,7 @@ bool BaseButtonInputType::storesValueSeparateFromAttribute()
void BaseButtonInputType::setValue(const String& sanitizedValue, bool, TextFieldEventBehavior)
{
- element()->setAttribute(valueAttr, sanitizedValue);
+ element().setAttribute(valueAttr, sanitizedValue);
}
} // namespace WebCore
« no previous file with comments | « Source/core/html/forms/BaseButtonInputType.h ('k') | Source/core/html/forms/BaseCheckableInputType.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698