Commit Graph

12553 Commits

Author SHA1 Message Date
mpodolian 6ba541642e Improvement for the Bubble Bar Bubbles' Shadows
The issue was caused by the alpha animation applied to the bubble bar.
Added code to check if the alpha applied to the bubble bar is less than
1 and instruct child bubble views not to provide a shadow outline in
such cases. While this is not a full fix, but rather an improvement,
b/345490679 should introduce a proper fix.

Bug: 345484712
Test: visual - go to any application and stash/unstash bubble bar
Flag: com.android.wm.shell.enable_bubble_bar
Change-Id: Icb6bdb009f4d5998ec1638f97de89f7a4c9feccf
2024-07-25 05:31:55 +01:00
Anushree Ganjam 7640b08ea3 Merge "Format dump logs so each of apps info prints in new line." into main 2024-07-24 23:43:54 +00:00
Ats Jenk 4e4b8a8402 Include bubble bar location in taskbar announcement
When bubble bar has bubbles, it will be expanded together with taskbar.
Include information about bubble bar appearing together with the taskbar
announcement. During expand include the location of the bubble bar,
whether it is on the left or right.

Bug: 344675357
Flag: com.android.wm.shell.enable_bubble_bar
Test: manual, enable talkback and check that taskbar expand announcement
  includes information about bubble bar, check that when bar is on left,
  announcement includes left and bar is right, announcement says right
Change-Id: I116ed531fe7032940478451508b37f4fd0bc98ff
2024-07-24 13:50:08 -07:00
Robin Lee 004849d2ec Skip launcher return for custom task transitions
Overriding the task exit transition requires a permission that indicates the exiting task already knows more than the launcher about what its exit is supposed to look like, so we
will let it play the animation it likes instead of the default return-to-launcher one.

Change-Id: I8f4b7292ae0863d378ec6319816e1b9cc7735c24
Test: atest transition-hotlaunch-phone
Flag: EXEMPT bugfix
Bug: 350712843
2024-07-24 20:49:39 +00:00
Liran Binyamin f93199cbe3 Merge "Fix squished hotseat due to bubbles" into main 2024-07-24 19:13:02 +00:00
Shamali Patwa b4d185e3cc Merge changes from topic "popup-refactor" into main
* changes:
  Delete the unused code from popup provider
  Update references that read popup data provider to use picker provider
  Update references that wrote widget data to popup data provider
  Move widget related listeners to widget picker data provider
  Define widget picker data provider separate from popup provider
  Create a separate class for widget related methods from popup provider
2024-07-24 18:46:35 +00:00
Liran Binyamin 2a47a4a68d Fix squished hotseat due to bubbles
Hotseat supports adjusting its layout to make room for bubbles when
needed. There are 2 events that trigger this:
  1. When Hotseat's layout is reset, it checks for whether bubbles
     are showing.
  2. When Bubble Bar visibility changes it notifies hotseat so that
     it can update itself.

Folding the device is recreated triggers both hotseat layout reset
and recreation of taskbar, but the order in which these happen is not
guaranteed. Sometimes hotseat checks for the status of bubble bar
which may be visible if taskbar hasn't been recreated yet.

This change makes sure that hotseat updates itself after taskbar is
recreated and the ui controller is set, so that it cleans up any
adjustments it may have if bubbles are not visible.

This change also updates the way QSB adjusts itself for bubbles.
Previously it always animated from the same start value to a target
value. Now the animation starts from its current width to the target,
so that if the current width is already equal to the target width,
there is no visible change.

Flag: com.android.wm.shell.enable_bubble_bar
Fixes: 349430356
Test: manual
       - unfold the device
       - create bubbles
       - observe hotseat adjusts itself for the bubble bar
       - fold the device
       - observe bubble bar is gone and hotseat shows correctly
Test: manual
       - start a youtube video in full screen
       - swipe from the edge of the screen to show the gesture nav
       - swipe on the gesture nav to go home
       - observe that the QSB does not animate
Change-Id: Ia0267ec518d6af9c3c3b68f17bb20ea67a49e5fd
2024-07-24 12:49:17 -04:00
Alina Zaidi bd3bb00593 Merge "[Dev options][More flags] Update all usages of some flags to use DesktopModeFlags." into main 2024-07-24 10:26:17 +00:00
Treehugger Robot 5ace16c7b8 Merge "Only register RecentTasksChangedListener if flag is enabled" into main 2024-07-24 01:17:35 +00:00
Tony Wickham bbfa9fc181 Only register RecentTasksChangedListener if flag is enabled
Also unregister it if the feature becomes disabled (currently
this is only done in tests but in the future there will be a
user setting as well).

Added tests to verify getTasks() is not called while both
canShowRunningApps and canShowRecentApps are false.

Bug: 354087794
Test: TaskbarRecentAppsControllerTest
Flag: com.android.launcher3.enable_recents_in_taskbar
Flag: com.android.window.flags.enable_desktop_windowing_taskbar_running_apps
Change-Id: I3123501e7584ad7f877e13294454556501d2dbc8
2024-07-23 23:24:10 +00:00
Treehugger Robot 33a237e447 Merge "Fix ConcurrentModificationException in OmniInvokerTest" into main 2024-07-23 23:23:27 +00:00
Treehugger Robot ea4373c060 Merge "Add NavHandleLongPressInputConsumerTest." into main 2024-07-23 23:20:47 +00:00
Treehugger Robot f3e8844b8c Merge "Revert "Fix squished hotseat due to bubbles"" into main 2024-07-23 23:16:48 +00:00
Anushree Ganjam 16f2206f24 Format dump logs so each of apps info prints in new line.
Bug: 353510823
Test: Manual
Flag: NONE BugFix
Change-Id: Id5b0deca68e7af3c63422206db21ce3eba5b0f3a
2024-07-23 15:21:42 -07:00
Liam Lee Pong Lam dfaaa4a258 Merge "[Launcher3] Hides AllApps education view for trackpad" into main 2024-07-23 22:04:04 +00:00
Mykola Podolian 126be5629b Merge "Added BubbleStashController interface" into main 2024-07-23 21:37:31 +00:00
Sihua Ma ee4877f67d Fix ConcurrentModificationException in OmniInvokerTest
Test: atest NexusLauncherRoboTests
Flag: TEST_ONLY
Change-Id: I31402443426e055fe470e11d98b52d07d64e9ca2
2024-07-23 21:24:52 +00:00
Ats Jenk 17f9e70a49 Merge "Announce when bubble bar expands or collapses" into main 2024-07-23 21:22:38 +00:00
Ats Jenk 354d367c47 Merge "Create a11y menu for a bubble in bubble bar" into main 2024-07-23 21:12:23 +00:00
Liran Binyamin f9650bd236 Revert "Fix squished hotseat due to bubbles"
This reverts commit a7821390e2.

Reason for revert: b/354648445

Fixes: 354648445

Change-Id: I069d6d72a59ec273e8b7776512ef9015bdb862c0
2024-07-23 19:56:52 +00:00
Liam, Lee Pong Lam a457b0e016 [Launcher3] Hides AllApps education view for trackpad
Added an indicator `mShowAllAppsEducationView` to check if AllApps
education view should show.

Flag: EXEMPT bugfix
Bug: 342369675
Test: Manual with/without trackpad
Change-Id: Ib995c80467143dd73fe2cac0504dbe6d03834f25
2024-07-23 19:41:18 +00:00
mpodolian 08e98a2c3e Added BubbleStashController interface
Added common BubbleStashController interface and implementation for the
PersistentTaskBarStashController. Added tests for the implementation.

Bug: 346391377
Flag: com.android.wm.shell.enable_bubble_bar
Test: PersistentTaskBarStashControllerTest
Change-Id: I353e5a2cfa2d39e83b0e94980938aee8a1002fd9
2024-07-23 19:32:08 +01:00
Ats Jenk 8034c414c3 Announce when bubble bar expands or collapses
Add a talkback announcement that tells the user when bubble bar expands
or collapses. The announcement includes the bubble name.

Bug: 344670486
Flag: com.android.wm.shell.enable_bubble_bar
Test: expand bubble bar by tapping on it, hear the announcement
Test: collapse bubble bar by tapping on it, hear the announcement
Test: expand/collapse bubble bar from action menu, hear the announcement
Test: use action menu to move expanded bubble bar from one side to the
    other, make sure there is no announcement

Change-Id: I3908bda3eb9e3eb201067fb2c465c3a883ce73d4
2024-07-23 11:01:43 -07:00
Alina Zaidi 7c75e25f56 [Dev options][More flags] Update all usages of some flags to use
DesktopModeFlags.

Test: Current tests pass
Bug: 348193756
Flag: com.android.window.flags.show_desktop_windowing_dev_option
Change-Id: Ie418f511c3b5d21cb2b4e485d30249b853a463af
2024-07-23 13:41:41 +00:00
Alina Zaidi 65794ef777 [Dev options][Wallpaper flag] Update all usage of enableDesktopWindowingWallpaperActivity
flag to use DesktopModeFlags

