From 57454878918522229b0e42485d83856d36925a20 Mon Sep 17 00:00:00 2001 From: Daniel U Date: Tue, 29 Mar 2016 20:28:21 +0100 Subject: [PATCH] Refresh cached user array upon lockscreen settings changed Clear the entire array storing which users allow notifications to be shown on the lockscreen. This is because we don't know which user changed the lockscreen settings. Update all notifications afterwards to fill the array again. BUG:27118634 Change-Id: Ic4f1a8de75824cd902841867b2a9bf482fd5dd7c --- .../src/com/android/systemui/statusbar/BaseStatusBar.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java b/packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java index 1c5d28aaf27bc..2acaca109f26e 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java @@ -276,9 +276,10 @@ public abstract class BaseStatusBar extends SystemUI implements private final ContentObserver mLockscreenSettingsObserver = new ContentObserver(mHandler) { @Override public void onChange(boolean selfChange) { - // We don't know which user changed LOCK_SCREEN_ALLOW_PRIVATE_NOTIFICATIONS, - // so we just dump our cache ... + // We don't know which user changed LOCK_SCREEN_ALLOW_PRIVATE_NOTIFICATIONS or + // LOCK_SCREEN_SHOW_NOTIFICATIONS, so we just dump our cache ... mUsersAllowingPrivateNotifications.clear(); + mUsersAllowingNotifications.clear(); // ... and refresh all the notifications updateNotifications(); }