Commit Graph

642 Commits

Author SHA1 Message Date
Sebastián Franco e1d31e5406 Revert "Revert "Moving DeviceProfile properties into DevicePrope..."
Revert submission 33716851-revert-33672643-DataDeviceProfile1-XHYRAPLEBK

Reason for revert: Error is fixed

Reverted changes: /q/submissionid:33716851-revert-33672643-DataDeviceProfile1-XHYRAPLEBK

Change-Id: Ib86824134955903c11e51e52dbfd6368aba1cd50
2025-05-23 14:08:11 -07:00
Priyanka Advani (xWF) 7705e92d93 Revert "Moving DeviceProfile properties into DeviceProperties da..."
Revert submission 33672643-DataDeviceProfile1

Reason for revert: Droidmonitor created revert due to b/419867875. Will be verifying through ABTD before submission.

Fix: 419867875

Reverted changes: /q/submissionid:33672643-DataDeviceProfile1

Change-Id: Icb66aefbbcee24e05806b2139923e1f2ea1c65e3
2025-05-23 13:53:04 -07:00
Sebastian Franco e1111e28c2 Moving DeviceProfile properties into DeviceProperties data class
Bug: 419264653
Flag: EXEMPT refactor
Test: DeviceProfileDumpTest
Test: All Image tests
Change-Id: I638f88cd76b926917965dbf9e70b5bdfff5971e0
2025-05-23 10:42:26 -07:00
Toni Barzic 3bd1f20e3b Implement spec to configure all apps height
Adds AllAppsSpec support, that can configure all apps height so the
container top aligns with the top of a row in the workspace grid.

Bug: 30153091
Flag: com.android.launcher3.enable_scalability_for_desktop_experience
Test: Manual

Change-Id: Ia5c939c7d3b6fed29a9c2f47233348a5e55b570f
2025-05-21 22:04:33 +00:00
Toni Barzic 83b8cc19ca Support workspace cells with two-line labels
Adds `maxLineCount` attribute to CellSpec. The attribute indicates the max
number of lines of text the cell was speced to support. It's used to:
*   enable two-line labels in `BubbleTextViews` for workspace (including
    folder children) items
*   Update cell dimension calculation to inform cell vertical padding

When calculating cell content size the icon text size will be included
`maxLineCount` times, so the cell content gets centered as if it
contains `maxLineCount` lines of text. That way the icon position will
be consistent between cells with text that fits into one line, and cells
that contain two lines of text.

Adds `maxLineCountMatchesWorkspace` attribute to specify that the cell
should inherit `maxLineCount` from workspace cell spec.

Bug: 30153091
Flag: com.android.launcher3.enable_scalability_for_desktop_experience
Test: Manual

Change-Id: I150a62f427a0ad755a4746a736d9846d3bea4d2e
2025-05-21 22:04:33 +00:00
Brandon Dayauon 653b4b9b31 Make hotseatQsbShadowHeight public
This variable is used during layout of the psb in hotSeat.java. It is specifically
applied to calculate the qsbOffsetY()

bug: 413719316
Test: manually presubmit
Flag: com.google.android.apps.nexuslauncher.psb_aim_reskin
Change-Id: I9b4bd244a39de61e7ef23dbf477e1808f30f5401
2025-05-14 11:33:10 -07:00
Ajinkya Chalke f0ec71d325 Store startAlignTaskbar in DisplayInfoSpec
- CD grids should override startAlignTaskbar.
- The DP.toBuilder method should carry forward DisplayInfoSpec instead
  of always recalculating.

Fix: 416276424
Test: m
Flag: EXEMPT updating recently added logic
Change-Id: I7b1cb8eab5fedc09b29e96a765d1341655474e8a
2025-05-08 17:00:22 +00:00
Ajinkya Chalke bb3571806e Reparse all grids for secondary displays for DP
- This is required to show a half width all apps sheet on external
  monitor connected to the phone. Without this the apps sheet covers the
  full width of the external monitor in projected mode.
- Create a new class to hold all the properties that need to be
  overridden. Set this class as part of DP buider.
- Override all props that are overridden for isTwoPanels.
- Update isTwoPanels to override using the new class in DP constructor.

Flag: com.android.window.flags.enable_taskbar_connected_displays
Bug: 414342881
Test: m
Change-Id: Ia035620c96c5a8912b99314014d4b19a125c7c5c
2025-05-06 12:32:53 +00:00
Sebastian Franco ef2be673a0 Make hotseat icons match with Workspace in Fixed Landscape
Bug: 409784022
Test: Screenshot tests
Test: DumptTest
Flag: EXEMPT bug fix
Change-Id: I12b9699b1dc9ba597511be8e929cc8cf1bde7756
2025-04-10 10:33:06 -07:00
Alex Chau b24e17db10 Add OverviewReleaseFlags to control combination of Overview flags
- This avoids flags from being enabled in Trunkfood partrial unless the dependency is also enabled

