Closed Bug 1592474 Opened 5 years ago Closed 5 years ago

Add some heuristics to disable scroll anchoring in pathological cases.

Categories

(Core :: Layout: Scrolling and Overflow, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla72
Tracking Status
firefox72 --- fixed

People

(Reporter: emilio, Assigned: emilio)

References

(Blocks 1 open bug)

Details

Attachments

(3 files)

The idea of these are not to penalize legit uses of scroll anchoring, and catching pathological cases fast.

The current algorithm I thought of is just whether the average of all the consecutive scroll anchoring adjustments is less than a given threshold.

If the average adjustment is close to zero and the user is not scrolling, it means that we're not making much progress.

Exact number may need tuning, let me know if you want it nightly-and-early-beta-only for now or something.

The idea of these are not to penalize legit uses of scroll anchoring, and
catching pathological cases fast.

The current algorithm I thought of is just whether the average of all the
consecutive scroll anchoring adjustments is less than a given threshold.

If the average adjustment is close to zero and the user is not scrolling, it
means that we're not making much progress.

It is important that zero adjustments don't get counted, since those are common
during window resizes and don't have side-effects anyway.

Exact number may need tuning, let me know if you want it
nightly-and-early-beta-only for now or something.

Attachment #9105103 - Attachment description: Bug 1592474 - Report a console warning when this happens. → Bug 1592474 - Report a console warning when we disable scroll anchoring on a scroller.
Pushed by ealvarez@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/49e2e43d3252 Share code between ScrollAnchorContainer::{Destroy,InvalidateAnchor}. r=dholbert https://hg.mozilla.org/integration/autoland/rev/b757148cddfd Add some heuristics to disable scroll anchoring in pathological cases. r=dholbert https://hg.mozilla.org/integration/autoland/rev/08338f14d554 Report a console warning when we disable scroll anchoring on a scroller. r=dholbert,flod
No longer blocks: 1592094
See Also: → 1592094
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: