Bug 59246

Summary: Let the RenderTheme decide if an input type should have a spinner
Product: WebKit Reporter: Joseph Pecoraro <joepeck>
Component: FormsAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: ddkilzer, joepeck, sam, tkent
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: PC   
OS: OS X 10.5   
Attachments:
Description Flags
[PATCH] Let RenderTheme make the decisions
none
[PATCH] Let RenderTheme make the decisions tkent: review+

Description Joseph Pecoraro 2011-04-22 15:14:18 PDT
Having a spinner, a UI decision, is nicely made optional
in RenderTextControlSingleLine. Instead of defaulting
certain input types to use a spinner, let the RenderTheme
make the decision.
Comment 1 Joseph Pecoraro 2011-04-22 15:21:45 PDT
Created attachment 90776 [details]
[PATCH] Let RenderTheme make the decisions

Currently only TextFields check if a SpinButton should be added.
However the RenderTheme decision could be used in other places
in the future.
Comment 2 Joseph Pecoraro 2011-04-22 15:24:19 PDT
Created attachment 90777 [details]
[PATCH] Let RenderTheme make the decisions

Updated ChangeLog. (git add issue!)
Comment 3 Kent Tamura 2011-04-22 15:31:10 PDT
Comment on attachment 90777 [details]
[PATCH] Let RenderTheme make the decisions

View in context: https://bugs.webkit.org/attachment.cgi?id=90777&action=review

> Source/WebCore/rendering/RenderTheme.h:206
> +    // Return true if the input element should have a spin button.
> +    virtual bool shouldHaveSpinButtonForInputElement(InputElement*) const;

nit: The comment might be unnecessary.
nit: "ForInputElement" in the function name is redundant.  We may remove it.
Comment 4 Joseph Pecoraro 2011-04-22 15:34:02 PDT
> > Source/WebCore/rendering/RenderTheme.h:206
> > +    // Return true if the input element should have a spin button.
> > +    virtual bool shouldHaveSpinButtonForInputElement(InputElement*) const;
> 
> nit: The comment might be unnecessary.
> nit: "ForInputElement" in the function name is redundant.  We may remove it.

Sounds good. Thanks!
Comment 5 Joseph Pecoraro 2011-04-22 15:45:33 PDT
Landed in <http://trac.webkit.org/changeset/84695>. Thanks!