Bug: 408178115
Test: build and smoke test
Flag: EXEMPT flag only

Change-Id: Iccf9a9368383ab14a9abf7a1198c8a0c372b103f
2025-04-04 10:38:32 +01:00
Charlie Anderson e3defaa8e6 Merge "Update folder previews to new specs" into main 2025-04-04 00:02:52 -07:00
Charlie Anderson 6f5f8cac25 Update folder previews to new specs
Bug: 403616844
Flag: com.android.launcher3.enable_launcher_icon_shapes
Test: visually comparing against spec

Change-Id: I671b3de7d4ac574122ee3a33451f6cb1d6155f29
2025-04-03 16:42:35 -07:00
Jordan Silva f0d253ef9d Merge "Remove unused overviewActionsButtonSpacing from DeviceProfile" into main 2025-04-03 13:48:07 -07:00
Jordan Silva 17fd5f13f4 Remove unused overviewActionsButtonSpacing from DeviceProfile
Bug: 404479758
Flag: EXEMPT. Clean-up code.
Test: DeviceProfileDumpTest
Test: DeviceProfileAlternativeDisplaysDumpTest
Test: DeviceDefaultGridTest
Change-Id: Ieb9ec81f82e80d293f04de71d5c2575a4ce50301
2025-04-03 10:18:23 -07:00
Andy Wickham 3c7f59ac4b Re-adds Workspace behind All Apps and ties to DepthController.
I had previously hidden workspace with All Apps blur because the
approaches I had tried looked poor. However, I found that this
approach is both simple and relatively performant! Essentially,
wallpaper is still pushed back and blurred by the DepthController.
When the DepthController applies blur, we also apply it to the
Workspace and Hotseat. In addition, we scale these at the same
rate as the depth when swiping to all apps. Perhaps we can have
the DepthController control this scale too, but for now we just
use the same Interpolator. The result looks pretty cohesive.

Demo: https://drive.google.com/file/d/1KyKc0c5BsAEOrT3K4buOW3U9-Gk0e7vE/view?usp=sharing&resourcekey=0-MI1gdQMul0cro9IEkQDEng
App exit demo (slightly outdated): https://drive.google.com/file/d/1r-VhzGhlI0300_6IUXthty3Tm1cgw9aI/view?usp=sharing&resourcekey=0-nxZ2BHW2UN34lr567I0RdA

Bug: 400827727
Bug: 371343636
Test: Manual
Flag: com.android.launcher3.all_apps_blur
Change-Id: I5dc66619a001ccd32f37272cf77966cbe1bf8ef6
2025-03-29 08:12:29 +00:00
Sebastián Franco f33242b9e6 Merge "Return correct QSB bottom padding when QSB is inline" into main 2025-03-21 09:09:09 -07:00
Sebastian Franco 82385f0b6a Return correct QSB bottom padding when QSB is inline
Bug: 403273334
Test: HomeScreenImageTests
Flag: com.android.launcher3.one_grid_specs
Change-Id: I42433f72313668f1c620b18e7a82d385269c13d0
2025-03-20 14:30:21 -07:00
Sebastian Franco c7151f6559 Swap hotseat padding when LTR and in Fixed Landscape
Fix: 404421611
Test: DumptTests
Flag: com.android.launcher3.one_grid_specs
Change-Id: Iba1a19f13d1e8ce164ca4f5b9306c7cdca369814
2025-03-19 09:52:04 -07:00
Sebastián Franco 837e576c56 Merge "Add padding in Fixed Landscape on the side oposite of the camera hole" into main 2025-03-12 18:34:30 -07:00
Andy Wickham ccb3a5c25c Adds all_apps_blur flag.
This enables blur both for Taskbar and Launcher, but in slightly
different ways.

For Taskbar All Apps, we apply blur to the overlay window, and
for Launcher All Apps, we utilize the existing DepthController to
blur the wallpaper window. For similicity, we currently fade out
workspace/hotseat to avoid awkward view + window blurs which
don't look that good. This is not the POR, but I think it achieves
most of the effect and will help us get some blur exposure.

Separately I will continue to investigate options such as blurring
workspace in a clever way so it feels blended with the wallpaper,
reusing the Taskbar window and connecting it to LauncherState, or
using a SurfaceView (though I spent quite some time trying this and
it seemed the same as the original issue).

