Display channel/group names only.

Test: manual
Change-Id: I7da68f71ddb78f3150ebc64af40310de65cd010c
This commit is contained in:
Julia Reynolds
2017-03-13 15:06:28 -04:00
parent 8ba1bf34b4
commit 2194f3db37
3 changed files with 8 additions and 29 deletions

View File

@@ -251,25 +251,4 @@ abstract public class NotificationSettingsBase extends SettingsPreferenceFragmen
return getContext().getString(R.string.notification_importance_high);
}
}
protected CharSequence getNotificationGroupLabel(NotificationChannelGroup group) {
return getLabel(group.getName(), group.getNameResId());
}
protected CharSequence getNotificationChannelLabel(NotificationChannel channel) {
return getLabel(channel.getName(), channel.getNameResId());
}
private CharSequence getLabel(CharSequence name, int nameResId) {
if (!TextUtils.isEmpty(name)) {
return name;
}
try {
ApplicationInfo info = mPm.getApplicationInfoAsUser(mAppRow.pkg, 0, mAppRow.userId);
return mPm.getText(mAppRow.pkg, nameResId, info);
} catch (NameNotFoundException e) {
e.printStackTrace();
}
return null;
}
}