mirror of
https://github.com/M66B/NetGuard.git
synced 2024-12-28 10:51:14 +00:00
Show default icon in access log for root/mediaserver/unknown packages
This commit is contained in:
parent
56421a954f
commit
719094d103
1 changed files with 1 additions and 3 deletions
|
@ -192,9 +192,7 @@ public class LogAdapter extends CursorAdapter {
|
|||
info = pm.getApplicationInfo(pkg[0], 0);
|
||||
} catch (PackageManager.NameNotFoundException ignored) {
|
||||
}
|
||||
if (info == null)
|
||||
ivIcon.setImageDrawable(null);
|
||||
else if (info.icon == 0)
|
||||
if (info == null || info.icon == 0)
|
||||
Picasso.with(context).load(android.R.drawable.sym_def_app_icon).into(ivIcon);
|
||||
else {
|
||||
Uri uri = Uri.parse("android.resource://" + info.packageName + "/" + info.icon);
|
||||
|
|
Loading…
Reference in a new issue