summaryrefslogtreecommitdiffstats
path: root/src/com
diff options
context:
space:
mode:
authorMichael Jurka <mikejurka@google.com>2012-05-14 20:05:15 -0700
committerAndroid (Google) Code Review <android-gerrit@google.com>2012-05-14 20:05:15 -0700
commite77b5f8e2706db4d16a0e8f5ab241473b0cc1173 (patch)
tree2c6fcccff99c86fcb31b8731b08c1a27335be8f3 /src/com
parent83d3b12ba6f930ad54ab0cbaa8dffefb23af56c0 (diff)
parent1202b33da6a00b22f3bfd531115cfe030eddf901 (diff)
downloadpackages_apps_trebuchet-e77b5f8e2706db4d16a0e8f5ab241473b0cc1173.zip
packages_apps_trebuchet-e77b5f8e2706db4d16a0e8f5ab241473b0cc1173.tar.gz
packages_apps_trebuchet-e77b5f8e2706db4d16a0e8f5ab241473b0cc1173.tar.bz2
Merge "Centering drag outline when placing shortcut on screen" into jb-dev
Diffstat (limited to 'src/com')
-rw-r--r--src/com/android/launcher2/AppsCustomizePagedView.java2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/com/android/launcher2/AppsCustomizePagedView.java b/src/com/android/launcher2/AppsCustomizePagedView.java
index f2c50a4..5c91d35 100644
--- a/src/com/android/launcher2/AppsCustomizePagedView.java
+++ b/src/com/android/launcher2/AppsCustomizePagedView.java
@@ -702,6 +702,8 @@ public class AppsCustomizePagedView extends PagedViewWithDraggableItems implemen
mWidgetPreviewIconPaddedDimension, Bitmap.Config.ARGB_8888);
Drawable d = image.getDrawable();
mCanvas.setBitmap(preview);
+ mCanvas.translate((mWidgetPreviewIconPaddedDimension - d.getIntrinsicWidth()) / 2,
+ (mWidgetPreviewIconPaddedDimension - d.getIntrinsicHeight()) / 2);
d.draw(mCanvas);
mCanvas.setBitmap(null);
createItemInfo.spanX = createItemInfo.spanY = 1;