HomePhorge

When stabilizing document scroll position for diffs, stick to anchors harder

Description

When stabilizing document scroll position for diffs, stick to anchors harder

Summary: Ref T12779. Try a little harder to get the autoscroll heuristic right, but also just stick to anchors if the URL has an anchor and the scroll position is near that anchor.

Test Plan:

  • Loaded an anchored diff at a bunch of window sizes, seemed pretty sticky.
  • Added usleep(100000 * mt_rand(1, 15)) to ChangesetViewController to make changesets load slowly and in random order, reloaded a bunch of times while scrolling around, things appeared reasonable.

Reviewers: chad

Reviewed By: chad

Maniphest Tasks: T12779

Differential Revision: https://secure.phabricator.com/D18060

Details

Provenance
epriestleyAuthored on Jun 1 2017, 10:41 AM
themackabuPushed on Mar 25 2025, 8:07 PM
Parents
rPb9a4988df36c: Mark "Settings" and "Nuance" as launchable applications
Branches
Unknown
Tags
Unknown

Event Timeline