diff options
author | Sunny Goyal <sunnygoyal@google.com> | 2014-10-07 12:01:58 -0700 |
---|---|---|
committer | Sunny Goyal <sunnygoyal@google.com> | 2014-10-07 12:04:39 -0700 |
commit | 2fce90c38a79d318e96a28107dea287e42509861 (patch) | |
tree | 9fcc3f0b65a4de7b43e820f3549019b9ae20bb25 /src/com/android/launcher3/IconCache.java | |
parent | 33de945451e1380eff2f4c6cd3aa5bb32c0ad368 (diff) | |
download | android_packages_apps_Trebuchet-2fce90c38a79d318e96a28107dea287e42509861.tar.gz android_packages_apps_Trebuchet-2fce90c38a79d318e96a28107dea287e42509861.tar.bz2 android_packages_apps_Trebuchet-2fce90c38a79d318e96a28107dea287e42509861.zip |
Cleaning up icon resizing code
> For resizing icons, scaling them down instead of cropping them
> Removing duplicate methods and variables
Bug: 17663119
Change-Id: I0f270860c0edaaa939495e63e05da841a603f6e9
Diffstat (limited to 'src/com/android/launcher3/IconCache.java')
-rw-r--r-- | src/com/android/launcher3/IconCache.java | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/com/android/launcher3/IconCache.java b/src/com/android/launcher3/IconCache.java index bb71d776c..47cca37f1 100644 --- a/src/com/android/launcher3/IconCache.java +++ b/src/com/android/launcher3/IconCache.java @@ -29,7 +29,6 @@ import android.content.res.Resources; import android.graphics.Bitmap; import android.graphics.BitmapFactory; import android.graphics.Canvas; -import android.graphics.drawable.BitmapDrawable; import android.graphics.drawable.Drawable; import android.text.TextUtils; import android.util.Log; @@ -390,8 +389,7 @@ public class IconCache { entry.title = title; } if (icon != null) { - entry.icon = Utilities.createIconBitmap( - new BitmapDrawable(mContext.getResources(), icon), mContext); + entry.icon = Utilities.createIconBitmap(icon, mContext); } } |