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

Commit 51d1d916 authored by Wale Ogunwale's avatar Wale Ogunwale
Browse files

Don't keep dead window with borrowed app token visible

If the window was add by a client using another client's app token,
we don't want to keep the dead window around for this case since
this funcationality is meant for 'real' apps.

Bug: 28467642
Change-Id: Ie4fdd9f90b122439a2fbcc60085ebfdb562d5c6d
parent b5cc6af4
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -1781,6 +1781,12 @@ final class WindowState implements WindowManagerPolicy.WindowState {
            return false;
        }

        if (mAttrs.token != mClient.asBinder()) {
            // The window was add by a client using another client's app token. We don't want to
            // keep the dead window around for this case since this is meant for 'real' apps.
            return false;
        }

        if (mAttrs.type == TYPE_APPLICATION_STARTING) {
            // We don't keep starting windows since they were added by the window manager before
            // the app even launched.