Mouse wheel can initiate overscroll on macOS with apz.overscroll.enabled = true and does not snap back
Categories
(Core :: Panning and Zooming, defect, P2)
Tracking
()
People
(Reporter: sam, Assigned: botond)
References
(Blocks 1 open bug)
Details
(Whiteboard: [proton-uplift])
Attachments
(4 files)
(deleted),
image/png
|
Details | |
(deleted),
text/x-phabricator-request
|
pascalc
:
approval-mozilla-beta+
|
Details |
(deleted),
text/x-phabricator-request
|
pascalc
:
approval-mozilla-beta+
|
Details |
(deleted),
text/x-phabricator-request
|
pascalc
:
approval-mozilla-beta+
|
Details |
In Nightly on macOS (tested 10.13.6 and 11.2.3) with apz.overscroll.enabled = true, the mouse wheel can also initiate overscroll without touching the trackpad. When this happens, the page gets stuck in an overscrolled state until manually scrolling down.
STR:
- Connect a mouse to the Mac.
- In about:config, set apz.overscroll.enabled = true.
- Visit https://github.com
- Using the mouse scroll wheel, scroll down, then scroll back up quickly.
Expected result:
The page does not overscroll when scrolling with the mouse wheel.
Actual result:
The page is overscrolled so there is a gap at the top of the page, even when using the mouse wheel and not the trackpad. The gap at the top of the page remains until scrolling back down manually.
Assignee | ||
Updated•4 years ago
|
Comment 1•4 years ago
|
||
Can't reproduce on macOS 10.14.6.
Assignee | ||
Comment 2•4 years ago
|
||
Do you have "Use smooth scrolling" enabled in about:preferences
?
Reporter | ||
Comment 3•4 years ago
|
||
"Use smooth scrolling" is disabled on both machines exhibiting the issue. On that note, I do also have set mousewheel.acceleration.start = 1 and mousewheel.acceleration.factor = 5.
Assignee | ||
Comment 4•4 years ago
|
||
With smooth scrolling disabled, mousewheel scrolling takes the DispatchScroll codepath, which can cause overscrolling (without any provision to start a snap-back animation, which is the caller's responsibility to do "at the end of the gesture").
I expect this doesn't happen commonly, because if we're at the edge of the page, wheel scrolling early-exits here, but in some cases (e.g. here, "scroll down and back up quickly") we may get past that.
I think instant keyboard scrolling has a similar issue.
Assignee | ||
Updated•4 years ago
|
Updated•4 years ago
|
Assignee | ||
Updated•4 years ago
|
Assignee | ||
Updated•3 years ago
|
Assignee | ||
Comment 5•3 years ago
|
||
Sam, would you be able to give this build a try (it comes from this CI push), and let me know if the problem is resolved there? (Note, please check the "Use smooth scrolling" setting, and disable it if necessary, so that you're testing the same configuration in which you encountered the bug.)
Reporter | ||
Comment 6•3 years ago
|
||
Hi Botond, I cannot reproduce the issue in the try build with macOS 11.3 or 10.13.6. As a sanity check I performed the same profile modifications in a recent autoland build, and was able to reproduce there, so it should be an accurate result. Thanks!
Updated•3 years ago
|
Assignee | ||
Comment 7•3 years ago
|
||
Thanks! That confirms my theory from comment 4. Will post the fix + a test for review shortly.
Assignee | ||
Comment 8•3 years ago
|
||
This makes the only existing place where we check
OverscrollHandoffState::mScrollSource express the check in a
more semantic way.
Assignee | ||
Comment 9•3 years ago
|
||
Also rename ScrollSource::Touch to Touchscreen for clarity.
Depends on D113457
Assignee | ||
Comment 10•3 years ago
|
||
Previously, it was implicitly disallowed by some checks in the wheel
handling code (e.g. CanScrollWithWheel()), but some cases (like
instant scroll where the starting position is away from the edge)
slipped through the cracks.
Depends on D113458
Comment 12•3 years ago
|
||
Comment 13•3 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/1b6de39f20be
https://hg.mozilla.org/mozilla-central/rev/9cef9dcb20b0
https://hg.mozilla.org/mozilla-central/rev/891e5a5fc7bf
Assignee | ||
Comment 14•3 years ago
|
||
Comment on attachment 9218547 [details]
Bug 1704410 - Explicitly disallow overscroll for wheel events. r=hiro
Beta/Release Uplift Approval Request
- User impact if declined: [Needed for MR1 / Proton] Sometimes users are able to activate overscroll via a regular mousewheel, and the page can get stuck in the overscrolled state (no snap-back animation)
- Is this code covered by automated tests?: Yes
- Has the fix been verified in Nightly?: Yes
- Needs manual test from QE?: No
- If yes, steps to reproduce:
- List of other uplifts needed: Bug 1704659
- Risk to taking this patch: Low
- Why is the change risky/not risky? (and alternatives if risky): Targeted fix, only affects the ability of mousewheel specifically to trigger overscroll
- String changes made/needed:
Assignee | ||
Updated•3 years ago
|
Assignee | ||
Updated•3 years ago
|
Comment 15•3 years ago
|
||
Comment on attachment 9218547 [details]
Bug 1704410 - Explicitly disallow overscroll for wheel events. r=hiro
Approved for 89 beta 6, thanks.
Updated•3 years ago
|
Updated•3 years ago
|
Comment 16•3 years ago
|
||
bugherder uplift |
Comment 17•3 years ago
|
||
Verified fixed on Firefox beta 89.0b8 (20210504185920) and Nightly 90.0a1(20210504214950).
Description
•