Commit Graph

20 Commits

Author SHA1 Message Date
Ats Jenk
1133492a3e Store bubble bar stashed state during rotation [6/N]
Store and restore bubble bar stashed state.
When bubble bar is restored from saved state, restore the bar state to
stashed, collapsed or expanded.
This ensures correct positioning of the bar on screen, before we receive
an update from shell.

Bug: 357115534
Test: bubble bar collapsed on home screen, rotate device and check
    bubble bar remains in correct position and collapsed
Test: bubble bar stashed in app, rotate device and check bubble bar
    remains stashed
Test: bubble bar and taskbar shown while in app, rotate device,
    bubble bar remains shown after rotation, not expanded or stashed
Test: bubble bar is expanded on home screen, rotate device and
    check bubble bar remains expanded
Test: bubble bar is expanded in app, rotate device and check bubble bar
    remains expanded
Flag: com.android.wm.shell.enable_bubble_bar
Change-Id: I91a3b5582a4af753e9e54156358b2ce9adb841c7
2025-04-28 18:45:01 -07:00
Ats Jenk
14474695a2 Store and restore selected bubble and expanded state [3/N]
When bubble bar gets recreated, store the expanded state and selected
bubble.
Allows us to show the bubble bar in previous state after rotation,
before shell has been able to send us an update.

Bug: 357115534
Test: on home screen, have bubble bar expanded, rotate device, check
  bubble bar remains expanded
Test: in app, have bubble bar expanded, rotate device, check bubble bar
  remains expanded
Test: have bubble bar collapsed, rotate device, check it is not expanded
Flag: com.android.wm.shell.enable_bubble_bar
Change-Id: Ied187c638287599297e15db77efdf44bd701d559
2025-04-28 18:44:23 -07:00
Jagrut Desai
64d448a8db Fix Taskbar Flicker with Recents or Running Apps Present
Test: Manual, Presubmit
Bug: 404772481
Flag: EXEMPT bugfix
Change-Id: If3b87474e6e85fabf24a42ac2a3e4ac6a19a4358
2025-03-25 14:16:12 -07:00
Ats Jenk
bcc12470b7 Handle suppressed bubbles
Hide or show bubble based on suppression signals from shell.
If this is the only bubble, hides or shows the bubble bar.

Bug: 273316505
Test: have a single bubble in the bubble bar, suppress the bubble,
  observe that bubble is hidden and bubble bar is not shown,
  unsuppress the bubble, check that bubble bar and bubble is shown
  again, perform check with transient and persistent taskbar
Test: have multiple bubbles, suppress one bubble, check that this bubble
  is not shown, but the bubble bar remains visible with other bubbles,
  perform the check with transient and persistent taskbar
Test: have a single bubble in bubble bar that is suppressed, receive
  notifications to trigger new bubbles, observe bubble bar is shown for
  new bubbles, check that after unsuppressing bubble, it is added back,
  perform the checks with tranient and persistent taskbar
Test: suppress a bubble and rotate the device to trigger launcher
  recreation, check that after unsuppress, the bubble is added back

Flag: com.android.wm.shell.enable_bubble_bar

Change-Id: I17e5cec750a2666feecc62213a3e8fc204ee510a
2024-12-11 16:02:32 -08:00
mpodolian
647266f298 Preserve bubble bar state.
Added logic to save and then restore existing bubbles in the
TaskbarSharedState object.

Bug: 375482371
Test: Manual. Switch between pinned and unpinned taskbar. Video:
http://recall/-/gx8ASgewUeUS3QYohfrd1J/d8hVHxksAokx85J8P7etoC
Flag: com.android.wm.shell.enable_bubble_bar
Change-Id: I34f580f1c652859f427385edc0ccadd447e1400f
2024-10-31 11:50:46 -07:00
Jagrut Desai
e62cb76491 Extend DesktopVisibilityController Funcationality to handle taskbar corner radius in desktop windowing mode
This cl includes
	- adding support for listenting into when desktop window mode task is resizing and we need to adjust taskbar corner radius.

Test: Presubmit
Bug: 348335379
Flag: com.android.window.flags.enable_desktop_windowing_mode
Change-Id: Ic6ea3dc1353df7fa4b8079106f20fade0f740683
2024-08-26 11:39:40 -07:00
Tracy Zhou
027600a259 Pipe nav bar transitions logic into task bar
Bug: 349155860
Test: manual
Flag: com.android.wm.shell.enable_taskbar_on_phones
Change-Id: Idaf7ecc7b964a2c406ddf4329b64971b08f5d7de
2024-06-25 22:01:34 -07:00
Chris Göllner
0cd995e4ef Convert SysUiState flags from int to long
We already reached the limit of 32 flags for an int. To be able to have
more, changing from int to long.

This is needed, as new flags have to be added.

Flag: NONE
Test: Manually running SysUI and Launcher
Test: Unit tests in CL
Bug: 335625543
Change-Id: Iec1d40218264c7c64c50fd09764aa07c0caa7787
2024-05-13 14:47:33 +01:00
Tracy Zhou
1c15229be6 Init with mIsLumaSamplingEnabled = true
Bug: 230395757
Test: Factory reset in unfolded. Check bar sampling. Fold and swipe up from an app different from system color to overview. Observe the bar color change.
Change-Id: I7d94a3a8f17a40fbabd4d65629846eb12bdbd3d6
2024-01-25 22:54:57 -08:00
Tracy Zhou
cf5407dfc6 Hook up luma sampling state change from CommandQueue
Currently when swiping up from some apps (maps), the stashed task bar color changes. Instead, sampling should be disabled during the transition (with a signal from the frameworks).

