From 61190fb7e7a520481fc06dba55f99fa91a72e9e4 Mon Sep 17 00:00:00 2001 From: Selim Cinek Date: Wed, 7 Dec 2016 12:16:45 -0800 Subject: [PATCH] Don't reset the velocity when flinging down just because of falsing The velocity was reset even if the direction was correct. Test: collapse on the lockscreen and then fling down, observe no jitter Bug: 32437839 Change-Id: I92454a1bb3d8156c8c3c537b266d061b16c82c7b --- .../src/com/android/systemui/statusbar/phone/PanelView.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PanelView.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PanelView.java index 570d5d40064f4..83bae11b70ffc 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PanelView.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PanelView.java @@ -685,7 +685,7 @@ public abstract class PanelView extends FrameLayout { mOverExpandedBeforeFling = getOverExpansionAmount() > 0f; ValueAnimator animator = createHeightAnimator(target); if (expand) { - if (expandBecauseOfFalsing) { + if (expandBecauseOfFalsing && vel < 0) { vel = 0; } mFlingAnimationUtils.apply(animator, mExpandedHeight, target, vel, getHeight());