From 68f240eb54891c264031c644a5e5aa4e4fd0c060 Mon Sep 17 00:00:00 2001 From: Sunny Goyal Date: Fri, 7 Oct 2016 13:36:15 -0700 Subject: Updating the folder cell dimensions to be closer to a square Bug: 31813976 Change-Id: I05d7520daee28a310ff122deaf265951e454d21e --- res/layout/user_folder.xml | 10 +++++----- res/layout/user_folder_icon_normalized.xml | 10 +++++----- res/values/dimens.xml | 5 +++-- src/com/android/launcher3/DeviceProfile.java | 3 ++- 4 files changed, 15 insertions(+), 13 deletions(-) diff --git a/res/layout/user_folder.xml b/res/layout/user_folder.xml index 50bd89699..da2a861d8 100644 --- a/res/layout/user_folder.xml +++ b/res/layout/user_folder.xml @@ -26,9 +26,9 @@ android:id="@+id/folder_content" android:layout_width="match_parent" android:layout_height="match_parent" - android:paddingLeft="4dp" - android:paddingRight="4dp" - android:paddingTop="4dp" + android:paddingLeft="8dp" + android:paddingRight="8dp" + android:paddingTop="6dp" launcher:pageIndicator="@+id/folder_page_indicator" /> 8dp 9dp - 8dp + 6dp 13sp - 12dp + 4dp + 12dp 14sp diff --git a/src/com/android/launcher3/DeviceProfile.java b/src/com/android/launcher3/DeviceProfile.java index c4e6ed119..f9f8e80ca 100644 --- a/src/com/android/launcher3/DeviceProfile.java +++ b/src/com/android/launcher3/DeviceProfile.java @@ -284,7 +284,8 @@ public class DeviceProfile { Utilities.calculateTextHeight(res.getDimension(R.dimen.folder_child_text_size)); final int folderBottomPanelSize = - 2 * res.getDimensionPixelSize(R.dimen.folder_label_padding) + res.getDimensionPixelSize(R.dimen.folder_label_padding_top) + + res.getDimensionPixelSize(R.dimen.folder_label_padding_bottom) + Utilities.calculateTextHeight(res.getDimension(R.dimen.folder_label_text_size)); // Don't let the folder get too close to the edges of the screen. -- cgit v1.2.3