Cancel ongoing PIP animations in onTaskVanished
onTaskVanished may be called when an activity is moved to
the back while a resize animation is still in progress.
This causes a race between the windowing mode change to
fullscreen and the PIP resize that results in the
fullscreen task leash getting a PIP-sized crop.
This change cancels any ongoing animations in
onTaskVanished and makes sure that finishResize() is not
called when the animation is canceled because the transition
to fullscreen will handle the final resize and cropping.
Bug: 188856244
Test: enter YT PIP, click the next button and the music
button quickly after that, then re-open YT from the
notification - verify the activity is fullscreen and is
cropped correctly.
Change-Id: Ide52b8c6b63205081bde96472a5e0589664e1c8a
1 file changed