New issue
Advanced search Search tips

Issue 682018 link

Starred by 3 users

Issue metadata

Status: Available
Owner: ----
Components:
EstimatedDays: ----
NextAction: ----
OS: All
Pri: 3
Type: Bug


Participants' hotlists:
Hotlist-1


Sign in to add a comment

preventDefault() for mousemove event prevents spin-button behavior

Reported by truefus...@gmail.com, Jan 17 2017

Issue description

UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.87 Safari/537.36

Steps to reproduce the problem:
1. Go here: https://jsfiddle.net/v9maqc0c/
2. Try to increment (or decrement) the visible input field using the HTML 5 controls (i.e. the up and down arrows).
3. Behold!

What is the expected behavior?
The value should change and mousemove event should not fire if mouse is not moving. Even if mouse moves when clicking, I don't think preventDefault() should prevent value changes for mousemove since mousemove default behavior for an input field should not relate to value changes.

What went wrong?
Mousemove event fires when I attempt to change the value using the HTML 5 input controls, and event.preventDefault() kicks in, preventing value changes.

Did this work before? N/A 

Chrome version: 55.0.2883.87  Channel: stable
OS Version: 10.0
Flash Version: Shockwave Flash 24.0 r0

There may have been a point in time where this did work as expected, but I can't remember. I also have no idea if this affects other input types, but this current issue prevents further development on Chrome.
 

Comment 1 by woxxom@gmail.com, Jan 18 2017

preventDefault on mousemove also makes Chrome highlight the wrong arrow both on hover and click - when the upper one is hovered/clicked, the bottom one is highlighted.

Comment 2 by rbyers@chromium.org, Jan 18 2017

Components: -Blink Blink>Forms>Number
Labels: -OS-Windows Hotlist-Interop OS-All
Status: Untriaged (was: Unconfirmed)
Interesting,
mousemove is not supposed to have a default action: https://w3c.github.io/uievents/#event-type-mousemove

Works correctly in Firefox and Safari.
Still broken in Chrome 42 so not a recent regression.


Comment 3 by tkent@chromium.org, Jan 19 2017

Labels: -Pri-2 Pri-3
Status: Available (was: Untriaged)
Summary: preventDefault() for mousemove event prevents spin-button behavior (was: mousemove Event.preventDefault() prevents input change!)
Spin button uses mousemove to check the pointer position while pressing the button.
I think it's possible to stop using mousemove by UA Shadow DOM structure change.

Any chance this can be bumped up to a priority higher than 3? 7 months and at least 4 major version releases since the time of this report, and it is still present. Since then I have managed to randomly come across the issue without preventDefault() and even without listening for any events on the input field, but I have not been able to isolate the cause, so unfortunately I am not able to provide any code concerning that at this time. Nevertheless, I am able to testify that this issue occurs under more than one situation.
Project Member

Comment 5 by sheriffbot@chromium.org, Aug 7

Labels: Hotlist-Recharge-Cold
Status: Untriaged (was: Available)
This issue has been Available for over a year. If it's no longer important or seems unlikely to be fixed, please consider closing it out. If it is important, please re-triage the issue.

Sorry for the inconvenience if the bug really should have been left as Available.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Labels: -Hotlist-Recharge-Cold
Status: Available (was: Untriaged)

Sign in to add a comment