summaryrefslogtreecommitdiffstats
path: root/src/com
diff options
context:
space:
mode:
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 dc2402214..71362e8c1 100644
--- a/src/com/android/launcher2/AppsCustomizePagedView.java
+++ b/src/com/android/launcher2/AppsCustomizePagedView.java
@@ -713,9 +713,11 @@ public class AppsCustomizePagedView extends PagedViewWithDraggableItems implemen
mWidgetPreviewIconPaddedDimension, Bitmap.Config.ARGB_8888);
Drawable d = image.getDrawable();
mCanvas.setBitmap(preview);
+ mCanvas.save();
mCanvas.translate((mWidgetPreviewIconPaddedDimension - d.getIntrinsicWidth()) / 2,
(mWidgetPreviewIconPaddedDimension - d.getIntrinsicHeight()) / 2);
d.draw(mCanvas);
+ mCanvas.restore();
mCanvas.setBitmap(null);
createItemInfo.spanX = createItemInfo.spanY = 1;
}