Use correct API for badging
Bug: 17414778 Change-Id: Ieb9890751c3071088b9f5aab48053e767f78bfe5
This commit is contained in:
@@ -215,8 +215,8 @@ public class ChooseAccountActivity extends PreferenceActivity {
|
||||
try {
|
||||
AuthenticatorDescription desc = mTypeToAuthDescription.get(accountType);
|
||||
Context authContext = createPackageContextAsUser(desc.packageName, 0, mUserHandle);
|
||||
icon = getPackageManager().getUserBadgedDrawableForDensity(
|
||||
authContext.getResources().getDrawable(desc.iconId), mUserHandle, null, 0);
|
||||
icon = getPackageManager().getUserBadgedIcon(
|
||||
authContext.getResources().getDrawable(desc.iconId), mUserHandle);
|
||||
} catch (PackageManager.NameNotFoundException e) {
|
||||
// TODO: place holder icon for missing account icons?
|
||||
Log.w(TAG, "No icon name for account type " + accountType);
|
||||
|
Reference in New Issue
Block a user