Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1fafc67f authored by Winson Chung's avatar Winson Chung Committed by Automerger Merge Worker
Browse files

Merge "Restore single-display check for visible recent task" into rvc-dev am:...

Merge "Restore single-display check for visible recent task" into rvc-dev am: a0d33955 am: d31dac02

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

Change-Id: Ia5ead1fbfb879916b20b0efe154f45c3dbef6430
parents b5ac9bc6 d31dac02
Loading
Loading
Loading
Loading
+11 −0
Original line number Diff line number Diff line
@@ -1341,6 +1341,17 @@ class RecentTasks {
                break;
        }

        // Tasks managed by/associated with an ActivityView should be excluded from recents.
        // singleTaskInstance is set on the VirtualDisplay managed by ActivityView
        // TODO(b/126185105): Find a different signal to use besides isSingleTaskInstance
        final ActivityStack stack = task.getStack();
        if (stack != null) {
            DisplayContent display = stack.getDisplay();
            if (display != null && display.isSingleTaskInstance()) {
                return false;
            }
        }

        // If we're in lock task mode, ignore the root task
        if (task == mService.getLockTaskController().getRootTask()) {
            return false;