Scroll fragments when manual restoration is set
The linked bug occurs, for both text and element fragments, because we try to avoid scrolling to fragments when the scroll offset will be restored by history. Manual scroll restoration is a web API that allows the page to override the scroll restoration, we treat it separately but want to avoid scrolling the fragment in this case too. However, the special case for manual restoration was missing a check that the navigation was actually a history navigation. Without this check, an ordinary (non-history) page load that sets manual restoration before the fragment is invoked will prevent it from scrolling. Bug: 1147568 Change-Id: I83e1a3cc12e9f40243c42ee21c52fef2acb36993 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2533149Reviewed-by:Nick Burris <nburris@chromium.org> Commit-Queue: David Bokan <bokan@chromium.org> Cr-Commit-Position: refs/heads/master@{#827023}
Showing
Please register or sign in to comment