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

Commit 2786203f authored by wilsonshih's avatar wilsonshih
Browse files

Search existing starting window activity in showStartingWindow

Always search for existing starting window in a task when calling
showStartingWindow, so there can transfer the existing starting window
without request a new one from shell.

Bug: 295838775
Test: presubmit
Change-Id: I1e42810ffe28b719d5872cdfb8aa328a881d122a
parent 8880dfea
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -7258,8 +7258,10 @@ final class ActivityRecord extends WindowToken implements WindowManagerService.A
    }

    void showStartingWindow(boolean taskSwitch) {
        showStartingWindow(null /* prev */, false /* newTask */, taskSwitch,
                false /* startActivity */, null);
        // Pass the activity which contains starting window already.
        final ActivityRecord prev = task.getActivity(
                a -> a != this && a.mStartingData != null && a.showToCurrentUser());
        showStartingWindow(prev, false /* newTask */, taskSwitch, false /* startActivity */, null);
    }

    /**