diff --git a/CHANGELOG.md b/CHANGELOG.md index 501ccbe97..36faad026 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -21,6 +21,7 @@ Changelog **Next release** +* Disabled application icon caching ([issue](/../../issues/2094)) * Removed Cydia Substrate support ([issue](/../../issues/2087)) [Open issues](https://github.com/M66B/XPrivacy/issues?state=open) diff --git a/src/biz/bokhorst/xprivacy/ApplicationInfoEx.java b/src/biz/bokhorst/xprivacy/ApplicationInfoEx.java index 042f3ba9a..0b0137255 100644 --- a/src/biz/bokhorst/xprivacy/ApplicationInfoEx.java +++ b/src/biz/bokhorst/xprivacy/ApplicationInfoEx.java @@ -31,7 +31,6 @@ public class ApplicationInfoEx implements Comparable { private Map mMapPkgInfo = new HashMap(); // Cache - private Drawable mIcon = null; private Boolean mInternet = null; private Boolean mFrozen = null; private long mInstallTime = -1; @@ -149,11 +148,11 @@ public List getPackageVersionCode(Context context) { } public Drawable getIcon(Context context) { - if (mIcon == null) - // Pick first icon - if (mMapAppInfo.size() > 0) - mIcon = mMapAppInfo.firstEntry().getValue().loadIcon(context.getPackageManager()); - return (mIcon == null ? new ColorDrawable(Color.TRANSPARENT) : mIcon); + // Pick first icon + if (mMapAppInfo.size() > 0) + return mMapAppInfo.firstEntry().getValue().loadIcon(context.getPackageManager()); + else + return new ColorDrawable(Color.TRANSPARENT); } public boolean hasInternet(Context context) {