Fix Pair-to-Pair animation being canceled in recents transition handler.

The recents animation should be canceled when leaft task changed(e.g.
expand Pip), so there should ignore structural change from non-leaf
tasks.

Bug: 286024881
Test: Put app in Pip, open another app, go to recents, expand pip
Test: Verify animation won't break when playing Pair-to-Pair switch.
Test: Do above tests with 3p Launcher.
Change-Id: I5d0f2c5750d0cad3887ed95f268cb42bd5961fdb
This commit is contained in:
wilsonshih
2023-06-06 10:27:45 +00:00
committed by Wei Sheng Shih
parent 5831c74c4c
commit d4809c6ccb

View File

@@ -595,8 +595,8 @@ public class RecentsTransitionHandler implements Transitions.TransitionHandler {
cancel(mWillFinishToHome, true /* withScreenshots */, "display change");
return;
}
// Don't consider order-only changes as changing apps.
if (!TransitionUtil.isOrderOnly(change)) {
// Don't consider order-only & non-leaf changes as changing apps.
if (!TransitionUtil.isOrderOnly(change) && isLeafTask) {
hasChangingApp = true;
}
}