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

Unified Diff: Source/core/html/forms/InputTypeView.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/InputTypeView.h ('k') | Source/core/html/forms/MonthInputType.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/forms/InputTypeView.cpp
diff --git a/Source/core/html/forms/InputTypeView.cpp b/Source/core/html/forms/InputTypeView.cpp
index 99e778b6078cdf88c157d7cc151cb28e39fb91cd..accadf5f3624f582de53ea32a11872c2dee88465 100644
--- a/Source/core/html/forms/InputTypeView.cpp
+++ b/Source/core/html/forms/InputTypeView.cpp
@@ -34,7 +34,7 @@
namespace WebCore {
-PassRefPtr<InputTypeView> InputTypeView::create(HTMLInputElement* input)
+PassRefPtr<InputTypeView> InputTypeView::create(HTMLInputElement& input)
{
return adoptRef(new InputTypeView(input));
}
@@ -45,7 +45,7 @@ InputTypeView::~InputTypeView()
bool InputTypeView::sizeShouldIncludeDecoration(int, int& preferredSize) const
{
- preferredSize = element()->size();
+ preferredSize = element().size();
return false;
}
@@ -88,12 +88,12 @@ bool InputTypeView::shouldSubmitImplicitly(Event* event)
PassRefPtr<HTMLFormElement> InputTypeView::formForSubmission() const
{
- return element()->form();
+ return element().form();
}
RenderObject* InputTypeView::createRenderer(RenderStyle* style) const
{
- return RenderObject::createObject(element(), style);
+ return RenderObject::createObject(&element(), style);
}
PassRefPtr<RenderStyle> InputTypeView::customStyleForRenderer(PassRefPtr<RenderStyle> originalStyle)
@@ -103,7 +103,7 @@ PassRefPtr<RenderStyle> InputTypeView::customStyleForRenderer(PassRefPtr<RenderS
void InputTypeView::blur()
{
- element()->defaultBlur();
+ element().defaultBlur();
}
bool InputTypeView::hasCustomFocusLogic() const
« no previous file with comments | « Source/core/html/forms/InputTypeView.h ('k') | Source/core/html/forms/MonthInputType.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698