Skip to content
This repository has been archived by the owner on Nov 9, 2018. It is now read-only.

Commit

Permalink
Render consume bubble icons if we only have a packageName. Fixes #576.
Browse files Browse the repository at this point in the history
  • Loading branch information
KevinGrandon committed Oct 16, 2015
1 parent 8368405 commit 1607f24
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -640,6 +640,11 @@ public Drawable getConsumeBubbleIcon(Constant.BubbleAction action, boolean white
}
ComponentName componentName = new ComponentName(packageName, name);
return packageManager.getActivityIcon(componentName);
} else if(packageName != null) {
// Try rendering the icon if we only have a packageName.
ApplicationInfo app = packageManager.getApplicationInfo(packageName, 0);
Drawable icon = packageManager.getApplicationIcon(app);
return icon;
}
} catch (OutOfMemoryError ex) {
} catch (PackageManager.NameNotFoundException e) {
Expand Down

0 comments on commit 1607f24

Please sign in to comment.