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

Issue 128133002: Update of change event for input type number (Closed)

Created:
6 years, 11 months ago by Habib Virji
Modified:
6 years, 10 months ago
Reviewers:
tkent, keishi
CC:
blink-reviews, dglazkov+blink, adamk+blink_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/blink.git@master
Visibility:
Public.

Description

Do not dispatch 'change' events during pressing spin buttons for input[type=number]. TextFieldInputType sends change event for its derived class. Change is done for DispatchInputAndChangeEvent to behave similar to DispatchChangeEvent. DispatchChangeEvent is generated by Range, Radio, File and Checkbox input type. DispatchInputAndChangeEvent is generated by inputtype for step up and down, BaseChooser/BaseMultipleFieldsDateandTime also generates DispatchInputAndChangeEvent. Since it is different set of inputs that generate DispatchChange and DispatchInputAndChange, both are kept but behavior is changed; this allows spin button to handle mouseup event. Keyboard events are also handled for spin button. R=tkent BUG=155747 TEST=automated Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=165300

Patch Set 1 #

Total comments: 1

Patch Set 2 : OnChange event for input type number #

Total comments: 1

Patch Set 3 : Code review updates #

Total comments: 8

Patch Set 4 : #

Patch Set 5 : Added callback function in SpinButtonOwner and added new tests #

Total comments: 4

Patch Set 6 : Code review changes #

Unified diffs Side-by-side diffs Delta from patch set Stats (+68 lines, -8 lines) Patch
A LayoutTests/fast/forms/number/number-spinbutton-changeevent-trigger.html View 1 2 3 4 5 1 chunk +33 lines, -0 lines 0 comments Download
A LayoutTests/fast/forms/number/number-spinbutton-changeevent-trigger-expected.txt View 1 2 3 4 1 chunk +10 lines, -0 lines 0 comments Download
M LayoutTests/fast/forms/number/number-type-update-by-change-event.html View 3 4 1 chunk +1 line, -0 lines 0 comments Download
M Source/core/html/forms/BaseMultipleFieldsDateAndTimeInputType.h View 1 2 3 4 5 1 chunk +1 line, -0 lines 0 comments Download
M Source/core/html/forms/BaseMultipleFieldsDateAndTimeInputType.cpp View 1 2 3 4 5 1 chunk +5 lines, -0 lines 0 comments Download
M Source/core/html/forms/InputType.cpp View 1 4 2 chunks +5 lines, -5 lines 0 comments Download
M Source/core/html/forms/TextFieldInputType.h View 1 2 3 4 5 1 chunk +1 line, -0 lines 0 comments Download
M Source/core/html/forms/TextFieldInputType.cpp View 1 2 3 4 5 2 chunks +6 lines, -0 lines 0 comments Download
M Source/core/html/shadow/SpinButtonElement.h View 1 2 3 4 5 1 chunk +1 line, -0 lines 0 comments Download
M Source/core/html/shadow/SpinButtonElement.cpp View 1 2 3 4 5 2 chunks +5 lines, -3 lines 0 comments Download

Messages

