summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Victor Chang <vichang@google.com> 2016-05-23 18:42:08 +0000
committer Android (Google) Code Review <android-gerrit@google.com> 2016-05-23 18:42:09 +0000
commit7c527bf76dcdcda414f10ed829999310f46161e7 (patch)
treeff413692e75c5b91b6bb704f9945574c9828de60
parent80c18bcc3a52dee62eec4b95de1ebfbf3c7d397f (diff)
parent12753ded44813a77a4cad5114d34345bec7b21ef (diff)
Merge "Fix Certificate authority installed notification is gone when turning off and on the work mode." into nyc-dev
-rw-r--r--services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java b/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
index a5eb0b217d1f..c1913decde16 100644
--- a/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
+++ b/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
@@ -484,7 +484,8 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub {
}
});
}
- if (Intent.ACTION_BOOT_COMPLETED.equals(action)
+ if (Intent.ACTION_USER_UNLOCKED.equals(action)
+ || Intent.ACTION_USER_STARTED.equals(action)
|| KeyChain.ACTION_STORAGE_CHANGED.equals(action)) {
int userId = intent.getIntExtra(Intent.EXTRA_USER_HANDLE, UserHandle.USER_ALL);
new MonitoringCertNotificationTask().execute(userId);
@@ -1582,6 +1583,7 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub {
filter.addAction(Intent.ACTION_USER_ADDED);
filter.addAction(Intent.ACTION_USER_REMOVED);
filter.addAction(Intent.ACTION_USER_STARTED);
+ filter.addAction(Intent.ACTION_USER_UNLOCKED);
filter.addAction(KeyChain.ACTION_STORAGE_CHANGED);
filter.setPriority(IntentFilter.SYSTEM_HIGH_PRIORITY);
mContext.registerReceiverAsUser(mReceiver, UserHandle.ALL, filter, null, mHandler);