Merge "Snapshot 2 tasks when swipe up split case" into tm-qpr-dev am: c33c69c1c3

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

Change-Id: I974373c26c8e48283287ea4954e08ee4b74959d1
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
Tony Huang
2022-10-25 06:17:56 +00:00
committed by Automerger Merge Worker

View File

@@ -1834,6 +1834,17 @@ public abstract class AbsSwipeUpHandler<T extends StatefulActivity<S>,
if (mRecentsAnimationController == null) return;
final ThumbnailData taskSnapshot =
mRecentsAnimationController.screenshotTask(runningTaskId);
// If split case, we should update all split tasks snapshot
if (mIsSwipeForSplit) {
int[] splitTaskIds = TopTaskTracker.INSTANCE.get(
mContext).getRunningSplitTaskIds();
for (int i = 0; i < splitTaskIds.length; i++) {
// Skip running one because done above.
if (splitTaskIds[i] == runningTaskId) continue;
mRecentsAnimationController.screenshotTask(splitTaskIds[i]);
}
}
MAIN_EXECUTOR.execute(() -> {
mTaskSnapshot = taskSnapshot;
if (!updateThumbnail(runningTaskId, false /* refreshView */)) {