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

Commit 0d73a37c authored by Evan Rosky's avatar Evan Rosky
Browse files

Remove unmatched mUserLeaving setting

mUserLeaving is intended to "wrap" a synchronous call (in that
we set to true, do something, set to false). However, this one
spot is setting it to true without unsetting it which is causing
later non-userleaving actions to incorrectly send userleaving
to apps at the wrong times.

Bug: 334038395
Test: mix enter/exit pip + screen off/on repeatedly
Change-Id: I4700faeab4a390e0343513aa4e4adb44dde6f1d9
parent 9a58057c
Loading
Loading
Loading
Loading
+0 −8
Original line number Diff line number Diff line
@@ -4748,14 +4748,6 @@ class Task extends TaskFragment {
            // transferring the transform on the leash to the task, reset this state once we're
            // moving out of pip
            setCanAffectSystemUiFlags(true);
            // Turn on userLeaveHint so other app can enter PiP mode.
            mTaskSupervisor.mUserLeaving = true;
            // Allow entering PiP from current top most activity when we are leaving PiP.
            final Task topFocused = mRootWindowContainer.getTopDisplayFocusedRootTask();
            if (topFocused != null) {
                final ActivityRecord ar = topFocused.getTopResumedActivity();
                enableEnterPipOnTaskSwitch(ar, null /* toFrontTask */, ar, null /* opts */);
            }
            mRootWindowContainer.notifyActivityPipModeChanged(this, null);
        }
        if (likelyResolvedMode == WINDOWING_MODE_PINNED) {