Merge "Shift focus when a task with multiple activities gets removed" into tm-qpr-dev am: d012ff2d14
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/20290966 Change-Id: I0429a53d5c00265082ec47bf2cf6751bfd00570a Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -1604,6 +1604,11 @@ class Task extends TaskFragment {
|
|||||||
removeChild(r, reason);
|
removeChild(r, reason);
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
|
// Finish or destroy apps from the bottom to ensure that all the other activity have
|
||||||
|
// been finished and the top task in another task gets resumed when a top activity is
|
||||||
|
// removed. Otherwise, shell transitions wouldn't run because there would be no event
|
||||||
|
// that sets the transition ready.
|
||||||
|
final boolean traverseTopToBottom = !mTransitionController.isShellTransitionsEnabled();
|
||||||
forAllActivities((r) -> {
|
forAllActivities((r) -> {
|
||||||
if (r.finishing || (excludingTaskOverlay && r.isTaskOverlay())) {
|
if (r.finishing || (excludingTaskOverlay && r.isTaskOverlay())) {
|
||||||
return;
|
return;
|
||||||
@@ -1617,7 +1622,7 @@ class Task extends TaskFragment {
|
|||||||
} else {
|
} else {
|
||||||
r.destroyIfPossible(reason);
|
r.destroyIfPossible(reason);
|
||||||
}
|
}
|
||||||
});
|
}, traverseTopToBottom);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user