diff --git a/quickstep/recents_ui_overrides/src/com/android/quickstep/WindowTransformSwipeHandler.java b/quickstep/recents_ui_overrides/src/com/android/quickstep/WindowTransformSwipeHandler.java index f1d1141bcd..af18bbf80c 100644 --- a/quickstep/recents_ui_overrides/src/com/android/quickstep/WindowTransformSwipeHandler.java +++ b/quickstep/recents_ui_overrides/src/com/android/quickstep/WindowTransformSwipeHandler.java @@ -1132,17 +1132,16 @@ public class WindowTransformSwipeHandler } if (start == end || duration <= 0) { mLauncherTransitionController.dispatchSetInterpolator(t -> end); - mLauncherTransitionController.getAnimationPlayer().end(); } else { mLauncherTransitionController.dispatchSetInterpolator(adjustedInterpolator); mAnimationFactory.adjustActivityControllerInterpolators(); - mLauncherTransitionController.getAnimationPlayer().setDuration(duration); - - if (QUICKSTEP_SPRINGS.get()) { - mLauncherTransitionController.dispatchOnStartWithVelocity(end, velocityPxPerMs.y); - } - mLauncherTransitionController.getAnimationPlayer().start(); } + mLauncherTransitionController.getAnimationPlayer().setDuration(Math.max(0, duration)); + + if (QUICKSTEP_SPRINGS.get()) { + mLauncherTransitionController.dispatchOnStartWithVelocity(end, velocityPxPerMs.y); + } + mLauncherTransitionController.getAnimationPlayer().start(); mHasLauncherTransitionControllerStarted = true; }