From b1c6bf9d8100906355d113986304f2b8997dba20 Mon Sep 17 00:00:00 2001 From: 1 Date: Tue, 11 Apr 2023 20:52:04 +0000 Subject: Show preview content in landscape. Make stuff smaller and less tall on landscape non-tablets. Let the system restart sharesheet on rotation to allow for resources to change. Tablet displays in landscape generally should follow the un-compressed UI of portrait phones, so the resources for that configuration have to be listed twice. This doesn't dismantle any of the code for handling orientation changes ourselves, as taking that apart may be error-prone. This is meant to a first pass, additional landscape miniturization will follow, as there still isn't a ton of room to scroll at the bottom. Bug: 267522604 Test: Testing in portrait and landscape with a variety of ShareTest payloads Change-Id: I4697ad9510526cc9ce5f9e0630080bef5fad377c --- java/res/layout/chooser_action_button.xml | 31 --------- java/res/layout/chooser_action_row.xml | 4 +- java/res/layout/chooser_grid_preview_image.xml | 2 +- java/res/layout/chooser_grid_preview_text.xml | 2 +- java/res/values-h480dp/bools.xml | 20 ------ java/res/values-land/bools.xml | 20 ++++++ java/res/values-land/dimens.xml | 4 ++ java/res/values-land/integers.xml | 19 +++++ java/res/values-sw600dp/bools.xml | 20 ++++++ java/res/values-sw600dp/dimens.xml | 5 +- java/res/values-sw600dp/integers.xml | 19 +++++ java/res/values/attrs.xml | 4 ++ java/res/values/bools.xml | 2 +- java/res/values/dimens.xml | 2 - java/res/values/integers.xml | 19 +++++ .../android/intentresolver/ChooserActivity.java | 3 +- .../intentresolver/widget/ChooserActionRow.kt | 81 ---------------------- .../intentresolver/widget/ScrollableActionRow.kt | 21 ++++-- 18 files changed, 132 insertions(+), 146 deletions(-) delete mode 100644 java/res/layout/chooser_action_button.xml delete mode 100644 java/res/values-h480dp/bools.xml create mode 100644 java/res/values-land/bools.xml create mode 100644 java/res/values-land/integers.xml create mode 100644 java/res/values-sw600dp/bools.xml create mode 100644 java/res/values-sw600dp/integers.xml create mode 100644 java/res/values/integers.xml delete mode 100644 java/src/com/android/intentresolver/widget/ChooserActionRow.kt (limited to 'java') diff --git a/java/res/layout/chooser_action_button.xml b/java/res/layout/chooser_action_button.xml deleted file mode 100644 index 2b68ccca..00000000 --- a/java/res/layout/chooser_action_button.xml +++ /dev/null @@ -1,31 +0,0 @@ - - -