summaryrefslogtreecommitdiffstats
path: root/packages/SystemUI
diff options
context:
space:
mode:
authorAdrian Roos <roosa@google.com>2014-11-21 13:55:09 +0100
committerAdrian Roos <roosa@google.com>2014-11-21 13:55:09 +0100
commit31b844ba0cf418b758fbe45023d0202f208c0191 (patch)
tree5de82d25bb1d772b37b4a9311a900f6fc8e5027c /packages/SystemUI
parent0653f508b58eab994089ae2da783852a5c1b4a8a (diff)
downloadframeworks_base-31b844ba0cf418b758fbe45023d0202f208c0191.zip
frameworks_base-31b844ba0cf418b758fbe45023d0202f208c0191.tar.gz
frameworks_base-31b844ba0cf418b758fbe45023d0202f208c0191.tar.bz2
Explicitly specify user for public mode
Bug: 18417850 Change-Id: I9d564a47fe66cb8035d73c8a2eedb912920410a2
Diffstat (limited to 'packages/SystemUI')
-rw-r--r--packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java3
-rw-r--r--packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarKeyguardViewManager.java4
2 files changed, 6 insertions, 1 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 3fca56d..daabcbd 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java
@@ -3183,6 +3183,7 @@ public class PhoneStatusBar extends BaseStatusBar implements DemoMode,
public void userSwitched(int newUserId) {
if (MULTIUSER_DEBUG) mNotificationPanelDebugText.setText("USER " + newUserId);
animateCollapsePanels();
+ updatePublicMode();
updateNotifications();
resetUserSetupObserver();
setControllerUsers();
@@ -3674,7 +3675,7 @@ public class PhoneStatusBar extends BaseStatusBar implements DemoMode,
private void updatePublicMode() {
setLockscreenPublicMode(mStatusBarKeyguardViewManager.isShowing()
- && mStatusBarKeyguardViewManager.isSecure());
+ && mStatusBarKeyguardViewManager.isSecure(mCurrentUserId));
}
private void updateKeyguardState(boolean goingToFullShade, boolean fromShadeLocked) {
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarKeyguardViewManager.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarKeyguardViewManager.java
index 65d231e..cec1559 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarKeyguardViewManager.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarKeyguardViewManager.java
@@ -426,4 +426,8 @@ public class StatusBarKeyguardViewManager {
public boolean isGoingToNotificationShade() {
return mPhoneStatusBar.isGoingToNotificationShade();
}
+
+ public boolean isSecure(int userId) {
+ return mBouncer.isSecure() || mLockPatternUtils.isSecure(userId);
+ }
}