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

Commit 08d0cbcd authored by Ankit Shetgaonkar's avatar Ankit Shetgaonkar
Browse files

Call adjustStatusBarLocked on UserSwitchComplete

Some race conditions in UserSwitch and previous calls to ajdustStatusBar might cause
StatusBarManagerService to receive incorrect last known state for the
current user. Calling adjustStatusBarLocked on UserSwitchComplete
ensures the current state is relayed, and since this funciton is
idempotent recalling the function should be harmless.

Bug: 431821706
Bug: 439645242
Test: Manual
Flag: EXEMPT bugFix
Change-Id: I09d2b42bca520ddd76c2ef65c8610d421575c0c9
parent 5e25f4d6
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -724,6 +724,10 @@ public class KeyguardViewMediator implements CoreStartable,
            mHandler.postDelayed(() -> dismiss(null /* callback */, null /* message */),
                    mDismissToken, 500);
        }
        // We need to adjust the status bar in case there are race conditions where the
        // previous adjust event was sent before the user switch completed.
        Log.d(TAG, String.format("onUserSwitchComplete, adjustStatusBarLocked  %d", userId));
        adjustStatusBarLocked();
    }

    KeyguardUpdateMonitorCallback mUpdateCallback = new KeyguardUpdateMonitorCallback() {