Commit Graph

29 Commits

Author SHA1 Message Date
fbaron
e4b0b71faa Make hotseat column span responsive
Flag: NONE
Test: DeviceProfileDumpTest, DeviceProfileAlternativeDumpTest, HomeScreenImageTest
Bug: 325084912
Change-Id: Ifa9e8066662a1ab053f66b8800b739d813d2dab8
2024-04-16 06:19:16 +00:00
Thales Lima
6a59006592 Polish hotseat and taskbar with 3 buttons
Change margin spaces and logic of how many items the hotseat and taskbar should show.

Fix: 246424857
Test: DeviceProfileDumpTest
Test: HotseatWidthCalculationTest
Change-Id: I8ec71c56a0aa362483c43d6400c762d12cf45f5b
2022-12-17 11:20:21 +00:00
Thales Lima
9938c2f791 Calculate hotseat width based on available width
Navigation buttons take space on the hotseat, so hotseat width (qsb width and border space between icons) should be calculated instead of having a coded value.

Bug: 223724516
Bug: 228998463
Test: manual, changing display size
Test: manual, changing hotseatBarEndOffset value
Test: HotseatWidthCalculationTest
Change-Id: Ibd4f5ff2e06afda8e7420fb744db049d2e418e14
2022-08-04 15:21:06 +01:00
Vinit Nayak
c7293179d0 Space out 3 button nav on taskbar
* Add additional margin on nav buttons if
there's overlap w/ contextual button
* End spacing is dependent on grid layout

Bug: 223724516
Test: Tested on unfolded with different
grid sizes.

Change-Id: Ie814f35cd1f35629744050ee3f7242c5a8599883
2022-07-25 13:15:11 -07:00
Thales Lima
b8c0595d42 Add new hotseat bottom margin options
This changes how the hotseat height is calculated and by consequence how spaces are distributed in the workspace as well. This is the first of a series of changes that will improve and streamline workspace calculations.

Bug: 228998463
Fix: 234023782
Fix: 230191631
Fix: 232914299
Fix: 236238226
Test: manual, HSV and comparing to mocks
Change-Id: If021e8ba2c7c24c0bf9f27a1aa7aa946792ed04f
2022-07-05 15:33:47 +01:00
Brandon Dayauon
07ca884eea App row padding is now consistent for all grid sizes. Also fix when 2x2 allApp icons get super big.
Added consistent padding to each app row.

Bug: 229789736
Bug: 229791507
Bug: 228320417
Bug: 230870213
Test: Manual on Raven

Change-Id: Ice1c8be361f009994a8e0960a30da04fc1c0c218
2022-05-13 17:10:15 -07:00
Thales Lima
425f6828f1 Fix hotseat width to span a number of columns
Fix: 227344807
Fix: 231283023
Test: manual
Change-Id: Iad0f38c2323be6d9752a8e509fc7e1164edbcf4e
2022-05-11 10:09:03 -03:00
Sunny Goyal
89a89d63a4 Revert "Fix hotseat width to span a number of columns"
Revert submission 17983445-hotseat_span

Reason for revert: b/231283023
Reverted Changes:
Ice4e37929:Fix hotseat width to span a number of columns
I9ed508490:Fix hotseat width to span a number of columns

Change-Id: Iabf67c5efd8155131a0c8a88192ddd671a43747b
2022-05-09 19:32:07 +00:00
Thales Lima
828875cd12 Fix hotseat width to span a number of columns
Bug: 227344807
Test: manual
Change-Id: Ice4e37929bcbb8c9cf3af340e67b6bec002578bd
2022-04-29 14:56:30 +00:00
Thales Lima
26aa8c2496 Making tablet grid scalable and tuning size
Bug: 227344807
Test: manual and HSV
Change-Id: I739cd814ecb8f693b4873cd78f2e8c182538be3b
2022-04-21 11:10:22 +00:00
Thales Lima
4ea95b7fd8 Revert "Making tablet grid scalable and tuning size"
Revert "[automerge] Making tablet grid scalable and tuning size ..."

Revert submission 17607211-aosp_tablet_tune

Reason for revert: Breaking a test b/228490147
Reverted Changes:
I88e581231:[automerge] Making tablet grid scalable and tuning...
I078d19905:Making tablet grid scalable and tuning size
Original bug: b/227344807

Change-Id: Ie6e55edcf5b82b73ad2c8ed7ffd5f0fa5b53594a
2022-04-08 14:14:25 +00:00
Thales Lima
c0481524da Making tablet grid scalable and tuning size
Bug: 227344807
Test: manual and HSV
Change-Id: I078d19905947eb924de8b6ed9067b70a32674bfa
2022-04-07 11:21:48 +00:00
TreeHugger Robot
27981bac2a Merge "Allow column size of search container to be configured" 2022-01-07 18:35:13 +00:00
Thales Lima
85c942fcc9 rename display-option attributes
Rename the attributes to make it more standardized and to be easier to check the multiple variants.

Bug: 202708085
Test: compile and run different launchers
Change-Id: I18b981877b9160bd3801a02567d52b49747d50d4
2022-01-05 10:54:29 +00:00
Alex Chau
ab26c62c4a Allow restore across form factors
- Removed deviceTypeCompatible check and allow restore across for mfactors
- In AOSP default device_profile, mark 3x3, 4x4, and 5x5 as phone only. On tablets they'll reflow to 6x5.

Bug: 198575341
Bug: 210129187
Test: Only 3x3, 4x4 and 5x5 are enabled on phone
Test: Only 6x5 is enabled on tablet
Test: Phone backup of 4x4 get restored and reflow to 6x5 on tablet
Change-Id: I36a641d47fcee86ace0fea3d9194d61d12517f13
2021-12-10 22:00:49 +00:00
Alex Chau
9fee3fd379 Allow column size of search container to be configured
- Added numSearchContainerColumns in grid-option to control search container's width, defaults to numColumns if not specified