In both cases, we use a 20-30% opacity scrim with a set color, and a
panel that blends 40% opacity of a dark/light color with 10% white.

Also updated some incorrect isTablet checks which really should have
been checking shouldShowAllAppsOnSheet(), which includes the
all_apps_sheet_for_handheld flag.

Demo: https://drive.google.com/file/d/1Ov9Dg3R9YHNfisfxNf97ZIhlDeEA1IWj/view?usp=sharing&resourcekey=0-l_SDpqpS4HtOb10a3b_jNg

Other upcoming improvements: interpolator tweaks, colors of things
inside the app panel (tabs, private space, search results, etc).

Bug: 400827727
Bug: 371343636
Test: Manual
Flag: com.android.launcher3.all_apps_blur
Change-Id: Ic7063cd822f39a5977715b5477f825bf11e57bdf
2025-03-11 23:34:03 +00:00
Sebastian Franco ad047c74b3 Add padding in Fixed Landscape on the side oposite of the camera hole
Fix: 380031237
Test: HomeScreenImageTest
Flag: com.android.launcher3.one_grid_specs
Change-Id: Ie7557767f629f0c7a5b7b62a3039c8a5c3cc7f43
2025-03-11 14:27:52 -07:00
Sunny Goyal 91547eb4d2 Merge "Simplifying icon normalization for adaptive icons" into main 2025-02-19 10:36:30 -08:00
Mady Mellor 768019357f Allow bubble bar to show on phones if the flag is enabled
* Check for bubble bar on phone being enabled in most places
  tiny taskbar was checking
* Forces taskbar to always be stashed when bubble bar is enabled
* There are a couple of visual issues with the flag enabled:
  - extra space in overview
  - the hotseat is a lil squished on home when bubbles are there

Flag: com.android.wm.shell.enable_bubble_bar_on_phones
Test: manual - enable bubble bar on phones observe that bubble bar
               is enabled and kind of works
Bug: 394869612
Change-Id: I56d3045c78c6c31dcacf16744033b34c9aa5f6e0
2025-02-14 13:09:46 -08:00
Sunny Goyal fe5101d8de Simplifying icon normalization for adaptive icons
Bug: 366237794
Flag: EXEMPT refactor
Test: PResubmit and screenshot tests
Change-Id: Id21e57c9d4ba83983f27aa7988a08db3fd618ce3
2025-02-14 09:09:33 -08:00
Sunny Goyal 29f9c3d231 Merging IconShape with ThemeManager
The order of initialization for IconShape is closely tied to ThemeManager
which makes it difficult for change listeners to work. Merging these keeps
all the theming information at one place

Bug: 381897614
Test: Updated tests
Flag: EXEMPT refactor
Change-Id: Ie29efa20c3308a24be3e284c1c93ed7444b68d58
2025-02-13 22:38:01 -08:00
Sunny Goyal 5bca45a739 Moving InvariantDeviceProfile to Dagger
Bug: 361850561
Test: Presubmit
Flag: EXEMPT dagger
Change-Id: Ia99ee031e96c5e6069a56fe90a262a533dd8665a
2025-02-11 15:22:18 -08:00
Charlie Anderson fcb3d2ec38 Add folder shapes for corresponding icon shapes
Bug: 372886883
Bug: 389329983
Test: Presubmit && IconShapesProviderTest
Flag: com.android.launcher3.enable_launcher_icon_shapes

Change-Id: I46b27b391fef5f379c65d81816353c93f56f2e1d
2025-01-29 14:16:56 -08:00
Sunny Goyal 4c261f7343 Fixing icon shape not properly clipped
> Using ShapeDelegate for icon clipping
> Creating ShapeDelegate based on the current icon shape
> Defining different shape delegates for icon and folder
> Updating preview rendering to use dagger graph
> Adding tests for all icon shapes

Bug: 392145015
Test: atest IconShapesProviderTest
Flag: com.android.launcher3.enable_launcher_icon_shapes

Change-Id: Ic9f287e2a6fef2aad18ba224404de58a64da0bb3
2025-01-29 16:24:38 +00:00
Treehugger Robot 906aa39c47 Merge "Cleanup leftRightSplitInPortrait flag" into main 2025-01-22 12:29:12 -08:00
Vinit Nayak 56234dbfe1 Cleanup leftRightSplitInPortrait flag
Bug: 291018646
Change-Id: I2c801378c33ee62b5f6eabf2e9122dd7ae1a5ee0
Flag: EXEMPT removing flag
2025-01-22 08:28:40 -08:00
Charlie Anderson ad8b2ec13b Update usages of icon shapes in Launcher
Bug: 387546051
Test: manual
Flag: com.android.launcher3.enable_launcher_icon_shapes
Change-Id: I33725259b3480f6e3a2976c227ccdffcfd7d6f83
2025-01-22 02:37:08 +00:00
Sunny Goyal e79d453bc8 Converting LauncherPrefs to dagger
Fixing ENABLE_TWOLINE_ALLAPPS_TOGGLE not properly tied to IDP:
http://recall/-/ep7WJ8pKwCEklUN5J1mAkM

