Commit Graph

218 Commits

Author SHA1 Message Date
Alex Chau
8a7dc2b244 Merge "Remove unnecessary GridDisplayOption_defaultSplitDisplayLayoutId attribute" into tm-qpr-dev 2022-12-14 21:50:34 +00:00
Sihua Ma
60813a89f7 Changed widget picker personal-work tab layout
Used layout margin instead of padding. Also making sure that Talkback would focus on the widgets title once the widget picker is opened.

Before: https://screenshot.googleplex.com/AgZspqTc7yS2Lte
Now: https://screenshot.googleplex.com/5W66ky7XAByCFRZ

Fix: 247121867
Test: Manual
Change-Id: I76534454754c5e57ab51ae7ce06ca4370a3fd22b
2022-12-09 13:58:57 -08:00
Alex Chau
766cd2b4b9 Remove unnecessary GridDisplayOption_defaultSplitDisplayLayoutId attribute
- Can use deviceCategory to make grid specific to splitDisplay instead
- Update TwoPanelWorkspaceTest for new workspace items

Fix: 233736588
Test: Clear launcher and check the default
Test: TwoPanelWorkspaceTest
Change-Id: I6ad3a2d866d847af281e10b802edbd4bcc892c39
2022-12-07 15:18:28 +00:00
Thales Lima
b35faed6e7 Improve spaces for folders
Bug: 214582832
Test: DeviceProfileTest
Change-Id: I7c5cae0792d51baf111d0aec46be302ac6ca9994
2022-11-07 18:23:48 +00:00
Sunny Goyal
fc1928e324 Optimizing some icon generation code:
1) Fixing missing shadow from shortcut icons
2) Chaning all-apps icon rendering to draw background/foreground separately
   This allows us to reuse the bitmap generated for themed icons, instead of
   creating a new everytime

Bug: 248308987
Test: Verified on device
Change-Id: Ia3cbefb21a2ce676d6bb2df3d9375d61b5bed61b
2022-10-20 10:40:54 -07:00
Thales Lima
8da8198bbb Merge "Make inlineQsb a grid-option attr" into tm-qpr-dev 2022-08-16 20:34:10 +00:00
Thales Lima
11af7bcd83 Make inlineQsb a grid-option attr
It should be per grid and not display size

Fix: 242301548
Test: atest DeviceProfileTest
Change-Id: I5ac11bd7162ce8102fd47c64039e339099ee8a05
2022-08-12 15:24:54 +01:00
Thales Lima
a08a443d63 Make folder sizes customizable
Introduce new attrs for folder sizes and update all grids to use the new attrs

Fix: 214582832
Fix: 236272949
Test: atest DeviceProfileTest
Test: manual comparison with mocks
Change-Id: I638052a7f01b4951df0dd26db577167468a3c46d
2022-08-12 12:24:18 +01:00
Thales Lima
1fb075de3b Tune display options for non-default display sizes
Fix: 241382721
Test: manual
Change-Id: I05379c359dabad6931ee897455aa847a7a9b470c
2022-08-10 10:47:50 +01: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
Sunny Goyal
9b458a0012 Generalizing the PredicitonScroll view so that in can be used in all-apps
Bug: 234008165
Test: Verified no-functionality-change on device
Change-Id: Ie17d58148b9bdcb08847beb24114b0494437b30e
2022-07-06 12:29:01 -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
Brian Isganitis
4aab0fdafc Merge "Update download app icon treatment to latest mocks." into tm-qpr-dev 2022-06-09 22:44:10 +00:00
Brandon Dayauon
7a8a9ed170 Fix issue where allAppsCellWidth is 0
when using secondary display on non-scalable grids causing allApps to be squished.
Bug: 234748862
Test: Manual

Change-Id: I2e92bce69438a17eccb0e4b2b2e3f2bdbfa7600e
2022-06-06 14:32:22 -07:00
Brian Isganitis
cd7cc294b8 Update download app icon treatment to latest mocks.
Demo: https://screenshot.googleplex.com/BfTvY2EaByJXwdw.png
Test: Manually using "start install session helper" in SupportApp.
Fix: 205714358
Change-Id: I3ec2fb776cbad974ae36f34b29f3081b3d073c83
2022-06-02 11:53:47 -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
c1ea50a43d Merge "Make inline qsb part of grid attrs" into tm-dev 2022-03-31 08:30:10 +00:00
Thales Lima
12d0eff037 Make inline qsb part of grid attrs
This should make it more configurable, and be independent of the screen size set by the user.

