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

Commit 9249b8dc authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "don't call the reparent method when the old parent of task is removed."...

Merge "don't call the reparent method when the old parent of task is removed." into main am: 8ce3a826

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



Change-Id: Ic2cc097689bd1aa2ffecc2625048c5bfd97dde67
Signed-off-by: default avatarAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
parents d3cb6900 8ce3a826
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -1655,6 +1655,12 @@ public class ActivityTaskSupervisor implements RecentTasks.Callbacks {
        activityIdleInternal(null /* idleActivity */, false /* fromTimeout */,
                true /* processPausingActivities */, null /* configuration */);

        if (rootTask.getParent() == null) {
            // The activities in the task may already be finishing. Then the task could be removed
            // when performing the idle check.
            return;
        }

        // Reparent all the tasks to the bottom of the display
        final DisplayContent toDisplay =
                mRootWindowContainer.getDisplayContent(DEFAULT_DISPLAY);