Bug: 230395757
Test: Swipe up from maps. Make sure the bar color doesn't change during transition
 to overview
Change-Id: Ifc30f4067a0e4d134b422d152f5b5caee0a77a33
2024-01-09 21:56:58 -08:00
Tracy Zhou
f441fd67d3 Make sure the task bar stays unstashed upon configuration change
So we recreate task bars when configuration is changed, if ENABLE_TASKBAR_NAVBAR_UNIFICATION = true. In order for unstashed state to propagate, we need to save STASHED_IN_APP_AUTO in TaskbarSharedState.

Fixes: 311429718
Test: Unstash the task bar in app, rotate, make sure the task bar stays unstashed
Change-Id: I7db773725ea89976612e9e91af5b6911d0ec5fc0
2023-12-12 19:33:42 -08:00
Jagrut Desai
70de8a4823 TaskbarPinningController Unit Tests
Test: Presubmit
Bug: 265439107
Flag: NONE

Change-Id: I5da3558adf88126b07c5d6217ee4fbbcc1e2e348
2023-12-11 14:46:55 -08:00
Jagrut Desai
631b284836 Taskbar pinning animation with no recreate
Test: Manual, Visual
Bug: 265436799
Flag: LEGACY ENABLE_TASKBAR_PINNING DISABLED

Change-Id: I84a4d1efdb0bd4a0f856fa1f46b6489ef54a3841
2023-10-26 10:36:48 -07:00
Tracy Zhou
01cc856157 Always recreate TaskbarActivityContext
- Add ENABLE_TASKBAR_NO_RECREATION flag
  When the flag is turned on,
  * Always destroy and recreate
  * Move task bar drag layer lifecycle from TaskbarActivityContext to TaskbarManager
  * Wrap the drag layer into a fullscreen root view

Note that in order to preserve the window across multiple TaskbarActivityContext creations, the inset types and ids must stay the same, so it's extracted out.

Bug: 274517647
Test: Fold and unfold a few times. Use a few applications. Make sure the task bar is visible and in the right place (tested with ENABLE_TASKBAR_NO_RECREATION and FLAG_HIDE_NAVBAR_WINDOW both on, both off, and one on and one off)
Change-Id: Ic3f0aa3d056fe178a53b76b2ad6cc6b9bffd5898
2023-09-10 22:43:47 -07:00
Jagrut Desai
d2140ba498 Taskbar System Action with Broadcast Receiver.
Test: Manual
Bug: 265618836
Change-Id: I734402ef277a09cf5e41aa63f8be09375706c17a
2023-03-29 10:37:45 -07:00
Tony Wickham
0c6ccca22d Restore proper nav buttons translation when taskbar is recreated
Since mTaskbarInAppDisplayProgressMultiProp is set by various states
that are hard to query in init() (e.g. state of all apps, -1, widgets,
etc.), we store the last mTaskbarInAppDisplayProgressMultiProp in the
TaskbarSharedState and restore those values in init().

Also updated some debug logs in the dump.

Test: manual: from home screen, swipe down to quick settings and toggle
Dark theme, ensure nav buttons don't translate; do the same but over
launcher all apps
Flag: none
Fixes: 267325761

Change-Id: Ib8e6778582ed39c674cd3c1e95312e673659f6a7
2023-03-16 00:06:22 +00:00
Winson Chung
8fe24e0893 Reapply previous states when recreating the task bar
- When the taskbar is recreated (ie. from a display config change),
  the previous states sent from SysUI need to be reapplied to the
  new controllers

Fixes: 267664948
Test: Wipe device, in SUW accessibility settings change the display
      density and verify it properly tints the back button
Change-Id: I837a67ced2941d4545359b8231026044b5479767
2023-02-11 00:25:01 +00:00
Schneider Victor-tulias
9b6babf839 Translate the 3 navigation buttons to/from their in-app position when animating to/from the -1 screen, all apps and widgets.
Bug: 221455508
Test: opened all apps, widgets, -1 screen, notifications shade and keyboard in various combinations and orders; locked screen, launched app, returned home with the back/home buttons, opened overview
Change-Id: Ia0b406aacf72b34bd6b7ff1c01278ab6895a7da4
Merged-In: Ia0b406aacf72b34bd6b7ff1c01278ab6895a7da4
(cherry picked from commit 9c1a452a1d)
2022-05-02 18:45:01 +00:00
Brian Isganitis
464209c535 Recreate All Apps when Taskbar is recreated.
Test: Manual
Fix: 222039500
Fix: 222037737
Fix: 222034811
Change-Id: I53aa3ae77d03ae2a1d500d906ad2ed90efda6f4a
2022-03-07 18:30:29 -08:00
Sunny Goyal
2a528a43c1 Delaying taskbar loading until user setup completed
> Also keeping it stashed while all-set activity is visible
> Creating a shared state (simiar to saved instance state) for taskbar
> Keeping taskbar stashed while all-set activity is visible

Bug: 194786060
Bug: 201782272
Test: Manual
Change-Id: Iab5e082243a206772266aece62d3028f5acb6400
2021-10-19 12:38:02 -07:00