WebUI Tab Strip: Reset swipe animation on pointerdown
If a swipe gesture gets canceled by a pointerleave event, the animation needs to be reset. If it is not reset, the next pointerup event will calculate the pixels swiped and the velocity based on an animation time from a previous gesture. This occurs most frequently in cases where a user is swiping diagonally on the tab strip to scroll. The diagonal swipe causes the TabSwiper to map a few of the first initial pixels as a tab swipe, which gets canceled by a pointerleave event caused by the scroll. The next time the user taps on a TabElement, the pointerup event will do its calcs based on the previous diagonal swipe since the animation remains in a state modified by the diagonal swipe. Bug: 1014679 Change-Id: I5ef44578f104152793af4c4750e4a493d7d908b3 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1913572Reviewed-by:Demetrios Papadopoulos <dpapad@chromium.org> Commit-Queue: John Lee <johntlee@chromium.org> Cr-Commit-Position: refs/heads/master@{#715128}
Showing
Please register or sign in to comment