Bug: 361850561
Flag: EXEMPT dagger-migration
Test: atest LauncherPrefsTest FakeLauncherPrefsTest
Change-Id: Iba63d060f4a8c2e31033fca2a4638c559c161338
2025-01-03 13:49:53 -08:00
mpodolian 3e419ebbf1 Remove usage of the enableBubbleBarInPersistentTaskBar flag.
Remove and merge the usage of the enableBubbleBarInPersistentTaskBar
flag to the enableBubbleBar flag.

Bug: 383181643
Flag: com.android.wm.shell.enable_bubble_bar
Test: NONE - removed and merged flag usage.
Change-Id: I4f131e1ddf8367425b91c8fb597857ee222b75d8
2024-12-10 15:10:49 -08:00
Sebastian Franco 789546f528 Using the right context when in FixedLandscape
Fix: 378956881
Test: HomeScreenImageTest
Flag: com.android.launcher3.one_grid_specs
Change-Id: I57c0fb2b57828e0cb80d20417f0a45e49c78b80e
2024-12-04 23:51:34 +00:00
fbaron d1cd8c2ea6 Add GridDimensionSpecs to fixed landscape and make grid dimension generalized so we can use it to determine row count or col count
Bug: 364711064
Flag: com.android.launcher3.one_grid_specs
Test: HomeScreenImageTest
Change-Id: If1dafedc710ebc483fc7b6b5cd6cae6f70dc3cfc
2024-12-03 02:43:13 +00:00
mpodolian 28907bcbd6 Set bubble bar aligned to QSB
Change logic to updated bubble bar alignment with the QSB vertical
center for 3 buttons navigation mode.

Fixes: 378400160
Flag: com.android.wm.shell.enable_bubble_bar
Test: PersistentBubbleStashControllerTest
Test: TransientBubbleStashControllerTest
Test: Manual. Set the buttons navigation mode and observe that the
bubble bar is centered with the QSB when the QSB is not aligned with the
hotseat. Then, switch to gestures navigation mode and observe that the
bubble bar is centered with the hotseat when the QSB is not aligned with
the hotseat.

Change-Id: I57a32ac5bde7a7055b54a89727429424e5c0ca4f
2024-11-27 10:15:08 -08:00
Sebastian Franco 5353cd8626 Making the QSB align in Fixed Landscape
Fix: 378959186
Fix: 378959255
Bug: 364711735
Test: HomeScreenImageTest
Flag: com.android.launcher3.one_grid_specs
Change-Id: I36612949006f12929cdc5b21f27f20ebc9751201
2024-11-16 00:39:44 +00:00
Sebastian Franco 9e4c99befd Adding Launcher Mode settings to Launcher settings
Bug: 364711735
Test: NA
Flag: com.android.launcher3.one_grid_specs
Change-Id: Iab688ebdb8449f9258b61f59a0afe97875f82a81
2024-11-07 21:17:10 -08:00
Andy Wickham 1f6a7b46be Adds all_apps_sheet_for_handheld flag.
This flag causes All Apps to render on a background panel in
handheld mode similarly to how it does on tablets.

Demo: https://drive.google.com/file/d/11K8yueTb9Xr8oRJCM3TxcFH8V3rRFJrJ/view?usp=sharing&resourcekey=0-hMNEGzMQ5KC9D7may2Gb-g

Bug: 374186088
Bug: 372618421
Test: Manual
Flag: com.android.launcher3.all_apps_sheet_for_handheld
Change-Id: Ie0b1e784d4330fd71f7f36f39e5dd85e8ee14933
2024-11-06 16:05:25 +00:00
Brandon Dayauon aebe733849 Merge "Set twoline toggle to false when not in english language." into main 2024-10-24 15:09:08 +00:00
mpodolian f230eee2ff Updated bubble bar position to be center aligned with the hotseat
Added a method to the device profile to calculate the vertical center of
the hotseat icons. Simplified the logic for positioning the bubble bar.

