diff options
Diffstat (limited to 'src/com/android/launcher3/DeviceProfile.java')
-rw-r--r-- | src/com/android/launcher3/DeviceProfile.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/com/android/launcher3/DeviceProfile.java b/src/com/android/launcher3/DeviceProfile.java index c0ad5163f..ccbfba178 100644 --- a/src/com/android/launcher3/DeviceProfile.java +++ b/src/com/android/launcher3/DeviceProfile.java @@ -245,7 +245,9 @@ public class DeviceProfile { hotseatCellHeightPx = iconSizePx; // Folder - folderCellWidthPx = Math.min(cellWidthPx + 6 * edgeMarginPx, + int folderCellPadding = isTablet || isLandscape ? 6 * edgeMarginPx : 3 * edgeMarginPx; + // Don't let the folder get too close to the edges of the screen. + folderCellWidthPx = Math.min(cellWidthPx + folderCellPadding, (availableWidthPx - 4 * edgeMarginPx) / inv.numFolderColumns); folderCellHeightPx = cellHeightPx + edgeMarginPx; folderBackgroundOffset = -edgeMarginPx; |