Total messages: 19 (0 generated)
Habib Virji
TextFieldInputType sends change event for its derived class. Change is done for DispatchInputAndChangeEvent to behave ...
6 years, 11 months ago (2014-01-08 12:24:31 UTC) #1
tkent
https://codereview.chromium.org/128133002/diff/1/Source/core/html/forms/TextFieldInputType.cpp File Source/core/html/forms/TextFieldInputType.cpp (right): https://codereview.chromium.org/128133002/diff/1/Source/core/html/forms/TextFieldInputType.cpp#newcode181 Source/core/html/forms/TextFieldInputType.cpp:181: case DispatchInputAndChangeEvent: This is not acceptable as I already ...
6 years, 11 months ago (2014-01-14 01:06:46 UTC) #2
Habib Virji
On 2014/01/14 01:06:46, tkent wrote: > https://codereview.chromium.org/128133002/diff/1/Source/core/html/forms/TextFieldInputType.cpp > File Source/core/html/forms/TextFieldInputType.cpp (right): > > https://codereview.chromium.org/128133002/diff/1/Source/core/html/forms/TextFieldInputType.cpp#newcode181 > ...
6 years, 11 months ago (2014-01-14 16:07:09 UTC) #3
tkent
We need a test to confirm that 'change' events are not dispatched during pressing a ...
6 years, 11 months ago (2014-01-15 00:19:44 UTC) #4
Habib Virji
On 2014/01/15 00:19:44, tkent wrote: > We need a test to confirm that 'change' events ...
6 years, 11 months ago (2014-01-15 09:50:53 UTC) #5
tkent
https://codereview.chromium.org/128133002/diff/110001/LayoutTests/fast/forms/number/number-type-update-by-change-event.html File LayoutTests/fast/forms/number/number-type-update-by-change-event.html (right): https://codereview.chromium.org/128133002/diff/110001/LayoutTests/fast/forms/number/number-type-update-by-change-event.html#newcode24 LayoutTests/fast/forms/number/number-type-update-by-change-event.html:24: function testMouseChangeEvent(){ Please do not modify this test. This ...
6 years, 11 months ago (2014-01-16 06:05:19 UTC) #6
Habib Virji
https://codereview.chromium.org/128133002/diff/110001/LayoutTests/fast/forms/number/number-type-update-by-change-event.html File LayoutTests/fast/forms/number/number-type-update-by-change-event.html (right): https://codereview.chromium.org/128133002/diff/110001/LayoutTests/fast/forms/number/number-type-update-by-change-event.html#newcode24 LayoutTests/fast/forms/number/number-type-update-by-change-event.html:24: function testMouseChangeEvent(){ On 2014/01/16 06:05:19, tkent wrote: > Please ...
6 years, 11 months ago (2014-01-16 09:49:18 UTC) #7
Habib Virji
Uploaded new patch set
6 years, 11 months ago (2014-01-16 12:25:12 UTC) #8
tkent
Some minor comments. https://codereview.chromium.org/128133002/diff/390002/LayoutTests/fast/forms/number/number-spinbutton-changeevent-trigger.html File LayoutTests/fast/forms/number/number-spinbutton-changeevent-trigger.html (right): https://codereview.chromium.org/128133002/diff/390002/LayoutTests/fast/forms/number/number-spinbutton-changeevent-trigger.html#newcode11 LayoutTests/fast/forms/number/number-spinbutton-changeevent-trigger.html:11: ++changeEventCounter; We usually use four-space indentation ...
6 years, 11 months ago (2014-01-17 02:19:19 UTC) #9
Habib Virji
On 2014/01/17 02:19:19, tkent wrote: > Some minor comments. > > https://codereview.chromium.org/128133002/diff/390002/LayoutTests/fast/forms/number/number-spinbutton-changeevent-trigger.html > File LayoutTests/fast/forms/number/number-spinbutton-changeevent-trigger.html ...
6 years, 11 months ago (2014-01-17 08:35:48 UTC) #10
tkent
lgtm
6 years, 11 months ago (2014-01-17 09:39:17 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/habib.virji@samsung.com/128133002/540001
6 years, 11 months ago (2014-01-17 09:39:36 UTC) #12
commit-bot: I haz the power
Change committed as 165300
6 years, 11 months ago (2014-01-17 10:45:48 UTC) #13
tkent
A revert of this CL has been created in https://codereview.chromium.org/140793012/ by tkent@chromium.org. The reason for ...
6 years, 11 months ago (2014-01-20 03:44:11 UTC) #14
tkent
On 2014/01/20 03:44:11, tkent wrote: > time-multiple-fields-spinbutton-change-and-input-events.html falky. falky -> flaky
6 years, 11 months ago (2014-01-20 03:52:19 UTC) #15
tkent
See http://test-results.appspot.com/dashboards/flakiness_dashboard.html#group=%40ToT%20Blink&tests=time-multiple-fields-spinbutton-change-and-input-events.html
6 years, 11 months ago (2014-01-20 03:53:34 UTC) #16
tkent
I'm sorry that the revert didn't fix the flakiness. I'll revert the revert.
6 years, 11 months ago (2014-01-20 04:30:07 UTC) #17
tkent
A revert of this CL has been created in https://codereview.chromium.org/159483004/ by tkent@chromium.org. The reason for ...
6 years, 10 months ago (2014-02-12 07:37:46 UTC) #18
tkent
6 years, 10 months ago (2014-02-12 08:02:28 UTC) #19
Message was sent while issue was closed.
On 2014/02/12 07:37:46, tkent wrote:
> A revert of this CL has been created in
> https://codereview.chromium.org/159483004/ by mailto:tkent@chromium.org.
> 
> The reason for reverting is: INPUT element dispatches extra events.
> .

Reverted manually: https://codereview.chromium.org/157813010/

Powered by Google App Engine
This is Rietveld 408576698