diff options
author | Rubin Xu <rubinxu@google.com> | 2016-04-04 17:23:46 +0100 |
---|---|---|
committer | Rubin Xu <rubinxu@google.com> | 2016-04-04 17:24:30 +0100 |
commit | 819f78e91b6d22dd260480622b10d23f367cae41 (patch) | |
tree | 4ed5862babfcc4d7a95f5c597d2057a1c328d08b /src/com/android/settings/TrustedCredentialsSettings.java | |
parent | 9069181c847168896c6fac97e8869944c97f0f2e (diff) | |
download | packages_apps_Settings-819f78e91b6d22dd260480622b10d23f367cae41.tar.gz packages_apps_Settings-819f78e91b6d22dd260480622b10d23f367cae41.tar.bz2 packages_apps_Settings-819f78e91b6d22dd260480622b10d23f367cae41.zip |
Listen on new broadcasts for profile changes.
The change is due to API review comments on the platform side.
Bug: 27532254
Change-Id: Iacb87f97148ceead6bf1f1cc7a0671711698b061
Diffstat (limited to 'src/com/android/settings/TrustedCredentialsSettings.java')
-rw-r--r-- | src/com/android/settings/TrustedCredentialsSettings.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/com/android/settings/TrustedCredentialsSettings.java b/src/com/android/settings/TrustedCredentialsSettings.java index e1f0109105..2b73c3ea16 100644 --- a/src/com/android/settings/TrustedCredentialsSettings.java +++ b/src/com/android/settings/TrustedCredentialsSettings.java @@ -185,7 +185,8 @@ public class TrustedCredentialsSettings extends OptionsMenuFragment { @Override public void onReceive(Context context, Intent intent) { final String action = intent.getAction(); - if (Intent.ACTION_MANAGED_PROFILE_AVAILABILITY_CHANGED.equals(action) || + if (Intent.ACTION_MANAGED_PROFILE_AVAILABLE.equals(action) || + Intent.ACTION_MANAGED_PROFILE_UNAVAILABLE.equals(action) || Intent.ACTION_MANAGED_PROFILE_UNLOCKED.equals(action)) { // Reload all alias final ExpandableListView systemView = (ExpandableListView) mTabHost @@ -212,7 +213,8 @@ public class TrustedCredentialsSettings extends OptionsMenuFragment { mKeyguardManager = (KeyguardManager) getActivity() .getSystemService(Context.KEYGUARD_SERVICE); IntentFilter filter = new IntentFilter(); - filter.addAction(Intent.ACTION_MANAGED_PROFILE_AVAILABILITY_CHANGED); + filter.addAction(Intent.ACTION_MANAGED_PROFILE_AVAILABLE); + filter.addAction(Intent.ACTION_MANAGED_PROFILE_UNAVAILABLE); filter.addAction(Intent.ACTION_MANAGED_PROFILE_UNLOCKED); getActivity().registerReceiver(mWorkProfileChangedReceiver, filter); } |