From 10ec24ca9e502623e5e39ca55f660da5da758559 Mon Sep 17 00:00:00 2001 From: MrSluffy Date: Sat, 1 Feb 2025 12:15:35 +0800 Subject: [PATCH 1/2] enh : restore split configuration - only tested in pixel fold emulator --- build.gradle | 2 + .../android/launcher3/FeatureFlagsImpl.java | 2 +- lawnchair/res/values-sw400dp-land/styles.xml | 18 ++ lawnchair/res/values-sw400dp/styles.xml | 38 +++ lawnchair/res/values-sw480dp-land/styles.xml | 18 ++ lawnchair/res/values-sw480dp/styles.xml | 18 ++ lawnchair/res/values-sw600dp-land/dimens.xml | 17 ++ lawnchair/res/values-sw600dp-land/styles.xml | 51 ++++ lawnchair/res/values-sw600dp/dimens.xml | 33 +++ lawnchair/res/values-sw600dp/integers.xml | 10 + lawnchair/res/values-sw600dp/styles.xml | 62 +++++ lawnchair/res/values-sw640dp-land/styles.xml | 25 ++ lawnchair/res/values-sw640dp/styles.xml | 25 ++ lawnchair/res/values-sw700dp-land/styles.xml | 36 +++ lawnchair/res/values-sw700dp/styles.xml | 56 +++++ lawnchair/res/values-sw720dp-land/dimens.xml | 13 + lawnchair/res/values-sw720dp/dimens.xml | 24 ++ lawnchair/res/values-sw800dp-land/styles.xml | 24 ++ lawnchair/res/values-sw800dp/styles.xml | 24 ++ lawnchair/res/values-sw900dp/dimens.xml | 5 + lawnchair/res/values/config.xml | 2 + lawnchair/res/values/dimens.xml | 4 + lawnchair/res/values/styles.xml | 13 + .../xml-sw600dp-land/paddings_split_4_col.xml | 47 ++++ .../xml-sw600dp-land/paddings_split_4x4.xml | 61 +++++ .../xml-sw600dp-land/paddings_split_4x5.xml | 47 ++++ .../xml-sw600dp-land/paddings_split_5_col.xml | 47 ++++ .../xml-sw600dp-land/paddings_split_5x5.xml | 47 ++++ .../res/xml-sw600dp/paddings_split_4_col.xml | 47 ++++ .../res/xml-sw600dp/paddings_split_4x4.xml | 49 ++++ .../res/xml-sw600dp/paddings_split_4x5.xml | 47 ++++ .../res/xml-sw600dp/paddings_split_5_col.xml | 47 ++++ .../res/xml-sw600dp/paddings_split_5x5.xml | 47 ++++ .../default_workspace_splitdisplay_4x5.xml | 75 ++++++ lawnchair/res/xml/device_profiles.xml | 234 ++++++++++++++++++ lawnchair/res/xml/paddings_split_4x5.xml | 47 ++++ .../spec_all_apps_cell_match_workspace.xml | 12 + .../spec_foldable_all_apps_4x5_unfolded.xml | 39 +++ .../xml/spec_foldable_folder_4x5_unfolded.xml | 57 +++++ .../spec_foldable_hotseat_4x5_unfolded.xml | 25 ++ .../spec_foldable_workspace_4x5_unfolded.xml | 71 ++++++ ...c_foldable_workspace_cell_4x5_unfolded.xml | 35 +++ lawnchair/res/xml/spec_handheld_all_apps.xml | 39 +++ .../res/xml/spec_handheld_folder_4x5.xml | 51 ++++ .../res/xml/spec_handheld_hotseat_4x5.xml | 31 +++ .../res/xml/spec_handheld_workspace_4x5.xml | 127 ++++++++++ .../xml/spec_handheld_workspace_cell_4x5.xml | 21 ++ src/com/android/launcher3/Launcher.java | 11 +- 48 files changed, 1875 insertions(+), 6 deletions(-) create mode 100644 lawnchair/res/values-sw400dp-land/styles.xml create mode 100644 lawnchair/res/values-sw400dp/styles.xml create mode 100644 lawnchair/res/values-sw480dp-land/styles.xml create mode 100644 lawnchair/res/values-sw480dp/styles.xml create mode 100644 lawnchair/res/values-sw600dp-land/dimens.xml create mode 100644 lawnchair/res/values-sw600dp-land/styles.xml create mode 100644 lawnchair/res/values-sw600dp/dimens.xml create mode 100644 lawnchair/res/values-sw600dp/integers.xml create mode 100644 lawnchair/res/values-sw600dp/styles.xml create mode 100644 lawnchair/res/values-sw640dp-land/styles.xml create mode 100644 lawnchair/res/values-sw640dp/styles.xml create mode 100644 lawnchair/res/values-sw700dp-land/styles.xml create mode 100644 lawnchair/res/values-sw700dp/styles.xml create mode 100644 lawnchair/res/values-sw720dp-land/dimens.xml create mode 100644 lawnchair/res/values-sw720dp/dimens.xml create mode 100644 lawnchair/res/values-sw800dp-land/styles.xml create mode 100644 lawnchair/res/values-sw800dp/styles.xml create mode 100644 lawnchair/res/values-sw900dp/dimens.xml create mode 100644 lawnchair/res/xml-sw600dp-land/paddings_split_4_col.xml create mode 100644 lawnchair/res/xml-sw600dp-land/paddings_split_4x4.xml create mode 100644 lawnchair/res/xml-sw600dp-land/paddings_split_4x5.xml create mode 100644 lawnchair/res/xml-sw600dp-land/paddings_split_5_col.xml create mode 100644 lawnchair/res/xml-sw600dp-land/paddings_split_5x5.xml create mode 100644 lawnchair/res/xml-sw600dp/paddings_split_4_col.xml create mode 100644 lawnchair/res/xml-sw600dp/paddings_split_4x4.xml create mode 100644 lawnchair/res/xml-sw600dp/paddings_split_4x5.xml create mode 100644 lawnchair/res/xml-sw600dp/paddings_split_5_col.xml create mode 100644 lawnchair/res/xml-sw600dp/paddings_split_5x5.xml create mode 100644 lawnchair/res/xml/default_workspace_splitdisplay_4x5.xml create mode 100644 lawnchair/res/xml/paddings_split_4x5.xml create mode 100644 lawnchair/res/xml/spec_all_apps_cell_match_workspace.xml create mode 100644 lawnchair/res/xml/spec_foldable_all_apps_4x5_unfolded.xml create mode 100644 lawnchair/res/xml/spec_foldable_folder_4x5_unfolded.xml create mode 100644 lawnchair/res/xml/spec_foldable_hotseat_4x5_unfolded.xml create mode 100644 lawnchair/res/xml/spec_foldable_workspace_4x5_unfolded.xml create mode 100644 lawnchair/res/xml/spec_foldable_workspace_cell_4x5_unfolded.xml create mode 100644 lawnchair/res/xml/spec_handheld_all_apps.xml create mode 100644 lawnchair/res/xml/spec_handheld_folder_4x5.xml create mode 100644 lawnchair/res/xml/spec_handheld_hotseat_4x5.xml create mode 100644 lawnchair/res/xml/spec_handheld_workspace_4x5.xml create mode 100644 lawnchair/res/xml/spec_handheld_workspace_cell_4x5.xml diff --git a/build.gradle b/build.gradle index a627ada2cc4..16438c6b099 100644 --- a/build.gradle +++ b/build.gradle @@ -448,6 +448,8 @@ dependencies { } implementation 'io.github.hokofly:hoko-blur:1.5.3' + + implementation "androidx.window:window:1.3.0" } ksp { diff --git a/flags/src/com/android/launcher3/FeatureFlagsImpl.java b/flags/src/com/android/launcher3/FeatureFlagsImpl.java index b8cfae5e3a0..d0aad19aaa5 100644 --- a/flags/src/com/android/launcher3/FeatureFlagsImpl.java +++ b/flags/src/com/android/launcher3/FeatureFlagsImpl.java @@ -121,7 +121,7 @@ private void load_overrides_launcher() { enableTaskbarPinning = properties.getBoolean(Flags.FLAG_ENABLE_TASKBAR_PINNING, true); enableTwoPaneLauncherSettings = - properties.getBoolean(Flags.FLAG_ENABLE_TWO_PANE_LAUNCHER_SETTINGS, false); + properties.getBoolean(Flags.FLAG_ENABLE_TWO_PANE_LAUNCHER_SETTINGS, true); enableTwolineAllapps = properties.getBoolean(Flags.FLAG_ENABLE_TWOLINE_ALLAPPS, false); enableTwolineToggle = diff --git a/lawnchair/res/values-sw400dp-land/styles.xml b/lawnchair/res/values-sw400dp-land/styles.xml new file mode 100644 index 00000000000..438c4fae835 --- /dev/null +++ b/lawnchair/res/values-sw400dp-land/styles.xml @@ -0,0 +1,18 @@ + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/values-sw400dp/styles.xml b/lawnchair/res/values-sw400dp/styles.xml new file mode 100644 index 00000000000..5fd65ee1d04 --- /dev/null +++ b/lawnchair/res/values-sw400dp/styles.xml @@ -0,0 +1,38 @@ + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/values-sw480dp-land/styles.xml b/lawnchair/res/values-sw480dp-land/styles.xml new file mode 100644 index 00000000000..438c4fae835 --- /dev/null +++ b/lawnchair/res/values-sw480dp-land/styles.xml @@ -0,0 +1,18 @@ + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/values-sw480dp/styles.xml b/lawnchair/res/values-sw480dp/styles.xml new file mode 100644 index 00000000000..fb6429298a2 --- /dev/null +++ b/lawnchair/res/values-sw480dp/styles.xml @@ -0,0 +1,18 @@ + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/values-sw600dp-land/dimens.xml b/lawnchair/res/values-sw600dp-land/dimens.xml new file mode 100644 index 00000000000..adb0ac5bc20 --- /dev/null +++ b/lawnchair/res/values-sw600dp-land/dimens.xml @@ -0,0 +1,17 @@ + + + 48dp + 11.33dp + 16dp + 0dp + 11.33dp + 49dp + 491dp + 24dp + 16dp + 48dp + 32dp + 3600dp + 44dp + 24dp + \ No newline at end of file diff --git a/lawnchair/res/values-sw600dp-land/styles.xml b/lawnchair/res/values-sw600dp-land/styles.xml new file mode 100644 index 00000000000..1bd7c5a89ab --- /dev/null +++ b/lawnchair/res/values-sw600dp-land/styles.xml @@ -0,0 +1,51 @@ + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/values-sw600dp/dimens.xml b/lawnchair/res/values-sw600dp/dimens.xml new file mode 100644 index 00000000000..1472dc78044 --- /dev/null +++ b/lawnchair/res/values-sw600dp/dimens.xml @@ -0,0 +1,33 @@ + + + 0dp + 38sp + 120dp + 15sp + 9dp + -1000dp + 16dp + 16dp + 64dp + 56dp + 9dp + 0dp + 62dp + 13dp + 32dp + 75dp + 6dp + 17dp + 3000dp + 25dp + 24dp + 28dp + 64dp + 36dp + 12dp + 300dp + 65dp + 44dp + 132dp + 32dp + \ No newline at end of file diff --git a/lawnchair/res/values-sw600dp/integers.xml b/lawnchair/res/values-sw600dp/integers.xml new file mode 100644 index 00000000000..51005e8b64b --- /dev/null +++ b/lawnchair/res/values-sw600dp/integers.xml @@ -0,0 +1,10 @@ + + + @integer/config_bottomSheetCloseDuration + @integer/config_bottomSheetOpenDuration + 500 + 500 + 400 + 550 + 8 + \ No newline at end of file diff --git a/lawnchair/res/values-sw600dp/styles.xml b/lawnchair/res/values-sw600dp/styles.xml new file mode 100644 index 00000000000..b355fc91c2c --- /dev/null +++ b/lawnchair/res/values-sw600dp/styles.xml @@ -0,0 +1,62 @@ + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/values-sw640dp-land/styles.xml b/lawnchair/res/values-sw640dp-land/styles.xml new file mode 100644 index 00000000000..05b3c3854bc --- /dev/null +++ b/lawnchair/res/values-sw640dp-land/styles.xml @@ -0,0 +1,25 @@ + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/values-sw640dp/styles.xml b/lawnchair/res/values-sw640dp/styles.xml new file mode 100644 index 00000000000..a8ef78797c5 --- /dev/null +++ b/lawnchair/res/values-sw640dp/styles.xml @@ -0,0 +1,25 @@ + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/values-sw700dp-land/styles.xml b/lawnchair/res/values-sw700dp-land/styles.xml new file mode 100644 index 00000000000..1addb3fa837 --- /dev/null +++ b/lawnchair/res/values-sw700dp-land/styles.xml @@ -0,0 +1,36 @@ + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/values-sw700dp/styles.xml b/lawnchair/res/values-sw700dp/styles.xml new file mode 100644 index 00000000000..b373d479037 --- /dev/null +++ b/lawnchair/res/values-sw700dp/styles.xml @@ -0,0 +1,56 @@ + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/values-sw720dp-land/dimens.xml b/lawnchair/res/values-sw720dp-land/dimens.xml new file mode 100644 index 00000000000..6e86df95b95 --- /dev/null +++ b/lawnchair/res/values-sw720dp-land/dimens.xml @@ -0,0 +1,13 @@ + + + 29.33dp + 32dp + 0dp + 21.93dp + 21dp + 580dp + 49dp + 5300dp + 64dp + 49dp + \ No newline at end of file diff --git a/lawnchair/res/values-sw720dp/dimens.xml b/lawnchair/res/values-sw720dp/dimens.xml new file mode 100644 index 00000000000..efec09e223f --- /dev/null +++ b/lawnchair/res/values-sw720dp/dimens.xml @@ -0,0 +1,24 @@ + + + 42sp + 16sp + 36dp + 48dp + 24dp + 8dp + 32dp + 32dp + 20sp + 110dp + 72dp + 27.59dp + 24dp + 3400dp + 36dp + 44dp + 16dp + 108dp + 3 + 16dp + 30dp + \ No newline at end of file diff --git a/lawnchair/res/values-sw800dp-land/styles.xml b/lawnchair/res/values-sw800dp-land/styles.xml new file mode 100644 index 00000000000..e0ea739772e --- /dev/null +++ b/lawnchair/res/values-sw800dp-land/styles.xml @@ -0,0 +1,24 @@ + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/values-sw800dp/styles.xml b/lawnchair/res/values-sw800dp/styles.xml new file mode 100644 index 00000000000..57bdb624bb8 --- /dev/null +++ b/lawnchair/res/values-sw800dp/styles.xml @@ -0,0 +1,24 @@ + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/values-sw900dp/dimens.xml b/lawnchair/res/values-sw900dp/dimens.xml new file mode 100644 index 00000000000..43830549d9e --- /dev/null +++ b/lawnchair/res/values-sw900dp/dimens.xml @@ -0,0 +1,5 @@ + + + 76dp + 0dp + \ No newline at end of file diff --git a/lawnchair/res/values/config.xml b/lawnchair/res/values/config.xml index ae76b57676c..ac0261ce4b8 100644 --- a/lawnchair/res/values/config.xml +++ b/lawnchair/res/values/config.xml @@ -161,4 +161,6 @@ 1.10 + + diff --git a/lawnchair/res/values/dimens.xml b/lawnchair/res/values/dimens.xml index a12ca82633a..338f3407f8f 100644 --- a/lawnchair/res/values/dimens.xml +++ b/lawnchair/res/values/dimens.xml @@ -109,4 +109,8 @@ 120dp + 10 + 1 + 1.05 + diff --git a/lawnchair/res/values/styles.xml b/lawnchair/res/values/styles.xml index f3453325b5e..bfef8a2586f 100644 --- a/lawnchair/res/values/styles.xml +++ b/lawnchair/res/values/styles.xml @@ -210,4 +210,17 @@ @dimen/key_text_shadow_dx @dimen/key_text_shadow_dy + + + + + + diff --git a/lawnchair/res/xml-sw600dp-land/paddings_split_4_col.xml b/lawnchair/res/xml-sw600dp-land/paddings_split_4_col.xml new file mode 100644 index 00000000000..fcdc96fbae0 --- /dev/null +++ b/lawnchair/res/xml-sw600dp-land/paddings_split_4_col.xml @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml-sw600dp-land/paddings_split_4x4.xml b/lawnchair/res/xml-sw600dp-land/paddings_split_4x4.xml new file mode 100644 index 00000000000..b35fefaba5a --- /dev/null +++ b/lawnchair/res/xml-sw600dp-land/paddings_split_4x4.xml @@ -0,0 +1,61 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml-sw600dp-land/paddings_split_4x5.xml b/lawnchair/res/xml-sw600dp-land/paddings_split_4x5.xml new file mode 100644 index 00000000000..fcdc96fbae0 --- /dev/null +++ b/lawnchair/res/xml-sw600dp-land/paddings_split_4x5.xml @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml-sw600dp-land/paddings_split_5_col.xml b/lawnchair/res/xml-sw600dp-land/paddings_split_5_col.xml new file mode 100644 index 00000000000..d6ce7f4d852 --- /dev/null +++ b/lawnchair/res/xml-sw600dp-land/paddings_split_5_col.xml @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml-sw600dp-land/paddings_split_5x5.xml b/lawnchair/res/xml-sw600dp-land/paddings_split_5x5.xml new file mode 100644 index 00000000000..d6ce7f4d852 --- /dev/null +++ b/lawnchair/res/xml-sw600dp-land/paddings_split_5x5.xml @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml-sw600dp/paddings_split_4_col.xml b/lawnchair/res/xml-sw600dp/paddings_split_4_col.xml new file mode 100644 index 00000000000..22c1cea904b --- /dev/null +++ b/lawnchair/res/xml-sw600dp/paddings_split_4_col.xml @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml-sw600dp/paddings_split_4x4.xml b/lawnchair/res/xml-sw600dp/paddings_split_4x4.xml new file mode 100644 index 00000000000..c5f13d1ac15 --- /dev/null +++ b/lawnchair/res/xml-sw600dp/paddings_split_4x4.xml @@ -0,0 +1,49 @@ + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml-sw600dp/paddings_split_4x5.xml b/lawnchair/res/xml-sw600dp/paddings_split_4x5.xml new file mode 100644 index 00000000000..22c1cea904b --- /dev/null +++ b/lawnchair/res/xml-sw600dp/paddings_split_4x5.xml @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml-sw600dp/paddings_split_5_col.xml b/lawnchair/res/xml-sw600dp/paddings_split_5_col.xml new file mode 100644 index 00000000000..837865e7e56 --- /dev/null +++ b/lawnchair/res/xml-sw600dp/paddings_split_5_col.xml @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml-sw600dp/paddings_split_5x5.xml b/lawnchair/res/xml-sw600dp/paddings_split_5x5.xml new file mode 100644 index 00000000000..837865e7e56 --- /dev/null +++ b/lawnchair/res/xml-sw600dp/paddings_split_5x5.xml @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml/default_workspace_splitdisplay_4x5.xml b/lawnchair/res/xml/default_workspace_splitdisplay_4x5.xml new file mode 100644 index 00000000000..36c1ce7137c --- /dev/null +++ b/lawnchair/res/xml/default_workspace_splitdisplay_4x5.xml @@ -0,0 +1,75 @@ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml/device_profiles.xml b/lawnchair/res/xml/device_profiles.xml index 54f66c26f7a..4e15c83c218 100644 --- a/lawnchair/res/xml/device_profiles.xml +++ b/lawnchair/res/xml/device_profiles.xml @@ -207,4 +207,238 @@ + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml/paddings_split_4x5.xml b/lawnchair/res/xml/paddings_split_4x5.xml new file mode 100644 index 00000000000..aaf00e7d3d6 --- /dev/null +++ b/lawnchair/res/xml/paddings_split_4x5.xml @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml/spec_all_apps_cell_match_workspace.xml b/lawnchair/res/xml/spec_all_apps_cell_match_workspace.xml new file mode 100644 index 00000000000..65ec082deb1 --- /dev/null +++ b/lawnchair/res/xml/spec_all_apps_cell_match_workspace.xml @@ -0,0 +1,12 @@ + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml/spec_foldable_all_apps_4x5_unfolded.xml b/lawnchair/res/xml/spec_foldable_all_apps_4x5_unfolded.xml new file mode 100644 index 00000000000..8fe5be8eb0f --- /dev/null +++ b/lawnchair/res/xml/spec_foldable_all_apps_4x5_unfolded.xml @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml/spec_foldable_folder_4x5_unfolded.xml b/lawnchair/res/xml/spec_foldable_folder_4x5_unfolded.xml new file mode 100644 index 00000000000..f3387566e97 --- /dev/null +++ b/lawnchair/res/xml/spec_foldable_folder_4x5_unfolded.xml @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml/spec_foldable_hotseat_4x5_unfolded.xml b/lawnchair/res/xml/spec_foldable_hotseat_4x5_unfolded.xml new file mode 100644 index 00000000000..8a6cc2ccf2a --- /dev/null +++ b/lawnchair/res/xml/spec_foldable_hotseat_4x5_unfolded.xml @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml/spec_foldable_workspace_4x5_unfolded.xml b/lawnchair/res/xml/spec_foldable_workspace_4x5_unfolded.xml new file mode 100644 index 00000000000..e240ac6952d --- /dev/null +++ b/lawnchair/res/xml/spec_foldable_workspace_4x5_unfolded.xml @@ -0,0 +1,71 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml/spec_foldable_workspace_cell_4x5_unfolded.xml b/lawnchair/res/xml/spec_foldable_workspace_cell_4x5_unfolded.xml new file mode 100644 index 00000000000..d26c4479ad9 --- /dev/null +++ b/lawnchair/res/xml/spec_foldable_workspace_cell_4x5_unfolded.xml @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml/spec_handheld_all_apps.xml b/lawnchair/res/xml/spec_handheld_all_apps.xml new file mode 100644 index 00000000000..ce700eb5cd2 --- /dev/null +++ b/lawnchair/res/xml/spec_handheld_all_apps.xml @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml/spec_handheld_folder_4x5.xml b/lawnchair/res/xml/spec_handheld_folder_4x5.xml new file mode 100644 index 00000000000..52c1b2ecb9c --- /dev/null +++ b/lawnchair/res/xml/spec_handheld_folder_4x5.xml @@ -0,0 +1,51 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml/spec_handheld_hotseat_4x5.xml b/lawnchair/res/xml/spec_handheld_hotseat_4x5.xml new file mode 100644 index 00000000000..f9c55a6cc5c --- /dev/null +++ b/lawnchair/res/xml/spec_handheld_hotseat_4x5.xml @@ -0,0 +1,31 @@ + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml/spec_handheld_workspace_4x5.xml b/lawnchair/res/xml/spec_handheld_workspace_4x5.xml new file mode 100644 index 00000000000..74b33499146 --- /dev/null +++ b/lawnchair/res/xml/spec_handheld_workspace_4x5.xml @@ -0,0 +1,127 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lawnchair/res/xml/spec_handheld_workspace_cell_4x5.xml b/lawnchair/res/xml/spec_handheld_workspace_cell_4x5.xml new file mode 100644 index 00000000000..3dc494318a5 --- /dev/null +++ b/lawnchair/res/xml/spec_handheld_workspace_cell_4x5.xml @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/com/android/launcher3/Launcher.java b/src/com/android/launcher3/Launcher.java index 03da5361672..51a91fd740c 100644 --- a/src/com/android/launcher3/Launcher.java +++ b/src/com/android/launcher3/Launcher.java @@ -166,6 +166,7 @@ import androidx.annotation.UiThread; import androidx.annotation.VisibleForTesting; import androidx.core.os.BuildCompat; +import androidx.window.embedding.RuleController; import com.android.launcher3.DropTarget.DragObject; import com.android.launcher3.accessibility.LauncherAccessibilityDelegate; @@ -605,11 +606,11 @@ protected void onCreate(Bundle savedInstanceState) { setTitle(R.string.home_screen); mStartupLatencyLogger.logEnd(LAUNCHER_LATENCY_STARTUP_ACTIVITY_ON_CREATE); -// if (BuildCompat.isAtLeastV() -// && com.android.launcher3.Flags.enableTwoPaneLauncherSettings()) { -// RuleController.getInstance(this).setRules( -// RuleController.parseRules(this, R.xml.split_configuration)); -// } + if (BuildCompat.isAtLeastV() + && com.android.launcher3.Flags.enableTwoPaneLauncherSettings()) { + RuleController.getInstance(this).setRules( + RuleController.parseRules(this, R.xml.split_configuration)); + } } protected ModelCallbacks createModelCallbacks() { From f92bb5e5aee52e5eaa5e8cde01496fd13f89539a Mon Sep 17 00:00:00 2001 From: MrSluffy Date: Sat, 1 Feb 2025 13:35:48 +0800 Subject: [PATCH 2/2] enh : update private space lock icon --- lawnchair/res/drawable/ic_pr_lock.xml | 24 ++++++++++++++++++++++++ res/layout/private_space_header.xml | 2 +- 2 files changed, 25 insertions(+), 1 deletion(-) create mode 100644 lawnchair/res/drawable/ic_pr_lock.xml diff --git a/lawnchair/res/drawable/ic_pr_lock.xml b/lawnchair/res/drawable/ic_pr_lock.xml new file mode 100644 index 00000000000..055e6b43f0b --- /dev/null +++ b/lawnchair/res/drawable/ic_pr_lock.xml @@ -0,0 +1,24 @@ + + + + diff --git a/res/layout/private_space_header.xml b/res/layout/private_space_header.xml index 9c0f129b12c..128d87e7d7f 100644 --- a/res/layout/private_space_header.xml +++ b/res/layout/private_space_header.xml @@ -59,7 +59,7 @@ android:layout_marginTop="@dimen/ps_lock_icon_margin_top" android:layout_marginBottom="@dimen/ps_lock_icon_margin_bottom" android:importantForAccessibility="no" - android:src="@drawable/ic_lock" + android:src="@drawable/ic_pr_lock" app:tint="@color/material_color_primary_fixed_dim" android:scaleType="center"/>