From a37de9e14144d5c4501d5eb61b82679c9d622408 Mon Sep 17 00:00:00 2001 From: Steven Ng Date: Thu, 8 Jul 2021 15:48:51 +0100 Subject: [PATCH] Restricts the width of pin widget dialog to 89% on large screen devices Test: manual Fix: 193116981 Change-Id: I6ff8920a3698e6c11729b01a140a6942268f67cc --- .../launcher3/widget/AddItemWidgetsBottomSheet.java | 10 ++++++++++ src/com/android/launcher3/widget/BaseWidgetSheet.java | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/src/com/android/launcher3/widget/AddItemWidgetsBottomSheet.java b/src/com/android/launcher3/widget/AddItemWidgetsBottomSheet.java index 1cc7f53bf9..13245390fa 100644 --- a/src/com/android/launcher3/widget/AddItemWidgetsBottomSheet.java +++ b/src/com/android/launcher3/widget/AddItemWidgetsBottomSheet.java @@ -18,6 +18,7 @@ package com.android.launcher3.widget; import static com.android.launcher3.Utilities.ATLEAST_R; import static com.android.launcher3.anim.Interpolators.FAST_OUT_SLOW_IN; +import static com.android.launcher3.widget.BaseWidgetSheet.MAX_WIDTH_SCALE_FOR_LARGER_SCREEN; import android.animation.PropertyValuesHolder; import android.annotation.SuppressLint; @@ -93,6 +94,15 @@ public class AddItemWidgetsBottomSheet extends AbstractSlideInView * The maximum scale, [0, 1], of the device screen width that the widgets picker can consume * on large screen devices. */ - protected static final float MAX_WIDTH_SCALE_FOR_LARGER_SCREEN = 0.8f; + protected static final float MAX_WIDTH_SCALE_FOR_LARGER_SCREEN = 0.89f; protected static final String KEY_WIDGETS_EDUCATION_TIP_SEEN = "launcher.widgets_education_tip_seen";