Fix some issues with shelf jumping/duration
Don't use OvershootParams for 0 button mode, since that interpolator assumes the shelf is moving in conjunction with recents/app window. Instead, use OVERSHOOT_1_2 like we do when not flinging. Also bound the duration when entering recents, since scroller duration could be 750ms if we are snapping to the current page. Now we cap at MAX_SWIPE_DURATION (350ms). This case is most likely to be hit when ending a slow swipe near the final recents scale, since in that case duration is close to 0 and the scroller duration is taken instead. Test: - Artificially always detect a pause, fling up in 0 button mode; ensure shelf doesn't jump - Either with the above artifical change in 0 button, or 2 button mode, end a swipe to recents near its final scale with a slight scroll to the right; ensure duration is 350 instead of 750 Bug: 132283018 Bug: 127783075 Change-Id: I8d5fbd0b30af21b9587fba47d141ba90b3b6e778
Loading
Please register or sign in to comment