From 0e41ae6433b38ab84184aec4ae55bc909a95abbb Mon Sep 17 00:00:00 2001 From: Winson Chung Date: Wed, 27 Oct 2010 18:10:32 -0700 Subject: Increasing icons for homescreen as well as as all-apps (temporarily until we get hi-res icons). - Also fixing spacing in the portrait mode, and using the same styles for both AllApps and workspace icons. Change-Id: I222dd5d53a39d6940a85f40b57912b69c926ffd0 --- src/com/android/launcher2/Launcher.java | 6 +++++- src/com/android/launcher2/PagedViewIcon.java | 4 +++- 2 files changed, 8 insertions(+), 2 deletions(-) (limited to 'src/com/android') diff --git a/src/com/android/launcher2/Launcher.java b/src/com/android/launcher2/Launcher.java index 346e472c5..961acfe80 100644 --- a/src/com/android/launcher2/Launcher.java +++ b/src/com/android/launcher2/Launcher.java @@ -992,8 +992,12 @@ public final class Launcher extends Activity View createShortcut(int layoutResId, ViewGroup parent, ShortcutInfo info) { TextView favorite = (TextView) mInflater.inflate(layoutResId, parent, false); + // Temporarily, we are scaling up all shortcuts on the workspace + int scaledSize = parent.getResources().getDimensionPixelSize(R.dimen.temp_scaled_icon_size); + Bitmap b = Bitmap.createScaledBitmap(info.getIcon(mIconCache), scaledSize, scaledSize, true); + favorite.setCompoundDrawablesWithIntrinsicBounds(null, - new FastBitmapDrawable(info.getIcon(mIconCache)), + new FastBitmapDrawable(b), null, null); favorite.setText(info.title); favorite.setTag(info); diff --git a/src/com/android/launcher2/PagedViewIcon.java b/src/com/android/launcher2/PagedViewIcon.java index be4999d58..c59ef8014 100644 --- a/src/com/android/launcher2/PagedViewIcon.java +++ b/src/com/android/launcher2/PagedViewIcon.java @@ -113,7 +113,9 @@ public class PagedViewIcon extends TextView implements Checkable { mHoloOutlineColor = a.getColor(R.styleable.PagedViewIcon_outlineColor, 0); mCheckedBlurColor = a.getColor(R.styleable.PagedViewIcon_checkedBlurColor, 0); mCheckedOutlineColor = a.getColor(R.styleable.PagedViewIcon_checkedOutlineColor, 0); - mScaledIconSize = a.getDimensionPixelSize(R.styleable.PagedViewIcon_scaledIconSize, 64); + mScaledIconSize = + context.getResources().getDimensionPixelSize(R.dimen.temp_scaled_icon_size); + a.recycle(); if (sHolographicOutlineHelper == null) { -- cgit v1.2.3