Fix setLaunchBehind target being stop while back gesture animating

The home activity will addToStopping when launching another app, if
the back gesture start before home activity stopped, it can still being
stopped and become invisible even set mLaunchTaskBehind = true.

Bug: 131727607
Test: launch an app, and start back gesture before home activity stopped,
monitor the home activity won't become invisible.

Change-Id: I189bc31a5dc55c91c48a1dc81e1336aa580e90c6
This commit is contained in:
wilsonshih
2022-10-19 18:54:41 +08:00
parent c83021b863
commit 8c47781511

View File

@@ -588,6 +588,7 @@ class BackNavigationController {
ProtoLog.d(WM_DEBUG_BACK_PREVIEW,
"Setting Activity.mLauncherTaskBehind to true. Activity=%s", activity);
activity.mTaskSupervisor.mStoppingActivities.remove(activity);
activity.getDisplayContent().ensureActivitiesVisible(null /* starting */,
0 /* configChanges */, false /* preserveWindows */, true);
}