Two Taskbar Bug

This cl fixes two taskbar bug being present when invoking CtS.

Solution: simply measure displacement and compare that with slop to animate taksbar background or not.

Test: Presubmit
Bug: 360116669
Flag: EXEMPT Bug Fix
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:7cada7c46b0462bc56d2dc363d61e8967a42001f)
Merged-In: I7d5a95e1a3729e30e5cf588dcf5b823f3d7de93f
Change-Id: I7d5a95e1a3729e30e5cf588dcf5b823f3d7de93f
diff --git a/quickstep/src/com/android/quickstep/inputconsumers/TaskbarUnstashInputConsumer.java b/quickstep/src/com/android/quickstep/inputconsumers/TaskbarUnstashInputConsumer.java
index 5ad55ae..49bff8d 100644
--- a/quickstep/src/com/android/quickstep/inputconsumers/TaskbarUnstashInputConsumer.java
+++ b/quickstep/src/com/android/quickstep/inputconsumers/TaskbarUnstashInputConsumer.java
@@ -228,10 +228,13 @@
         }
 
         float velocityYPxPerS = mVelocityTracker.getYVelocity();
+        float dY = Math.abs(mLastPos.y - mDownPos.y);
         if (mCanPlayTaskbarBgAlphaAnimation
                 && mMotionMoveCount >= NUM_MOTION_MOVE_THRESHOLD // Arbitrary value
                 && velocityYPxPerS != 0 // Ignore these
-                && velocityYPxPerS >= mTaskbarSlowVelocityYThreshold) {
+                && velocityYPxPerS >= mTaskbarSlowVelocityYThreshold
+                && dY != 0
+                && dY > mTouchSlop) {
             mTaskbarActivityContext.playTaskbarBackgroundAlphaAnimation();
             mCanPlayTaskbarBgAlphaAnimation = false;
         }