Merge "Cancel ongoing PIP animations in onTaskVanished" into sc-dev

This commit is contained in:
Jorge Gil
2021-06-30 14:27:18 +00:00
committed by Android (Google) Code Review

View File

@@ -722,6 +722,14 @@ public class PipTaskOrganizer implements ShellTaskOrganizer.TaskListener,
if (info.displayId != Display.DEFAULT_DISPLAY && mOnDisplayIdChangeCallback != null) { if (info.displayId != Display.DEFAULT_DISPLAY && mOnDisplayIdChangeCallback != null) {
mOnDisplayIdChangeCallback.accept(Display.DEFAULT_DISPLAY); mOnDisplayIdChangeCallback.accept(Display.DEFAULT_DISPLAY);
} }
final PipAnimationController.PipTransitionAnimator animator =
mPipAnimationController.getCurrentAnimator();
if (animator != null) {
animator.removeAllUpdateListeners();
animator.removeAllListeners();
animator.cancel();
}
} }
@Override @Override