diff options
-rw-r--r-- | src/com/android/launcher3/DeviceProfile.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/com/android/launcher3/DeviceProfile.java b/src/com/android/launcher3/DeviceProfile.java index ca5d8e746..2d5f8d016 100644 --- a/src/com/android/launcher3/DeviceProfile.java +++ b/src/com/android/launcher3/DeviceProfile.java @@ -436,7 +436,8 @@ public class DeviceProfile { // Since we are only concerned with the overall padding, layout direction does // not matter. Point padding = getTotalWorkspacePadding(); - result.x = calculateCellWidth(availableWidthPx - padding.x, inv.numColumns); + int cellPadding = cellLayoutPaddingLeftRightPx * 2; + result.x = calculateCellWidth(availableWidthPx - padding.x - cellPadding, inv.numColumns); result.y = calculateCellHeight(availableHeightPx - padding.y, inv.numRows); return result; } |