Allow lines to be highlighted on managed service pages.

Test: manual
Change-Id: I4d20b7b146b17dea8bc0ed3957d18394931889a8
Fixes: 72067617
This commit is contained in:
Julia Reynolds
2018-01-17 11:19:14 -05:00
parent 8fe96d100a
commit 5038698a5f
2 changed files with 3 additions and 0 deletions

View File

@@ -137,6 +137,7 @@ public class ZenAccessSettings extends EmptyTextSettings {
final String pkg = app.packageName;
final CharSequence label = app.loadLabel(mPkgMan);
final SwitchPreference pref = new AppSwitchPreference(getPrefContext());
pref.setKey(pkg);
pref.setPersistent(false);
pref.setIcon(app.loadIcon(mPkgMan));
pref.setTitle(label);

View File

@@ -143,8 +143,10 @@ public abstract class ManagedServiceSettings extends EmptyTextSettings {
final boolean enable = (boolean) newValue;
return setEnabled(cn, summary, enable);
});
pref.setKey(cn.flattenToString());
screen.addPreference(pref);
}
highlightPreferenceIfNeeded();
}
private int getCurrentUser(int managedProfileId) {