Use correct API for badging

Bug: 17414778
Change-Id: Ieb9890751c3071088b9f5aab48053e767f78bfe5
This commit is contained in:
Amith Yamasani
2014-09-07 15:38:09 -07:00
parent b5cc01342e
commit 30c50b15d0
4 changed files with 8 additions and 9 deletions

View File

@@ -212,10 +212,9 @@ public class RecentLocationApps {
final UserHandle userHandle = new UserHandle(userId);
Drawable appIcon = mPackageManager.getApplicationIcon(appInfo);
Drawable icon = mPackageManager.getUserBadgedDrawableForDensity(appIcon, userHandle,
null, 0);
Drawable icon = mPackageManager.getUserBadgedIcon(appIcon, userHandle);
CharSequence appLabel = mPackageManager.getApplicationLabel(appInfo);
CharSequence badgedAppLabel = um.getBadgedLabelForUser(appLabel.toString(), userHandle);
CharSequence badgedAppLabel = mPackageManager.getUserBadgedLabel(appLabel, userHandle);
preference = createRecentLocationEntry(icon,
appLabel, highBattery, badgedAppLabel,
new PackageEntryClickedListener(packageName));