summaryrefslogtreecommitdiffstats
path: root/src/com/android/launcher2/Utilities.java
diff options
context:
space:
mode:
authorWinson Chung <winsonc@google.com>2011-05-23 17:45:09 -0700
committerWinson Chung <winsonc@google.com>2011-05-23 17:58:39 -0700
commit0be025d64c1f84138fe430a58875886e66aae767 (patch)
tree8503e717562195b97a5bf5490728c968725ec7e6 /src/com/android/launcher2/Utilities.java
parent7d7207f6bca8584c28c8b0b6586f262e543f2d68 (diff)
downloadandroid_packages_apps_Trebuchet-0be025d64c1f84138fe430a58875886e66aae767.tar.gz
android_packages_apps_Trebuchet-0be025d64c1f84138fe430a58875886e66aae767.tar.bz2
android_packages_apps_Trebuchet-0be025d64c1f84138fe430a58875886e66aae767.zip
Fixing long-press issue due to child hit-rect offset.
- Removing some unused code Change-Id: I875e3b27372c4c507e4bbc2d36b16eba077e2121
Diffstat (limited to 'src/com/android/launcher2/Utilities.java')
-rw-r--r--src/com/android/launcher2/Utilities.java22
1 files changed, 0 insertions, 22 deletions
diff --git a/src/com/android/launcher2/Utilities.java b/src/com/android/launcher2/Utilities.java
index ba258939c..04abd77aa 100644
--- a/src/com/android/launcher2/Utilities.java
+++ b/src/com/android/launcher2/Utilities.java
@@ -68,28 +68,6 @@ final class Utilities {
sCanvas.setDrawFilter(new PaintFlagsDrawFilter(Paint.DITHER_FLAG,
Paint.FILTER_BITMAP_FLAG));
}
-
- static Bitmap centerToFit(Bitmap bitmap, int width, int height, Context context) {
- final int bitmapWidth = bitmap.getWidth();
- final int bitmapHeight = bitmap.getHeight();
-
- if (bitmapWidth < width || bitmapHeight < height) {
- int color = context.getResources().getColor(R.color.window_background);
-
- Bitmap centered = Bitmap.createBitmap(bitmapWidth < width ? width : bitmapWidth,
- bitmapHeight < height ? height : bitmapHeight, Bitmap.Config.RGB_565);
- centered.setDensity(bitmap.getDensity());
- Canvas canvas = new Canvas(centered);
- canvas.drawColor(color);
- canvas.drawBitmap(bitmap, (width - bitmapWidth) / 2.0f, (height - bitmapHeight) / 2.0f,
- null);
-
- bitmap = centered;
- }
-
- return bitmap;
- }
-
static int sColors[] = { 0xffff0000, 0xff00ff00, 0xff0000ff };
static int sColorIndex = 0;