From 999c4022c408e2a3c6c37fa3a47d09a6eec282fc Mon Sep 17 00:00:00 2001 From: LuK1337 Date: Mon, 28 Sep 2015 17:44:40 +0200 Subject: ProfileGroupConfig: Use CMSDK profile manager * Should fix the NPE on 145th line Change-Id: Icfbb961a4f562d977bf14fbfa603c7bb11d2cdca --- src/com/android/settings/profiles/ProfileGroupConfig.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'src/com/android/settings/profiles') diff --git a/src/com/android/settings/profiles/ProfileGroupConfig.java b/src/com/android/settings/profiles/ProfileGroupConfig.java index 9219967..cd37487 100644 --- a/src/com/android/settings/profiles/ProfileGroupConfig.java +++ b/src/com/android/settings/profiles/ProfileGroupConfig.java @@ -35,8 +35,6 @@ import com.android.settings.SettingsPreferenceFragment; public class ProfileGroupConfig extends SettingsPreferenceFragment implements OnPreferenceChangeListener { - public static final String PROFILE_SERVICE = "profile"; - private static final CharSequence KEY_SOUNDMODE = "sound_mode"; private static final CharSequence KEY_VIBRATEMODE = "vibrate_mode"; @@ -83,7 +81,7 @@ public class ProfileGroupConfig extends SettingsPreferenceFragment implements mProfile = (Profile) args.getParcelable("Profile"); UUID uuid = UUID.fromString(args.getString("ProfileGroup")); - mProfileManager = (ProfileManager) getSystemService(PROFILE_SERVICE); + mProfileManager = ProfileManager.getInstance(getActivity()); mProfileGroup = mProfile.getProfileGroup(uuid); mRingerMode = (ListPreference) findPreference(KEY_RINGERMODE); -- cgit v1.1