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

Commit 66ed4c63 authored by Chong Zhang's avatar Chong Zhang
Browse files

Fix lost window warning

Mark activity window as invisible with window manager when it's
destroyed normally, to differentiate with the case where the app
crashed while visible.

bug: 25671369

Change-Id: I26d8df6b7e08fc5b65cd2c7aa432a3c5c8c5c7b3
parent c6a2da07
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -3103,6 +3103,9 @@ final class ActivityStack {
            // If the activity is PAUSING, we will complete the finish once
            // it is done pausing; else we can just directly finish it here.
            if (DEBUG_PAUSE) Slog.v(TAG_PAUSE, "Finish not pausing: " + r);
            if (r.visible) {
                mWindowManager.setAppVisibility(r.appToken, false);
            }
            return finishCurrentActivityLocked(r, FINISH_AFTER_PAUSE, oomAdj) == null;
        } else {
            if (DEBUG_PAUSE) Slog.v(TAG_PAUSE, "Finish waiting for pause of: " + r);