Merge "Switch to screenshot when finishing recents animation for split select" into tm-qpr-dev am: 7fb1336de7

Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/20364924

Change-Id: I48dc3166018934e249eea473aab3b459819cdeb4
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
Vinit Nayak
2022-11-03 23:41:42 +00:00
committed by Automerger Merge Worker

View File

@@ -2900,6 +2900,19 @@ public abstract class RecentsView<ACTIVITY_TYPE extends StatefulActivity<STATE_T
InteractionJankMonitorWrapper.begin(this,
InteractionJankMonitorWrapper.CUJ_SPLIT_SCREEN_ENTER, "First tile selected");
anim.addListener(new AnimatorListenerAdapter() {
@Override
public void onAnimationStart(Animator animation) {
if (mSplitHiddenTaskView == getRunningTaskView()) {
finishRecentsAnimation(true /* toRecents */, false /* shouldPip */,
null /* onFinishComplete */);
} else {
switchToScreenshot(
() -> finishRecentsAnimation(true /* toRecents */,
false /* shouldPip */, null /* onFinishComplete */));
}
}
});
anim.addEndListener(success -> {
if (success) {
InteractionJankMonitorWrapper.end(
@@ -4190,8 +4203,6 @@ public abstract class RecentsView<ACTIVITY_TYPE extends StatefulActivity<STATE_T
mSplitSelectStateController.setInitialTaskSelect(taskView.getTask(),
stagePosition, splitEvent, taskView.getItemInfo());
mSplitHiddenTaskViewIndex = indexOfChild(taskView);
finishRecentsAnimation(true /* toRecents */, false /* shouldPip */,
null /* onFinishComplete */);
}
/**