diff options
author | Jon Miranda <jonmiranda@google.com> | 2017-06-20 10:58:36 -0700 |
---|---|---|
committer | Jon Miranda <jonmiranda@google.com> | 2017-06-23 11:47:48 -0700 |
commit | b28c4fcf351dc9f44f69253b227880758f6b460c (patch) | |
tree | 1a75f63300be881006ab64d5d39ef0b815826d85 /src/com/android/launcher3/ShortcutAndWidgetContainer.java | |
parent | a9d721df781bf4d195eb52bba1f9a3193f7eaad4 (diff) | |
download | android_packages_apps_Trebuchet-b28c4fcf351dc9f44f69253b227880758f6b460c.tar.gz android_packages_apps_Trebuchet-b28c4fcf351dc9f44f69253b227880758f6b460c.tar.bz2 android_packages_apps_Trebuchet-b28c4fcf351dc9f44f69253b227880758f6b460c.zip |
Landscape grid changes for Workspace/All Apps.
This is the just first CL to get eyes on the changes.
Next CL will update the All Apps to be full width.
Bug: 37015359
Change-Id: I2d7ec6851fdc13b8fa654e7e2be3152330243ccc
Diffstat (limited to 'src/com/android/launcher3/ShortcutAndWidgetContainer.java')
-rw-r--r-- | src/com/android/launcher3/ShortcutAndWidgetContainer.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/com/android/launcher3/ShortcutAndWidgetContainer.java b/src/com/android/launcher3/ShortcutAndWidgetContainer.java index 3a3e13d22..fd708c0fd 100644 --- a/src/com/android/launcher3/ShortcutAndWidgetContainer.java +++ b/src/com/android/launcher3/ShortcutAndWidgetContainer.java @@ -120,7 +120,9 @@ public class ShortcutAndWidgetContainer extends ViewGroup { // Center the icon/folder int cHeight = getCellContentHeight(); int cellPaddingY = (int) Math.max(0, ((lp.height - cHeight) / 2f)); - int cellPaddingX = profile.cellPaddingXPx; + int cellPaddingX = mContainerType == CellLayout.WORKSPACE + ? profile.workspaceCellPaddingXPx + : (int) (profile.edgeMarginPx / 2f); child.setPadding(cellPaddingX, cellPaddingY, cellPaddingX, 0); } } else { |