summaryrefslogtreecommitdiffstats
path: root/packages
diff options
context:
space:
mode:
authorBenjamin Franz <bfranz@google.com>2015-04-29 09:15:20 +0000
committerAndroid Git Automerger <android-git-automerger@android.com>2015-04-29 09:15:20 +0000
commitaf275e157abb8b3add62e5bf1827519820cdf238 (patch)
treec68b9a6e3155b56c2514cc1b3b58a46437371bfe /packages
parent633a45a0d4e095ae81fc2c3e882c23a6513bbaee (diff)
parentc4aa3c781a0ddce64853cd5d88bf97f8a9faf98b (diff)
downloadframeworks_base-af275e157abb8b3add62e5bf1827519820cdf238.zip
frameworks_base-af275e157abb8b3add62e5bf1827519820cdf238.tar.gz
frameworks_base-af275e157abb8b3add62e5bf1827519820cdf238.tar.bz2
am c4aa3c78: Merge "Add status bar flag to disable quick settings" into mnc-dev
* commit 'c4aa3c781a0ddce64853cd5d88bf97f8a9faf98b': Add status bar flag to disable quick settings
Diffstat (limited to 'packages')
-rw-r--r--packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java24
1 files changed, 19 insertions, 5 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java
index b1d48f2..bf27e84 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java
@@ -1293,13 +1293,20 @@ public class PhoneStatusBar extends BaseStatusBar implements DemoMode,
updateClearAll();
updateEmptyShadeView();
- // Disable QS if device not provisioned.
- // If the user switcher is simple then disable QS during setup because
- // the user intends to use the lock screen user switcher, QS in not needed.
+ updateQsExpansionEnabled();
+ mShadeUpdates.check();
+ }
+
+ /**
+ * Disable QS if device not provisioned.
+ * If the user switcher is simple then disable QS during setup because
+ * the user intends to use the lock screen user switcher, QS in not needed.
+ */
+ private void updateQsExpansionEnabled() {
mNotificationPanel.setQsExpansionEnabled(isDeviceProvisioned()
&& (mUserSetup || mUserSwitcherController == null
- || !mUserSwitcherController.isSimpleUserSwitcher()));
- mShadeUpdates.check();
+ || !mUserSwitcherController.isSimpleUserSwitcher())
+ && ((mDisabled2 & StatusBarManager.DISABLE2_QUICK_SETTINGS) == 0));
}
private void updateNotificationShadeForChildren() {
@@ -1732,6 +1739,9 @@ public class PhoneStatusBar extends BaseStatusBar implements DemoMode,
flagdbg.append(((diff1 & StatusBarManager.DISABLE_CLOCK) != 0) ? "* " : " ");
flagdbg.append(((state1 & StatusBarManager.DISABLE_SEARCH) != 0) ? "SEARCH" : "search");
flagdbg.append(((diff1 & StatusBarManager.DISABLE_SEARCH) != 0) ? "* " : " ");
+ flagdbg.append(((state2 & StatusBarManager.DISABLE2_QUICK_SETTINGS) != 0) ? "QUICK_SETTINGS"
+ : "quick_settings");
+ flagdbg.append(((diff2 & StatusBarManager.DISABLE2_QUICK_SETTINGS) != 0) ? "* " : " ");
flagdbg.append(">");
Log.d(TAG, flagdbg.toString());
@@ -1780,6 +1790,10 @@ public class PhoneStatusBar extends BaseStatusBar implements DemoMode,
(state1 & StatusBarManager.DISABLE_NOTIFICATION_ALERTS) != 0;
mHeadsUpObserver.onChange(true);
}
+
+ if ((diff2 & StatusBarManager.DISABLE2_QUICK_SETTINGS) != 0) {
+ updateQsExpansionEnabled();
+ }
}
@Override