Test: Current tests pass
Bug: 348193756
Flag: com.android.window.flags.show_desktop_windowing_dev_option
Change-Id: Ib1b1b01f6a94b4d9c49019a31d0e2269246c301b
2024-07-23 10:18:15 +00:00
Alina Zaidi 6bf1a01ff8 Merge "[Dev options][DW flag] Update all usage of enable_desktop_windowing_mode flag to use DesktopModeFlags" into main 2024-07-23 10:06:47 +00:00
Andy Wickham 8e4faffd0e Add NavHandleLongPressInputConsumerTest.
Tests LPNH for the standard conditions (no flags or AGA configs).

Specifically tests:
 - Delegate stealing focus
 - Long press triggers with steady hold or slight slop
 - Up, cancel, or excessive slop cancels the long press
 - Touch ignored if outside the nav handle (not centered)

Things behind flags / AGA config which are not yet tested:
 - 2 stage detection (double timeout after small slop)
 - Deep press
 - Custom timeout from AGA

Fix: 353613291
Test: NavHandleLongPressInputConsumerTest
Flag: TEST_ONLY
Change-Id: I5ada3a07ccec9062ac22fa21b00d5a030f6d134a
2024-07-23 01:23:45 +00:00
Shamali P 66614049eb Update references that wrote widget data to popup data provider
Migrates to write to widget picker data provider instead

Test: Existing tests
Flag: EXEMPT minor refactoring
Bug: 353347512
Change-Id: I1735151e133db0358dfd4f7fa824c6bc7d792307
2024-07-22 23:58:04 +00:00
Vinit Nayak bb37e19c4d Merge "Synchronize split dismiss timing w/ launcher state transition" into main 2024-07-22 22:20:00 +00:00
Ats Jenk 85d4b8bb72 Create a11y menu for a bubble in bubble bar
A11y that supports the following actions:
- collapse
- dismiss
- move bar to the left or right (depending on current location)

Bug: 347028716
Test: select bubble in expanded bubble bar, open action menu
Test: use action menu to:
  - collapse bubble bar
  - dismiss a bubble, ensure only selected bubble is dismissed
  - move bubble bar to other side
Flag: com.android.wm.shell.enable_bubble_bar
Change-Id: I70d90877e045abadb1fca4665ce315476d33c713
2024-07-22 15:17:16 -07:00
Alina Zaidi 3835f93237 [Dev options][DW flag] Update all usage of enable_desktop_windowing_mode flag to use DesktopModeFlags
Test: Current tests pass
Bug: 348193756
Flag: com.android.window.flags.show_desktop_windowing_dev_option
Change-Id: I96107f7c2964ee8261ad0a161163491d6f7d4d39
2024-07-22 20:33:02 +00:00
Vinit Nayak dfa99349c9 Synchronize split dismiss timing w/ launcher state transition
* Extract out common bits from SplitInstructionsView as well

Fixes: 321863575
Test: Dismissed split from overview, swipe to home, cancel button,
tapping on scrim. No thumbnail flashes
Flag: EXEMPT bugfix

Change-Id: I83d54c9b8309bdec64af12bbc8ed397c045e847d
2024-07-22 11:45:52 -07:00
Vinay Joglekar f3256e5ba4 Merge "Support sysUiStatusNavFlags for refactored TTV" into main 2024-07-22 14:35:47 +00:00
Treehugger Robot d603151ae7 Merge "Remove TODO for animating bubble bar view" into main 2024-07-22 13:50:59 +00:00
Sam Cackett 78524ae618 Merge "Convert IconView class to Kotlin" into main 2024-07-22 13:20:18 +00:00
vinayjoglekar 82bb770738 Support sysUiStatusNavFlags for refactored TTV
Bug: 350743460
Test: SysUiStatusNavFlagsUseCaseTest
Flag: com.android.launcher3.enable_refactor_task_thumbnail
Change-Id: Id7576cb2eda14e6c72f34fe3fea3323a104a5164
2024-07-22 12:44:52 +01:00
samcackett d256c912b1 Convert IconView class to Kotlin
Fix: 342594235
Test: Manual. Check IconView in Overview works
Flag: EXEMPT converting java class to Kotlin
Change-Id: Icef4c5ebe7c4ce05fb844448679d032b171ad1bb
2024-07-22 08:51:19 +01:00
Ats Jenk 496e56e4f5 Remove TODO for animating bubble bar view
The animation is added and the linked bug is fixed.
Removing obsolete TODO.

