Add catch for missing app icon resource.

The catch was present before moving the code into
the compat class.

Bug: 15276879
Change-Id: I81fbd49dacd813e861a2bc4f0b41dcbeccb9def2
(cherry picked from commit c879052247)
This commit is contained in:
Kenny Guy
2014-05-27 16:34:59 +01:00
committed by Adam Cohen
parent 6ea3b116fc
commit 958315e8ef
@@ -61,7 +61,11 @@ public class LauncherActivityInfoCompatV16 extends LauncherActivityInfoCompat {
resources = null;
}
if (resources != null) {
d = resources.getDrawableForDensity(mActivityInfo.getIconResource(), density);
try {
d = resources.getDrawableForDensity(mActivityInfo.getIconResource(), density);
} catch (Resources.NotFoundException e) {
// Return default icon below.
}
}
}
if (d == null) {