Merge "Make sure tasks below home task is invisible while in split" into sc-dev am: 52e3d9a45e

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14328763

Change-Id: I213873a6abce47dd01500306bfbbf9396bba1ddc
This commit is contained in:
Jerry Chang
2021-05-03 16:01:06 +00:00
committed by Automerger Merge Worker

View File

@@ -4315,11 +4315,21 @@ class Task extends WindowContainer<WindowContainer> {
// the screen are opaque. // the screen are opaque.
return TASK_VISIBILITY_INVISIBLE; return TASK_VISIBILITY_INVISIBLE;
} }
if (isAssistantType && gotRootSplitScreenTask) { if (gotRootSplitScreenTask) {
// Assistant stack can't be visible behind split-screen. In addition to this not if (isAssistantType) {
// making sense, it also works around an issue here we boost the z-order of the // Assistant stack can't be visible behind split-screen. In addition to this not
// assistant window surfaces in window manager whenever it is visible. // making sense, it also works around an issue here we boost the z-order of the
return TASK_VISIBILITY_INVISIBLE; // assistant window surfaces in window manager whenever it is visible.
return TASK_VISIBILITY_INVISIBLE;
}
if (other.isHomeOrRecentsRootTask()) {
// While in split mode, home task will be reparented to the secondary split and
// leaving tasks not supporting split below. Due to
// TaskDisplayArea#assignRootTaskOrdering always adjusts home surface layer to
// the bottom, this makes sure those tasks below home is invisible and won't
// occlude home task unexpectedly.
return TASK_VISIBILITY_INVISIBLE;
}
} }
if (other.mAdjacentTask != null) { if (other.mAdjacentTask != null) {
if (adjacentTasks.contains(other.mAdjacentTask)) { if (adjacentTasks.contains(other.mAdjacentTask)) {