Fix: 223726518
Test: atest Launcher3Tests:HotseatSizeTest
Test: atest Launcher3Tests:InlineQsbTest
Change-Id: If04f3fb0f556103f60b580c757a9fc06da561516
2022-03-30 20:57:57 +01:00
Thales Lima
080d890383 Add border space to all apps cells
Also remove tablet condition, phones should also follow the workspace size.

Fix: 218638090
Test: visual and HSV
Change-Id: Ib201011391c28c0f1dcd0ce8645c3191655a7227
2022-03-30 11:56:27 +01:00
Thales Lima
b7ef569591 Change size of All Apps bottom sheet
This brings the size of the bottom sheet closer to the spec provided by UX. For that type of flexibility to be possible, more attributes are introduced and some calculations had to be changed.

This shouldn't affect phones.

Bug: 218638090
Test: visual, with dumpsys and HSV
Change-Id: Ieee7580d80d8e100837b1cdd7a1455c4d65612dc
2022-03-22 12:19:46 +00:00
Thales Lima
44cc3a2e21 Add more border space options
This give options to landscape layouts to have different border options

Bug: 222109350
Test: manual and HSV
Change-Id: If823dd09c945438f77e57ff80a8a0c4fc0b4c8a6
2022-03-18 14:28:24 +00:00
Alex Chau
6ed408f59f Use less icons in hotseat when in 3 button nav for tablet
- We have less space on tablets when 3 button nav is enabled because QSB is now inline with the icons. This creates a new attribute to define how many icons should be shown when in that mode. This could be used for other grids in the future as well.
- InvariantDeviceProfile now listens for nav mode changes

Fixes 214882090, 221420204
Test: manual

Change-Id: I012432a1a322c4e5505e46a1198c841ab124aaa6
2022-03-07 18:38:05 +00:00
Jon Miranda
48a2f7a0ac Use color tokens for all apps entry buttons.
Bug: 220356537
Bug: 205803230
Test: manual, dark mode, light mode
Change-Id: I0973d5aa9ab1ccbdcc78c1e411cbbf63953f2f94
2022-02-23 19:47:33 +00:00
Thales Lima
9df1ba0847 Merge "create 6x5 scalable grid for tablets" 2022-01-14 12:21:58 +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
dd027348dd create 6x5 scalable grid for tablets
Create more attributes for landscape and fix the space between icons in the hotseat. The dimensions are correct but some size might differ from mocks because of device scaling, qsb position and insets not finalized.

Bug: 210118169
Test: visual, using HSV and Window
Change-Id: Ie505923dce2e30133eb1e5c9c83c33a2895147f2
2022-01-07 12:54:37 +00:00
Thales Lima
bb7d3881fe launcher: more options for all apps icon sizes
Different postures now require different icons sizes, changes in spaces and text size. This should give enough options to change the sizes in All Apps the same was as in the home screen.

Bug: 202708085
Test: visual, using HSV and Window
Change-Id: I40a28f27a19b5728a950a4b43f4239c1ba26c2a4
2022-01-05 15:55:16 +00:00
Thales Lima
6e7f36c86a add attributes for hotseat space
Hotseat now follows the size of workspace icons and should have different spaces based on the grid and posture of the device. It also has more icons.

Fixes: 204488528
Test: HSV and Window
Change-Id: I534df95dda6dc7de3f810632f2cab3822bf78416
2022-01-05 12:54:53 +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
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
Jonathan Miranda
273aa1c7af Merge "Update folder preview and folder background colors." into sc-v2-dev 2021-10-08 18:22:06 +00:00
Thales Lima
83bedbfe97 launcher: refactoring variables into arrays
There are a lot of variables that can be merged together into arrays
following some optimizations done in other places.

Bug: 191879424
Test: checking cell size and extra space in dumpsys
Change-Id: I1d73fbb5da2df2345ced7f46df5bae5d75d9d6b1
2021-10-08 13:36:56 +01:00
Jon Miranda
b77878ebe3 Update folder preview and folder background colors.
Bug: 201332301
Test: light theme / dark theme
      open and close folder, ensure colors are accurate

