Closed
Bug 369793
Opened 19 years ago
Closed 19 years ago
DOMMouseScroll events not dispatched when they cause text zoom changes
Categories
(Core :: DOM: UI Events & Focus Handling, defect)
Core
DOM: UI Events & Focus Handling
Tracking
()
RESOLVED
FIXED
People
(Reporter: myk, Assigned: smaug)
References
Details
Attachments
(2 files, 1 obsolete file)
|
1.07 KB,
text/html
|
Details | |
|
22.51 KB,
patch
|
jst
:
review+
peterv
:
superreview+
|
Details | Diff | Splinter Review |
nsEventStateManager::DoScrollTextsize doesn't dispatch events, so when nsEventStateManager::PostHandleEvent calls it to change the text zoom, event listeners don't get notified about the DOMMouseScroll event.
Contrast with nsEventStateManager::DoScrollText, which does dispatch events. Seems like DoScrollTextsize should dispatch events just like DoScrollText does, so listeners who care about text zoom changes can find out about them.
| Assignee | ||
Comment 1•19 years ago
|
||
The testcase shows that currently DOMMouseScroll is also targeted wrongly.Event target shouldn't be [object Text], which it is currently
if mouse is over some text.
Assignee: events → Olli.Pettay
Status: NEW → ASSIGNED
| Assignee | ||
Comment 2•19 years ago
|
||
This removes explicit DOMMouseScroll dispatching, because there is
already NS_MOUSE_SCROLL event being dispatched.
event->detail is now updated in ESM::PreHandleEvent so that it has
the right value during the actual event dispatching.
Attachment #254795 -
Flags: review?(bzbarsky)
| Assignee | ||
Comment 3•19 years ago
|
||
Comment on attachment 254795 [details] [diff] [review]
Make DOMMouseScroll work more like other events
Oops, this doesn't handle nsIDOMNSUIEvent::SCROLL_PAGE_DOWN
properly.
Attachment #254795 -
Flags: review?(bzbarsky)
| Assignee | ||
Comment 4•19 years ago
|
||
This adds 2 calls to Get***Pref comparing to the current code,
but mouse wheel events aren't
dispatched that often (comparing to mouse move, for example).
The reason for those 2 calls is that PreHandleEvent needs to know
whether to useSysNumLines and what is the action for the mousewheel event. Those same values are then needed in PostHandleEvent.
The patch fixes the event targeting bug, because DOMMouseScroll is now
handled like any other event.
Attachment #254795 -
Attachment is obsolete: true
Attachment #254810 -
Flags: review?(bzbarsky)
Comment 5•19 years ago
|
||
I'm not going to be able to review this quickly... Please ask someone else if you want a review in the next few weeks?
| Assignee | ||
Updated•19 years ago
|
Attachment #254810 -
Flags: review?(bzbarsky) → review?(jst)
Comment 6•19 years ago
|
||
Comment on attachment 254810 [details] [diff] [review]
handles nsIDOMNSUIEvent::SCROLL_PAGE_UP/DOWN
r=jst
Attachment #254810 -
Flags: review?(jst) → review+
| Assignee | ||
Updated•19 years ago
|
Attachment #254810 -
Flags: superreview?(peterv)
Comment 7•19 years ago
|
||
Comment on attachment 254810 [details] [diff] [review]
handles nsIDOMNSUIEvent::SCROLL_PAGE_UP/DOWN
I wonder if it wouldn't be cheaper to use AppendLiteral instead of NS_LITERAL_CSTRING/Append. Either way, sr=peterv.
Attachment #254810 -
Flags: superreview?(peterv) → superreview+
| Assignee | ||
Comment 8•19 years ago
|
||
Writing a mochitest would require (an enhanced version of ) bug 364508.
Status: ASSIGNED → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
Updated•19 years ago
|
Flags: in-testsuite?
Updated•7 years ago
|
Component: Event Handling → User events and focus handling
You need to log in
before you can comment on or make changes to this bug.
Description
•