Status bar: Forward the disabled state to the status bar process when it comes up.
Bug: 3108996
Change-Id: I92c2ff645dc64ca2610e3de814e0cfef6cde88c3
diff --git a/services/java/com/android/server/StatusBarManagerService.java b/services/java/com/android/server/StatusBarManagerService.java
index 95d2b65..0eeef38 100644
--- a/services/java/com/android/server/StatusBarManagerService.java
+++ b/services/java/com/android/server/StatusBarManagerService.java
@@ -71,9 +71,7 @@
Object mLock = new Object();
// We usually call it lights out mode, but double negatives are annoying
boolean mLightsOn = true;
-
boolean mMenuVisible = false;
-
boolean mIMEButtonVisible = false;
private class DisableRecord implements IBinder.DeathRecipient {
@@ -352,7 +350,7 @@
// ================================================================================
public void registerStatusBar(IStatusBar bar, StatusBarIconList iconList,
List<IBinder> notificationKeys, List<StatusBarNotification> notifications,
- boolean switches[]) {
+ int switches[]) {
enforceStatusBarService();
Slog.i(TAG, "registerStatusBar bar=" + bar);
@@ -367,9 +365,10 @@
}
}
synchronized (mLock) {
- switches[0] = mLightsOn;
- switches[1] = mMenuVisible;
- switches[2] = mIMEButtonVisible;
+ switches[0] = gatherDisableActionsLocked();
+ switches[1] = mLightsOn ? 1 : 0;
+ switches[2] = mMenuVisible ? 1 : 0;
+ switches[3] = mIMEButtonVisible ? 1 : 0;
}
}