Change-Id: I49198eb2faee03111be33051fd1cb08094844c77
2021-10-06 16:57:33 -07:00
Thales Lima
78d00adcbe launcher: create more space options
The grid doesn't have a constant space between cells anymore, so we need
new attributes for the different spaces in different situations.

Bug: 191879424
Test: checking cell size and extra space in dumpsys
Change-Id: I4b6aae5b3fea281490c00cd13d0cd3a25372f21b
2021-10-05 12:26:05 +01:00
Thales Lima
bfb6996484 Merge "launcher: create attrs for more horizontal margin options" into sc-v2-dev 2021-10-01 13:20:25 +00:00
Steven Ng
9114f280a2 Merge "Group weather widgets under the widget category" into sc-v2-dev 2021-10-01 10:17:47 +00:00
Steven Ng
43859f10bc Group weather widgets under the widget category
Test: manual (see video in bug) and added PackageUserKeyTest
      Also tested pending conversation widget to ensure the right icon
      is shown.
Fix: 201062480
Change-Id: If23c28bd93c54fb1747648309ab3c238a1810902
2021-09-30 14:22:21 +01:00
Thales Lima
d90faab655 launcher: create attrs for more horizontal margin options
According to new specs, margins are different depending on orientation
and fold/unfolded. Also change the name of the variable to
horizontalMargin, since it applies the same padding to both sides.

Bug: 191879424
Test: manual and checking paddings in HSV
Change-Id: I8990c02b928a22b9f3b0cf3cbc3abf08df4daa9d
2021-09-30 14:06:56 +01:00
sfufa@google.com
de0132939b [Foldable] Apply max width to AllApps in unfolded state.
Since we are applying the same iconWidth in AllApps as Workspace in unfolded state, this change restricts AllApps to span only the area required to display AllApps contents and not span full available width. Unfolded/phone behavior remains the same.

Bug: 199959857
Bug: 194259694
Test: visual
Change-Id: Ie5658d566f20e825e666ef17db79a87b07dc2936
2021-09-24 15:18:01 -07:00
Thales Lima
d1df5fcaac launcher: use scalable grid in 4x4
Many changes are required to make scalable displays work correctly on
foldables. This first one is making sure that the correct number of
columns is used when calculating the used width for scalable grid. The
spaces around the workspace are not final yet.

Bug: 191879424
Test: manual
Change-Id: Idc41ed004580f1f86d8f9595d005abc72301b1e3
2021-09-17 10:43:42 +01:00
Alex Chau
1e4484669d Remove widget panel
- Remove all usage of LEFT_PANEL_ID and fixed left panel code
- For preview renderer, load screen 0 + screen 1 instead
- Added a split display specific default workspace layout, with a placeholder app to pass test before we implement page pairing(b/196376162)
- Known issue: If screenId 1 is deleted, right panel will disappear from Wallpaepr & Style because there is no screenId 1. Will be resovled after page pairing(b/196376162)

Bug: 175939730
Test: manual and TaplTestsLauncher3#testWorkSpace
Change-Id: Icac1c94165c14a49c17897c45355b6cdc4d87e91
2021-08-13 21:48:35 +01:00
Thales Lima
7ec8382044 launcher: hide grid options for foldables
Some grid options are too dense for foldables (those with 5 icons), so
we are hiding them on those devices.

This also move the parsing to be done on InvariantDeviceProfile only.

Fixes: 183140646
Test: open Wallpaper & style and change app grid options
Change-Id: I771571db02709db5d0f814236060c57ce0180cd1
2021-08-13 16:07:05 +00:00
Andras Kloczl
30fe9152d5 Update two panel specific launcher home icon sizing
Test: manual
Bug: 191879424
Change-Id: I4f51616004d78036ad801298bb5ba72af8de3f30
2021-08-12 18:46:01 +01:00
Brian Isganitis
cbaf149f87 Update folder pagination dot color to match mocks.
Test: Folder page dot color matches mocks in light and dark mode.
Fix: 195045519
Change-Id: Ib485e51fbb903b1345ee865ddd8614f280e7608a
2021-08-09 16:03:54 -04:00
Jonathan Miranda
7a582f2d7d Merge "Update colors for non-v31 devices." into sc-dev 2021-06-26 00:09:59 +00:00