Bug: 280605790
Change-Id: I54ab56f93794afb7f7c23de4df1a348d30cbbf42
Test: NA
Flag: DOCS_ONLY
2024-07-20 00:06:34 +00:00
Ats Jenk f2eb1152a2 Merge "Create accessibility menu for bubble bar" into main 2024-07-19 23:40:47 +00:00
Ats Jenk 7f3b6c030b Create accessibility menu for bubble bar
Bug: 344670180
Test: open accessibility action menu on bubble bar. use menu to
  - expand bubble bar
  - dismiss bubble bar
Test: when bubble bar is on the right, the action menu has an option to
  move bubble bar to the left only, use menu to move bar to the left
Test: when bubble bar is on the left, the action menu has an option to
  move bubble bar to the right only, use menu to move bar to the right
Flag: com.android.wm.shell.enable_bubble_bar
Change-Id: Id875a43927bc3410a83d1342b9456330c9521085
2024-07-19 13:59:35 -07:00
Hongwei Wang 7c0fe2d17f Merge "Disable gesture nav while PiP anim is running" into main 2024-07-19 19:38:52 +00:00
Treehugger Robot 8bba516ca4 Merge "Align color resources in launcher projects." into main 2024-07-19 16:15:25 +00:00
Shamali Patwa 6babde40e3 Merge "Move out picker related methods from widgets model" into main 2024-07-19 15:46:00 +00:00
Ikram Gabiyev d890a9e3e2 Merge "Pass empty srcRectHint if overlay is present" into main 2024-07-19 15:04:02 +00:00
Marcelo Arteiro f38d98d1a6 Align color resources in launcher projects.
This is an effort to align/unify color usage across all launcher projects and the system itself.
This fix recreates all dynamic color attributes present in the OS since many launcher areas cannot access private attributes.
It is recomemnded to use these new local attributes in all launcher areas and avoid creating new color resources when these can be used directly.

Bug: 352690172
Test: Presubmits
Flag: EXEMPT bugfix
Change-Id: Ic36b8bf70ee37f2fdd32e459e66f0e2d001d6ba2
2024-07-19 14:22:21 +00:00
Jordan Silva 426f74369a Introducing Manual DI for Overview
This CL adds the RecentsDependencyContainer to maintain singletons and dependencies related to RecentsView. RecentsDependencies is a singleton that requires the application context to be initialized. Unlike regular singletons, this class has an initialize function where it gets initialized and can be retrieved with getInstance without providing the appContext each time.

- We've updated the refactored classes behind the -enable_refactor_task_thumbnail flag to use this DI solution rather than relying on .parent or recreating dependencies.

- To inject dependencies, you can use RecentsDependencies.inject for lazy initialization or RecentsDependencies.get for eager initialization.

- At the moment, we don't have a singleton or factory definition. All dependencies created by RecentsDependencies will be stored in a specific scope, making the instance a singleton within that scope.

- You can create or retrieve a dependency in a particular scope by calling RecentsDependencies.inject(scopeId).

- If you don't need the dependency to be stored in RecentsDependencies, you can create it manually in your code and inject the necessary parameters from RecentsDependencies (see the viewModel in TaskOverlayHelper).

- Handling the cleaning/resetting of dependencies will be addressed in b/353917593. RecentsView lifecycle is more complex and doesn't get recreated every time. We need to determine which dependencies or scopes can be destroyed and recreated.

Fix: 349055024
Test: NONE
Flag: com.android.launcher3.enable_refactor_task_thumbnail
Change-Id: I27b92e3038f1cce0fd53b637dba5054c05b40283
2024-07-19 11:54:20 +00:00
Treehugger Robot 2495e980ed Merge "Throw exception from SystemUiProxy.getRecentTasks for invalid result" into main 2024-07-19 11:01:40 +00:00
Alex Chau 3210f73125 Throw exception from SystemUiProxy.getRecentTasks for invalid result
- The reason Recents is empty after a force-stop is when RecentsTasksList.getTasks is called first time after restart, the result is always invalid but we cached the invalid result with a chagneId(=1). The next time we call getTasks again, we think the cached result is valid, and returend an empty list.
- The fix is to mark such result as invalid to avoid caching the wrong result

Fix: 353926204
Test: RecentTasksListTest
Flag: EXEMPT bugfix
Change-Id: If15ab8fd7454db8a08c22b17eaac73f0c78aa75f
2024-07-19 09:21:40 +00:00
Liam Lee Pong Lam 0002e9cfc9 Merge "Add unit tests for SettingsChangeLogger" into main 2024-07-19 01:53:21 +00:00
Jon Miranda 6d5ab854d1 Merge "Synchronize the app launch and taskbar stash animations." into main 2024-07-19 00:26:33 +00:00