Closed Bug 1212116 Opened 9 years ago Closed 8 years ago

No wheel events fire on disabled <input> elements

Categories

(Core :: DOM: Events, defect)

44 Branch
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla47
Tracking Status
firefox47 --- fixed

People

(Reporter: drgigguls, Assigned: smaug)

References

()

Details

(Keywords: testcase)

Attachments

(1 file)

User Agent: Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/45.0.2454.101 Safari/537.36

Steps to reproduce:

1) I used a plugin to style the scrollbar on Firefox. The plugin doesn't really matter, every mature javascript plugin behaves like demonstrated.
2) I'm having an <input type="text" disabled> (could be a textarea, also applicable on mobile devices)


Actual results:

When I hover the disabled input and use mousescroll, nothing happens.
Video: https://www.youtube.com/watch?v=7FGel8wdi9Y&hd=1


Expected results:

It should scroll like the other browsers do.
(In reply to Vergil Penkov from comment #0)
> User Agent: Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML,
> like Gecko) Chrome/45.0.2454.101 Safari/537.36
> 
> Steps to reproduce:
> 
> 1) I used a plugin to style the scrollbar on Firefox. The plugin doesn't
> really matter, every mature javascript plugin behaves like demonstrated.

Can you please give a more complete testcase in a jsbin, codepen, jsfiddle, or by attaching a file or set of files to this bug?

At the moment it's not clear whether, say, that scrollbar is entirely constructed in client DOM, or whether you simply mean that the container has overflow-y: scroll or auto and there's some CSS that styles the scrollbars, or something else still. In order to reproduce and work out what the problem is, that's quite important information to have.
Flags: needinfo?(drgigguls)
Keywords: testcase-wanted
Product: Firefox → Core
Component: Untriaged → General
Flags: needinfo?(drgigguls)
http://jsfiddle.net/1uzug7jn/

There's a link.
This happens with every custom scrollbar plugin.
OS: Unspecified → All
Product: Core → Firefox
Hardware: Unspecified → All
I created a minimal-ish testcase: http://codepen.io/anon/pen/BjyxrN . Olli or Neil, do you know what's going on here?
Status: UNCONFIRMED → NEW
Component: General → DOM: Events
Ever confirmed: true
Flags: needinfo?(enndeakin)
Flags: needinfo?(bugs)
Product: Firefox → Core
Summary: Disabled inputs ignore mouse scroll → No wheel events fire on disabled <input> elements
It is unspecified which events should fire on disabled elements, different browsers fire different events.
And we're too strict here.
Assignee: nobody → bugs
Flags: needinfo?(bugs)
Just to further clarify, this is an issue with <textarea> elements as well. Presumably <button> also.
Yes, various form elements (not talking about <form> but <input> etc as form elements.)
Flags: needinfo?(enndeakin)
Attached patch patchSplinter Review
Attachment #8724054 - Flags: review?(bzbarsky)
note, the patch affects just which events are dispatched to dom, not what is being scrolled.
Comment on attachment 8724054 [details] [diff] [review]
patch

r=me
Attachment #8724054 - Flags: review?(bzbarsky) → review+
https://hg.mozilla.org/mozilla-central/rev/c728ed2a0ba9
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla47
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: