Rewrite: Widget preview loader logic
> Widget previews are saved in data dir instead of cache dir
> Expiring widget previews similar to IconCache
> Removed support for setting thread priorities
Bug: 19865031
Change-Id: Ib6033c2b1ff8ae61bba8762ca994ccd8217d3c75
diff --git a/src/com/android/launcher3/IconCache.java b/src/com/android/launcher3/IconCache.java
index 3c7adbe..9b2119e 100644
--- a/src/com/android/launcher3/IconCache.java
+++ b/src/com/android/launcher3/IconCache.java
@@ -656,8 +656,8 @@
public ContentValues newContentValues(Bitmap icon, String label) {
ContentValues values = new ContentValues();
- values.put(IconDB.COLUMN_ICON, ItemInfo.flattenBitmap(icon));
- values.put(IconDB.COLUMN_ICON_LOW_RES, ItemInfo.flattenBitmap(
+ values.put(IconDB.COLUMN_ICON, Utilities.flattenBitmap(icon));
+ values.put(IconDB.COLUMN_ICON_LOW_RES, Utilities.flattenBitmap(
Bitmap.createScaledBitmap(icon,
icon.getWidth() / LOW_RES_SCALE_FACTOR,
icon.getHeight() / LOW_RES_SCALE_FACTOR, true)));