From 84812583030b3799e8a1203b480b78d3825b7adb Mon Sep 17 00:00:00 2001 From: Ricky Wai Date: Tue, 10 May 2016 20:11:59 +0100 Subject: Hide notification before tie managed profile lock We should hide the notification asap before setting managed profile lock, to reduce the time that user is unlocked while the notification is still showing. Bug: 28689675 Change-Id: I289302302e3079726998adefebe2e8b113b2e52a --- services/core/java/com/android/server/LockSettingsService.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/services/core/java/com/android/server/LockSettingsService.java b/services/core/java/com/android/server/LockSettingsService.java index c2a1c50a8d2b..cec32291cb30 100644 --- a/services/core/java/com/android/server/LockSettingsService.java +++ b/services/core/java/com/android/server/LockSettingsService.java @@ -340,8 +340,9 @@ public class LockSettingsService extends ILockSettings.Stub { } public void onUnlockUser(int userId) { - tieManagedProfileLockIfNecessary(userId, null); + // Hide notification first, as tie managed profile lock takes time hideEncryptionNotification(new UserHandle(userId)); + tieManagedProfileLockIfNecessary(userId, null); // Now we have unlocked the parent user we should show notifications // about any profiles that exist. -- cgit v1.2.3-59-g8ed1b