From a910be6deee33cfc2a6829076cfeacba4534eb85 Mon Sep 17 00:00:00 2001 From: Fabian Kozynski Date: Fri, 19 Nov 2021 15:00:56 -0500 Subject: [PATCH] Apply dialog style to User switcher dialog. Apply the unified style and set just the inner content, relying on the default title and buttons. Also, fix using the vertical spacing in PseudoGridView. Test: manual Test: atest UserSwitchDialogControllerTest Bug: 203666386 Change-Id: If6a0220979d9f9df584c29f4adce317341577cf4 Merged-In: If6a0220979d9f9df584c29f4adce317341577cf4 --- .../SystemUI/res/layout/qs_user_detail.xml | 2 +- .../res/layout/qs_user_detail_item.xml | 2 - .../res/layout/qs_user_dialog_content.xml | 76 +++-------------- .../android/systemui/qs/PseudoGridView.java | 5 +- .../android/systemui/qs/user/UserDialog.kt | 82 ------------------- .../qs/user/UserSwitchDialogController.kt | 20 +++-- .../systemui/qs/user/UserDialogTest.kt | 62 -------------- .../qs/user/UserSwitchDialogControllerTest.kt | 67 ++++----------- 8 files changed, 39 insertions(+), 277 deletions(-) delete mode 100644 packages/SystemUI/src/com/android/systemui/qs/user/UserDialog.kt delete mode 100644 packages/SystemUI/tests/src/com/android/systemui/qs/user/UserDialogTest.kt diff --git a/packages/SystemUI/res/layout/qs_user_detail.xml b/packages/SystemUI/res/layout/qs_user_detail.xml index 91d3a53556a75..1aec296f4f5c7 100644 --- a/packages/SystemUI/res/layout/qs_user_detail.xml +++ b/packages/SystemUI/res/layout/qs_user_detail.xml @@ -22,6 +22,6 @@ xmlns:sysui="http://schemas.android.com/apk/res-auto" android:layout_width="match_parent" android:layout_height="match_parent" - sysui:verticalSpacing="4dp" + sysui:verticalSpacing="20dp" sysui:horizontalSpacing="4dp" style="@style/UserDetailView" /> \ No newline at end of file diff --git a/packages/SystemUI/res/layout/qs_user_detail_item.xml b/packages/SystemUI/res/layout/qs_user_detail_item.xml index cc6c5d343502a..91b11fcc3c264 100644 --- a/packages/SystemUI/res/layout/qs_user_detail_item.xml +++ b/packages/SystemUI/res/layout/qs_user_detail_item.xml @@ -24,8 +24,6 @@ android:layout_height="wrap_content" android:orientation="vertical" android:gravity="top|center_horizontal" - android:paddingTop="16dp" - android:minHeight="112dp" android:clipChildren="false" android:clipToPadding="false" android:focusable="true" diff --git a/packages/SystemUI/res/layout/qs_user_dialog_content.xml b/packages/SystemUI/res/layout/qs_user_dialog_content.xml index 2a63895b71b8e..355df2c4448ad 100644 --- a/packages/SystemUI/res/layout/qs_user_dialog_content.xml +++ b/packages/SystemUI/res/layout/qs_user_dialog_content.xml @@ -15,75 +15,19 @@ ~ See the License for the specific language governing permissions and ~ limitations under the License. --> - - - - + > - - - -