Bug 59246 - Let the RenderTheme decide if an input type should have a spinner
Summary: Let the RenderTheme decide if an input type should have a spinner
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Forms (show other bugs)
Version: 528+ (Nightly build)
Hardware: PC OS X 10.5
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-04-22 15:14 PDT by Joseph Pecoraro
Modified: 2011-04-22 15:45 PDT (History)
4 users (show)

See Also:


Attachments
[PATCH] Let RenderTheme make the decisions (8.96 KB, patch)
2011-04-22 15:21 PDT, Joseph Pecoraro
no flags Details | Formatted Diff | Diff
[PATCH] Let RenderTheme make the decisions (9.62 KB, patch)
2011-04-22 15:24 PDT, Joseph Pecoraro
tkent: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
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!