Closed
Bug 1161634
Opened 9 years ago
Closed 9 years ago
Allow synthesizing native mouse wheel events on Linux
Categories
(Core :: Widget: Gtk, defect)
Tracking
()
RESOLVED
FIXED
mozilla41
Tracking | Status | |
---|---|---|
firefox41 | --- | fixed |
People
(Reporter: kats, Assigned: kats)
References
Details
Attachments
(2 files, 1 obsolete file)
4.15 KB,
patch
|
karlt
:
review+
|
Details | Diff | Splinter Review |
2.89 KB,
patch
|
mstange
:
review+
|
Details | Diff | Splinter Review |
+++ This bug was initially created as a clone of Bug #1161206 +++ In order to properly exercise the APZ code we need to be able to synthesize and dispatch native events on desktop platforms. The stubs for these already exist (see nsIDOMWindowUtils::sendNative*) but they are not implemented across all platforms. This bug is specifically about implementing SynthesizeNativeMouseScrollEvent on GTK.
Assignee | ||
Comment 1•9 years ago
|
||
The synthesization works, but the test actually fails *without* APZ because the preventDefault on the wheel event is getting ignored or something. Need to investigate more.
Assignee: nobody → bugmail.mozilla
Assignee | ||
Comment 2•9 years ago
|
||
Attachment #8601620 -
Attachment is obsolete: true
Assignee | ||
Comment 3•9 years ago
|
||
Awaiting try push https://treeherder.mozilla.org/#/jobs?repo=try&revision=dbc13893d1a1 with baited breath.
Assignee | ||
Updated•9 years ago
|
Attachment #8601668 -
Flags: review?(karlt)
Assignee | ||
Comment 4•9 years ago
|
||
Comment on attachment 8601669 [details] [diff] [review] Part 2 - Update test to run on linux Try is green (I know it doesn't look like it, but it's true! M-4 is where the test is, all the other chunks are empty because I used --tag in the try syntax, and get detected as failing).
Attachment #8601669 -
Flags: review?(mstange)
Comment 5•9 years ago
|
||
Comment on attachment 8601669 [details] [diff] [review] Part 2 - Update test to run on linux Review of attachment 8601669 [details] [diff] [review]: ----------------------------------------------------------------- cool
Attachment #8601669 -
Flags: review?(mstange) → review+
Comment 6•9 years ago
|
||
Comment on attachment 8601668 [details] [diff] [review] Part 1 - Implement native wheel event synth on gtk >+ AutoObserverNotifier notifier(aObserver, "mousescrollevent"); I don't know the purpose of this. Don't is matter that Observe() is called before the GdkEvent is actually processed?
Attachment #8601668 -
Flags: review?(karlt) → review+
Assignee | ||
Comment 7•9 years ago
|
||
(In reply to Karl Tomlinson (ni?:karlt) from comment #6) > I don't know the purpose of this. > Don't is matter that Observe() is called before the GdkEvent is actually > processed? It's basically a ping back to the caller to indicate that the synthesization function has run. We need it because it run asynchronously from the call to nsIDOMWindowUtils::sendNative*Event. (That, in turn, was done so that the e10s and non-e10s cases would behave the same, since the e10s cases would necessarily be async across the IPC bridge). And no, in general we can't track these events "through" the OS layer so the Observe() just reports that the widget did the synthesization as requested. The caller can listen for the actual gecko event if they want to make sure it got created (and in fact that's what I do in the test).
https://hg.mozilla.org/integration/mozilla-inbound/rev/18474e89292a https://hg.mozilla.org/integration/mozilla-inbound/rev/7141b7088a89
Comment 9•9 years ago
|
||
sorry had to back this out for test failures like https://treeherder.mozilla.org/logviewer.html#?job_id=9604133&repo=mozilla-inbound
Flags: needinfo?(bugmail.mozilla)
Comment 10•9 years ago
|
||
Backout: https://hg.mozilla.org/integration/mozilla-inbound/rev/5eb58823f834 https://hg.mozilla.org/integration/mozilla-inbound/rev/d4462013432a
Assignee | ||
Comment 11•9 years ago
|
||
So the test passes when run in isolation, in both e10s and non-e10s [1]. It passes on non-e10s when run along with the rest of M-4 suite, but fails on e10s [2]. Therefore some other test in M-4 suite is interfering with this test, causing it to fail, in e10s mode. What's annoying is that when I run the tests locally they pass always. (Also, running --total-chunks 5 --this-chunk 4 locally runs a different set of tests than on tryserver; I have to use --total-chunks 9 --this-chunk 8 to get approximately the same set of tests, and even then it's not perfect). [1] https://treeherder.mozilla.org/#/jobs?repo=try&revision=08d95edf5cb3 [2] https://treeherder.mozilla.org/#/jobs?repo=try&revision=26d5fb568ce9
Flags: needinfo?(bugmail.mozilla)
Assignee | ||
Comment 12•9 years ago
|
||
Soo... I got a loaner and was able to reproduce the failure. Then I did some bisection attempts by playing with --total-chunks and --this-chunk and narrowed it down. At some point the test started passing, but it was also the first test in the chunk at that point. So then I tried shifting the chunks and widening the range again to try and narrow down a good vs bad range, and now I can't reproduce the failure at all, even with the original arguments that could reproduce them. *sigh*
Assignee | ||
Comment 13•9 years ago
|
||
After rebooting the loaner instance I was able to reproduce the problem again. After fiddling with the chunks some more I narrowed it down to the libeditor tests (I learnt that tests from a single folder never get split across chunks) so after that I had to start commenting out tests. I seem to have narrowed it down to test_bug417418.html in the libeditor mochitest suite. If I disable that test things pass. Looking at the test the likely problem is that it synthesizes a bunch of mousedown events without the corresponding mouse-up events, causing the widget to enter a drag state and screwing up future tests.
Assignee | ||
Comment 14•9 years ago
|
||
Filed bug 1163640 for fixing the bug417418 test.
Comment 15•9 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/5655a0ee61f2 https://hg.mozilla.org/integration/mozilla-inbound/rev/d0129aa5b896
Comment 16•9 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/5655a0ee61f2 https://hg.mozilla.org/mozilla-central/rev/d0129aa5b896
Status: NEW → RESOLVED
Closed: 9 years ago
status-firefox41:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla41
You need to log in
before you can comment on or make changes to this bug.
Description
•