feedv2: Fix scroll restore
Scroll restore didn't work when: - the feed is being restored in async, so scrolling must happen later, - And the item at the top of the NTP was a header, present before the feed is loaded. This CL stores the last visible item index in the scroll state, and waits until the right number of items are added to the recycler adapter. Bug: 1115488 Change-Id: Iac489572da73659261231a002e2c2a66591234af Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2360311Reviewed-by:Cathy Li <chili@chromium.org> Commit-Queue: Cathy Li <chili@chromium.org> Auto-Submit: Dan H <harringtond@chromium.org> Cr-Commit-Position: refs/heads/master@{#798871}
Showing
Please register or sign in to comment