summaryrefslogtreecommitdiffstats
path: root/src/com/android/launcher3/ShortcutAndWidgetContainer.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/com/android/launcher3/ShortcutAndWidgetContainer.java')
-rw-r--r--src/com/android/launcher3/ShortcutAndWidgetContainer.java7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/com/android/launcher3/ShortcutAndWidgetContainer.java b/src/com/android/launcher3/ShortcutAndWidgetContainer.java
index 1cf4c11b6..bb5601e90 100644
--- a/src/com/android/launcher3/ShortcutAndWidgetContainer.java
+++ b/src/com/android/launcher3/ShortcutAndWidgetContainer.java
@@ -123,6 +123,13 @@ public class ShortcutAndWidgetContainer extends ViewGroup {
mIsHotseatLayout = isHotseat;
}
+ int getCellContentWidth() {
+ final LauncherAppState app = LauncherAppState.getInstance();
+ final DeviceProfile grid = app.getDynamicGrid().getDeviceProfile();
+ return Math.min(getMeasuredHeight(), mIsHotseatLayout ?
+ grid.hotseatCellWidthPx: grid.cellWidthPx);
+ }
+
int getCellContentHeight() {
final LauncherAppState app = LauncherAppState.getInstance();
final DeviceProfile grid = app.getDynamicGrid().getDeviceProfile();