Test: TransientBubbleStashControllerTest
Test: PersistentBubbleStashControllerTest
Test: Visual. Go to home page, check that bubble bar is vertically
center aligned with the hotseat
Bug: 345491493
Flag: com.android.wm.shell.enable_bubble_bar

Change-Id: I52f1b94de79f6c912f43a88fcc5c884e20e56310
2024-10-23 14:44:40 -07:00
Brandon Dayauon 9c65174760 Set twoline toggle to false when not in english language.
Set toggle preference in deviceProfile as this is the first step after the locale change before any binding/inflation happens.
Otherwise the toggle will be stale if we set this false during "apply"/bind which can cause complexities.

bug:373670311
Test manually vid: https://drive.google.com/file/d/1WXl_fMU8eynwlxdwYBamEnqP1tU_q0kb/view?usp=sharing
Flag: NONE bugfix

Change-Id: Iaf9e88ef76ebda6b62942b7bc3f4e39b4ced5116
2024-10-22 09:57:23 -07:00
mpodolian 1d4e75c777 Refactored hotseat translation X logic
Made retrieval of the hotseat translation X easier to use.

Test: Manual. Set the navigation mode to 3-button. Moved the bubble bar
from one side to the other. Switched the navigation mode to gestures.
Moved the bubble bar from one side to the other again.
Bug: 373422448
Flag: EXEMPT refactoring

Change-Id: Ie69f1ecf178244008e5c752882c4b91a30928756
2024-10-17 09:46:47 -07:00
mpodolian 51e2bb31ed Created a helper method that calculates the hotseat icons shift X.
Moved out logic that computes the translation X for the hotseat icons.

Fixes: 368379159
Test: Manual. Have the hotseat adjusted. Open any application from the
hotseat bar. Go back to home.
Flag: EXEMPT refactoring

Change-Id: If9dfa70be537f87b075bd865e7f9c5cd1ae78f00
2024-10-09 12:17:01 -07:00
mpodolian 3dcb19f33a Fixed the hotseat placement in RTL mode
Updated logic that computest the hotseat shift.

Fixes: 372014534
Flag: com.android.wm.shell.enable_bubble_bar
Test: Manual. Put device into 3 buttons navigation mode, force RTL.
Hotseat is placed next to the navigation buttons bar.

Change-Id: Ie7b6be11a093ffa4006182bdc0b73018ba799246
2024-10-07 10:34:42 -07:00
mpodolian 518d404509 Added nav bar properties to DeviceProfile dump() method
Added logging of inlineNavButtonsEndSpacingPx and
navButtonsLayoutWidthPx

Test: DeviceProfileDumpTest
Bug: 346381754
Flag: com.android.wm.shell.enable_bubble_bar_in_persistent_task_bar
Change-Id: I9e537db3d8edf815c131fa9f872193f0d16c259d
2024-09-27 14:06:20 -07:00
Mykola Podolian 6f231f694d Merge "Update placement of the hotseat according to the bubble bar location." into main 2024-09-27 15:45:04 +00:00
mpodolian dfb48214ea Update placement of the hotseat according to the bubble bar location.
Update the hotseat and Qsb placement according to the 3 nav buttons bar.

Test: Manual.
Set navigation mode to 3 buttons.
On launcher home screen move the bubble bar from one side to another.
Observe that the Hotseat and Qsb moving together with the navigation
bar.
Once moved the bubble bar, expand the bubble bar and collapse it.
Observe how the Hotseat is stashing and un-stashing.
After bubble bar changes position hit the recent apps button, observe
the transition.
On launcher home screen start application with the hotseat icon and exit
opened application. Observe that flying icon comes back to the correct
position in the hotseat.
Video with the above scenarios:
http://recall/-/gx8ASgewUeUS3QYohfrd1J/blTYrKopTyufOcRoPuVpYK
Bug: 346381754
Flag: com.android.wm.shell.enable_bubble_bar_in_persistent_task_bar

Change-Id: Ic8c6acdffbbb111cbe4f3fd6bc60195578d7035d
2024-09-26 19:04:01 -07:00
Jon Miranda 9c09196dfd Revert "Add support for taskbar background to wrap around hotseat"
This reverts commit 5dc07d786f.

Reason for revert: b/360116669

Bug: 345768019
Change-Id: Id70ceed141e2106f746d4a0e68a09675ba45dd28
Fixes: 360116669
Test: open taskbar, open all apps w/ ime, use ime back button
Flag: com.android.launcher3.enable_scaling_reveal_home_animation
2024-09-23 22:38:35 +00:00
Treehugger Robot a926663c46 Merge "Removing obsolete flags" into main 2024-09-10 09:25:51 +00:00