Bug: 210127246
Test: manual
Change-Id: I0c2594f0eeab8844dcff9468e603282a09fae0bd
2021-12-10 17:55:51 +00:00
Alex Chau
1c883d861e Add launcher grid spec for tablet
- Introduced device_category to allow grids to be only enabled for certain device types. By default grids are enabled for all device types, so old OEM device_profiles aren't affected
  - Removed device_profiles_split.xml as a result and merged with device_profiles.xml
- Added deviceType in InvariantDeviceProfile to replace isSplitDisplay and centralize the logic
- Only has 6x5 grid with new default layout that works better for tablets

Bug: 198575341
Test: manual
Change-Id: I03f6727ce837ffeee6321b6d7c53942338d0cf30
2021-12-08 18:22:34 +00:00
Thales Lima
1de4d55d55 launcher: create a device profile for foldables
This creates a device_profiles_split.xml that will be used when the
device is a foldable. This makes the changes contained for specific
devices and make it possible to use different padding files in the
future if needed.

Bug: 191879424
Test: tested with NexusLauncher and Launcher3, in foldables and
handhelds
Test: check that 4x4 is not scalable anymore on handhelds by using HSV

Change-Id: If6ef14e3611c5252634c080643433545ce186f0d
2021-10-14 22:42:25 +01:00
Alex Chau
1d5929dd82 Fix wrong screenId when committing emptyScreens
- Need to increment newScreenId whenever the screen is already bound
- Also cleaned up placeholder on w1 as we now have page pairing logic

Bug: 199160559
Bug: 175939730
Fix: 199131780
Test: drag and drop after clear data
Change-Id: Ic42f3bddfa6cf11b8b726d6181ed2477defde19d
2021-09-10 14:36:36 +01:00
Alex Chau
fa3a209537 Only add 2nd screen by default for split display
Fixes: 175939730
Fixes: 196951827
Test: atest Launcher3Tests:com.android.launcher3.ui.TaplTestsLauncher3#testWorkspace
Change-Id: I5b0acf162b7f63c6df8f55a6c7e2975e1748190a
2021-08-17 13:53:07 +00:00
Jon Miranda
f70265f4ec Add split_display device profile.
Bug: 192215417
Test: manual set isSplitDisplay=true, ensure the added device profile
      gets set on device
Change-Id: Ibe33c33d3af140352c0bb4fb44460106ad898285
2021-06-29 17:10:12 +00:00
Tracy Zhou
7df93d28d4 Setup infrastructure (multi-db support) for the new grid migration algorithm
We'll have a db for each grid option and a db for back up / restore.

TODO(pinyaoting): support back up / restore using the new infrastructure, particularly calls to GridBackupTable should use different DBs when the feature flag (NEW_GRID_MIGRATION_ALGORITHM) is on.

Bug: 144052802
Test: N/A

Change-Id: I644a3e70148bd78204a747a337446a3c038f616f
2020-02-05 19:55:05 -08:00
Ryan Mitchell
01b8b68db7 Rename launcher:iconSize attribute to prevent overriding material
A previous change [1] introduced the material library as a static library
for the SecondaryDisplayLauncher. The material library defines a
resource "attr/iconSize" with format="dimension" while Launcher3 defines
a resource of the same name with format="float". The material resource
is being overriden by the Launcher3 resource and is preventing aapt2
from disallowing multiple definitions of the same attribute with
different formats.

This change renames the Launcher3 iconSize so it will not collide with
the material resource.

[1] If183dd35a1d197c4a9a8225a021e36c4f1662587

Bug: 129146717
Test: build success and inspection of generated apk
Change-Id: I5eb54ea606ddcfb47d5150b44906a8707203e905
2019-04-24 16:22:51 +00:00
Sunny Goyal
415f173331 Changing the format for device profile definition
Device profiles are defined such that the grid size is fixed
and only the icon and text sizes change. For every grid size option
there are multiple display configurations.

Bug: 118758696
Change-Id: I54aac9106c576324b02530913c447e849b4ae1da
2018-12-07 00:06:25 -08:00
Jon Miranda
5eacbb7fc1 Update launcher grid for tablet devices.
* Number of hotseat icons matches number of workspace columns.
* Evenly space out the workspace icons.

Bug: 111617973
Change-Id: Ia80e6354c8d449f2a397db5fd432cebc9f23027f
2018-07-31 11:15:01 -07:00
Sunny Goyal
b1d222e9a7 Removing support for app prediction from Launcher3
Derivative projects can extend the FloatingHeader to add support
to custom content in all-apps screen.

Change-Id: I4e29221a72e5a077a756713a6774cda7ecde8f1b
2018-01-30 20:53:11 -08:00
Sunny Goyal
3cf2d5093f Fixing wrong xml refenrece when the packageName is changed
Change-Id: I276d22e82dbef65eaa0f6c3331d7990292a62bc9
2017-11-07 15:41:16 -08:00
Jon Miranda
b28c4fcf35 Landscape grid changes for Workspace/All Apps.
This is the just first CL to get eyes on the changes.
Next CL will update the All Apps to be full width.

Bug: 37015359
Change-Id: I2d7ec6851fdc13b8fa654e7e2be3152330243ccc
2017-06-23 11:47:48 -07:00
Sunny Goyal
819e1936bb Defining the list of predefined device profiles in xml.
This allows the profiles to be easily customized by derivatives.

Change-Id: Iaec2b7a0eda34581c8e48b7dc44817013632dabe
2016-07-07 16:57:49 -07:00