Open Bug 2029043 Opened 5 months ago Updated 5 months ago

Use PureRelative scroll position update in more situations to fix bug 2009679

Categories

(Core :: Panning and Zooming, task, P3)

task

Tracking

()

People

(Reporter: hiro, Unassigned)

References

(Depends on 1 open bug)

Details

Attachments

(5 files)

This is an alternative approach to fix bug 2009679. This approach should be independent from bug 1946610 (scroll position rounding/pixel alignment), of course even with this approach there may be appearing scroll jittering due to scroll position rounding, but the behavior of bug 2009679 will be significantly improved, I would say scroll stuck will be resolved.

This bug mainly consists of three parts; 1) bug 1740164, 2) a subset of 1662022, i.e. changing this NewRelativeScroll to NewPureRelativeScroll, 3) ScrollOrigin::Clamp becomes PureRelative rather than Absolute.

Bug 2029033 might also be mandatory in some edge cases to make this bug more robust, such as multiple PureRelative happens at once while paint skipping.

It turned out that bug 1740164 is unnecessary since bug 2009679's case is actually involving a smooth animation being run by APZ.

No longer depends on: 1740164
User Story: (updated)

There are two small but important differences between FrameMetrics::ApplyPureRelativeScrollUpdateFrom and FrameMetrics::ApplyRelativeScrollUpdateFrom;

  1. ApplyRelativeScrollUpdateFrom uses the update source which was introduced in bug 1978682
  2. ApplyRelativeScrollUpdateFrom doesn't clamp the destination, which was introduced in bug 1871760

For 1) after-scrollable-range-shrinkage-001.html and other after-scrollable-range-shrinkage-00X.html can be test cases for pure relative scroll position update once after we migrated this NewRelativeScroll to NewPureRelativeScroll.

But for 2) I haven't succeeded in writing automated tests, bug 1978682 landed a gtest but modifying the test doesn't catch the bug in pure relative cases.

Meanwhile I realized that

(In reply to Hiroyuki Ikezoe (:hiro) from comment #0)

  1. ScrollOrigin::Clamp becomes PureRelative rather than Absolute.

Just changing ScrollOrigin::Clamp from ScrollUpdateType::Absolute to ScrollUpdateType::Relative fixes bug 2009679. I am going to file a new bug for the change.

Depends on: 2029551

Filed bug 2029551. This bug is no longer blocking bug 2009679.

No longer blocks: 2009679
User Story: (updated)
See Also: → 2009679

As of now clamping while applying the update is not a problem, but it
will be a problem when we merge pure relative into relative one.

There are some test cases in wpts which will be affected by this change
when we have merged those scroll position updates.

testing/web-platform/tests/css/css-scroll-anchoring/after-scrollable-range-shrinkage-00[1-4].html

For references in future I uploaded the changes for this bug.

Severity: -- → S3
Type: defect → task
Priority: -- → P3
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: