Commit Graph

1083 Commits

Author SHA1 Message Date
Orhan Uysal
8f2a4e0854 Merge "Use RecentTasksListener to trigger TopTaskTracker" into main 2024-06-12 12:30:13 +00:00
Orhan Uysal
c948537a82 Use RecentTasksListener to trigger TopTaskTracker
Currently launcher gets task stack updates through WM core. Ideally we
would like to migrate into a model where launcher gets these updates
through shell instead.

Test: Manually check that the correct task info is delivered to launcher
from shell
Bug: 341932484
Bug: 344684650
Flag: NONE Just adding a listener, no logic added

Change-Id: Iaf534a4bfee968138d4a4ff282a66e62759af2c0
2024-06-11 21:00:22 +00:00
Treehugger Robot
0f83d92ae4 Merge "Scrolling down to locate PS after lock/unlock event." into main 2024-06-11 20:24:17 +00:00
Himanshu Gupta
3a4b79bf7b Scrolling down to locate PS after lock/unlock event.
This change fixes TAPL tests by:
1. Scrolling down to locate PS, in case the scrollbar moves after lock/unlock.
2. Retrying lock/unlock, as sometimes, the request is cancelled by UserManager (if the profile is already in that state)

Bug: 345556016
Test: atest TaplPrivateSpaceTest
Flag: NONE Tapl fix tweak.
Change-Id: Ic0cc3259a2f92065a699d694c47f65c5f68934b8
2024-06-11 18:15:51 +00:00
Jeremy Sim
dafbaa5f1b Merge "Fix flaky test" into main 2024-06-11 04:12:58 +00:00
Treehugger Robot
9aafa6bd76 Merge changes I8411fb83,I5b757558 into main
* changes:
  Move Desktop running apps support into TaskbarRecentAppsController
  Add flag for Recents in Taskbar
2024-06-11 02:16:56 +00:00
Tony Wickham
a2b510dc23 Move Desktop running apps support into TaskbarRecentAppsController
- Merged DesktopTaskbarRunningAppsController up into
  TaskbarRecentAppsController, which is now initialized directly
- The old TaskbarRecentAppsController was effectively a no-op
  that was always overridden, so merging the one subclass up makes
  things simpler (especially for the follow up CLs which will add
  support for switching between Running and Recent tasks using
  the same underlying data).

Flag: com.android.launcher3.enable_recents_in_taskbar
Test: TaskbarRecentAppsControllerTest
Bug: 315354060
Change-Id: I8411fb832e5dd3d76201d2694dec0b11bd70bbf9
2024-06-11 00:18:23 +00:00
Jeremy Sim
c1470021c8 Fix flaky test
Attempts to fix a flaky test by ensuring that recents is always cleared before creating a split pair (so the split pair under test is always the same).

Bug: 340935208
Test: testSaveAppPairMenuItemOrActionExistsOnSplitPair(), testSplitTaskTapBothIconMenus()
Flag: TEST_ONLY
Change-Id: Ibc81b90fac531f0e78e93a494ff59073ab5e52cf
2024-06-10 14:51:53 -07:00
Vadim Tryshev
d37d4d8b7d Merge "Removing test class TaplViewInflationDuringSwipeUp" into main 2024-06-07 21:19:04 +00:00
Vadim Tryshev
e7d59d06c4 Removing test class TaplViewInflationDuringSwipeUp
The bugs for fixing the removed tests are obsolete, and it was decided to not allocate resources for fixing the tests.

Bug: 190618549, 190729479
Test: presubmit
Flag: NONE it's a test
Change-Id: I1ca3c2c054e4b598c65c86913f0ddbbc711d7f6c
2024-06-07 12:16:37 -07:00
Shamali P
d69e21f8fe Ensure widgets from WidgetSections.xml are included in suggestions
Additionally, let only prediction system provide suggestions, since the
UI surface has been there for a while, adding locally filtered widgets
from app package isn't required.

Bug: 345520128
Test: Unit tests
Flag: EXEMPT bugfix
Change-Id: Ia97f0743fefeae750e07a694bb19d24a5cc11ffe
2024-06-06 22:23:35 +00:00
Himanshu Gupta
91988caf99 Merge "Re-enabling a failing Tapl test for Private Space." into main 2024-06-06 17:08:41 +00:00
Himanshu Gupta
72297b7b81 Re-enabling a failing Tapl test for Private Space.
The test seemed to be failing due to animation issues
(settings cog and Lock text not visible)- b//339179262
Re-enabling the test as those issues are now fixed.

Bug: 322882655
Test: TaplPrivateSpaceTest
Flag: None TaplTest
Change-Id: I4053b9759cd97c721ea576965f57ef309fffaab3
2024-06-05 15:42:46 +01:00
Alina Zaidi
f895a7b0bd Add transition source for DesktopMode enter transition event originating
from AppIcon press in overview

Test: Updated unit tests
Flag: EXEMPT not a major feature/ user visible change
Bug: b/326231756

Change-Id: I9e53cd3ec41dd2475ba90ea8fab2fb7a90f5e158
2024-06-04 13:12:04 +00:00
Tracy Zhou
acb4a3d1e8 Support trackpad tapl tests in 3-button mode
Currently we have logic to only enable input monitor when a trackpad is connected. Tapl tests need to have infrastructure to override that logic

Bug: 335146977
Test: presubmit
Change-Id: Ib7f80c828760f8b5abd7ed2788b246e47fca6e34
2024-05-29 21:58:20 -07:00
Tracy Zhou
a27409e8b2 Merge "Register input monitor for trackpad only when trackpad is attached" into main 2024-05-30 04:12:27 +00:00
Alex Chau
09ae3694e3 Merge "Address jank and memory issues with OverviewActionsView" into main 2024-05-29 09:36:37 +00:00
Jeremy Sim
1ab32a7942 Address jank and memory issues with OverviewActionsView
Attempt to improve jank and memory regressions by simplifying the view layout of OverviewActionsView.

Bug: 339688091
Bug: 339853741
Test: testSaveAppPairMenuItemOrActionExistsOnSplitPair()
Flag: EXEMPT bugfix
Change-Id: Ib4a7c5a813b221c0a083144e7fb1e1c5f3fedb1c
2024-05-28 13:16:52 -07:00
Tracy Zhou
db295670fd Register input monitor for trackpad only when trackpad is attached
Fixes: 335146977
Test: Use logging to make sure that input monitor isn't registered in 3 button mode when trackpad is not attached. When it's attached, it's registered upon attachment
Change-Id: I89fc249546945b3adfc4c804eefd53808138168d
2024-05-26 17:42:30 -07:00
Sunny Goyal
b03d274375 Merge "Fixing some missing swipecancelled events" into main 2024-05-25 08:11:56 +00:00
Sunny Goyal
97ceed42e6 Fixing some missing swipecancelled events
Updating NavBarPosition to expose more constructor and getters

Flag: com.android.launcher3.use_activity_overlay
Test: atest SwipeTransitionTest
Bug: 340432854
Change-Id: I86193fa26c0337d50e366cecb2d7debf37940fe1
2024-05-24 17:34:36 -07:00
Pierre Barbier de Reuille
2de842b558 Merge "Update desktop mode to identify minimized tasks" into main 2024-05-24 08:26:48 +00:00
Pierre Barbier de Reuille
f60dd5471c Update desktop mode to identify minimized tasks
When a task is minimised, it becomes invisible but is still running.
WMShell now signals to the launcher when a task's visibility changes.
The task bar takes the visibility into account to know if a running task
is, in fact, minimised.

Test: atest NexusLauncherTests:DesktopTaskbarRunningAppsControllerTest
Flag: com.android.window.flags.enable_desktop_windowing_taskbar_running_apps
Bug: 333872717
Change-Id: Iaff6b1240d354bb3c4de8e4884948acf9bf40112
2024-05-23 20:59:16 +01:00
Anushree Ganjam
ef9427c709 Merge "Add "Uninstall app" string for private space shortcut." into main 2024-05-22 16:08:31 +00:00
Anushree Ganjam
87e875e702 Add "Uninstall app" string for private space shortcut.
Before: https://screenshot.googleplex.com/8RvbiWnJmgAvSYf.png
After: https://screenshot.googleplex.com/4e7N3rr8EAH7k6B.png

Bug: 335451332
Flag: com.android.launcher3.enable_private_space
Flag: EXEMPT resource only update
Test: Manual
Change-Id: I759005f51562683cb6c095abcca27d448acd10f8
2024-05-21 16:36:02 -07:00
Uwais Ashraf
784b4f28b0 Fix some compile errors occurring as a result of robo enablement
Fix: 297950111
Test: :NexusLauncher.Robo:testGoogleWithQuickstepDebugUnitTest
Test: atest NexusLauncherRoboTests
Flag: NA
Change-Id: Ic9b09fff630d274558d09b7031d12ec28f10fbc7
2024-05-21 18:56:52 +00:00
Alex Chau
4127e460b0 Move common code from DesktopTaskView and GroupedTaskView to TaskView
- Most TaskView method will now loop through taskContainer instead of accessing the first/second
- Moved TaskThumbnailView, showWindowsView, and TaskOverlay to be part of TaskContainer. There are still some TaskOverlay access from TaskThumbnailViewDeprecated that should be remove as we start using TaskThumbnailView

Fix: 339787250
Test: Manual
Flag: EXEMPT refactor
Change-Id: Icfaa4f5eb50582faed01113465335b6d2899f781
2024-05-21 12:43:37 +01:00
Alex Chau
ed9e3a8701 Merge "Convert TaksView to Kotlin" into main 2024-05-16 14:00:02 +00:00
Alex Chau
9565667813 Convert TaksView to Kotlin
- PS1: Android Studio conversion (unformatted, cannot compile)
- PS2: Fix compilation issues and formatting
- PS3: First pass ready for review
- PS4: Minor changes (Remove Consumer, remove unnecessary null-checks)
- PS5: Removed check() around taskContainers, which is now lateinit and should always be initiailzed. Also ensure TaskView is bound before adding to parent.
- PS6: Move a bunch of getters to use .property style
- PS8: Refacoted RecentsView.applyLoadPlan bind logic, to avoid inflating TaksView, bind, add then immediatley remove
- PS10: Turned more functions to express functions; added an extension function
- PS11: Re-order functions, no code changes
- PS12: Reverted unit express function back to {} style

Bug: 339787593
Test: Manual
Flag: NONE
Change-Id: I75c06cf29718d8f258a4124997bcb054f5eb056f
2024-05-16 12:33:28 +01:00
Eghosa Ewansiha-Vlachavas
1c44de9cdb [2/n] Unify DesktopModeStatus between Shell and Sysui
Remove `DesktopModeStatus` from quickstep and instead access through
shell/shared to shell/shared.

Flag: None
Bug: 335401172
Test: atest -c NexusLauncherTests:com.android.quickstep.DesktopSystemShortcutTest

Change-Id: I42f8b6e5f97f13fda22ed34bda4aa712ead53349
2024-05-14 15:26:15 +00:00
Chris Göllner
fa09b12443 Merge "Convert SysUiState flags from int to long" into main 2024-05-14 10:44:40 +00:00
Alex Chau
74804ae560 Merge "Remove unused @ScreenRecord and @Stability for closed bug" into main 2024-05-13 18:03:27 +00:00
Treehugger Robot
b28f611163 Merge "Removing old workaround" into main 2024-05-13 15:53:22 +00: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
Alex Chau
f1c402ad89 Remove unused @ScreenRecord and @Stability for closed bug
Fix: 309820115
Test: None
Flag: None
Change-Id: I7739c3eccb72e8c20e71ed85f5464e1619f8ea3f
2024-05-13 12:22:28 +01:00
Federico Baron
6619568efd Revert "Add screenrecord for TaplPrivateSpaceTest#testPrivateContainerIsPresent"
This reverts commit 4f836430a7.

Reason for revert: issue resolved

Change-Id: I7174e50c166358634626aa308edbd5987e5cc2fb
2024-05-10 20:43:32 +00:00
Vadim Tryshev
306fa566f9 Removing old workaround
Bug: 165029151
Test: presubmit
Flag: N/A
Change-Id: Id54344f0b0423caa4c23eb574f0764648f49e41a
2024-05-10 13:40:37 -07:00
Alex Chau
ec547e0c32 Merge "Recycle thumbnailViews in DesktopTaskView" into main 2024-05-08 22:20:22 +00:00
Alex Chau
4205013b0a Recycle thumbnailViews in DesktopTaskView
- Changed mTaskContainers to a List
- Added an XML for TaskThumbnailView to make it compatible with ViewPool
- Removed mSnapshotViews variable, and streamlined DesktopTaskView binding logic to re-use thumbnailvIew from mTaskContainers or ViewPool

Bug: 249371338
Fix: 251586230
Test: manual
Flag: ACONFIG com.android.window.flags.enable_desktop_windowing_mode DEVELOPMENT
Change-Id: Iab7575e9c36b8ebf3eb62f19f13d75ba671f9f4f
2024-05-08 22:19:27 +00:00
Treehugger Robot
05f201e8ac Merge "Marking testPrivateSpaceLockingBehaviour as disabled." into main 2024-05-08 20:59:02 +00:00
Jeremy Sim
7d69804e4e Merge "Fix bug with double-relayout of Overview Actions View" into main 2024-05-08 20:24:21 +00:00
Himanshu Gupta
a3da6fc6bd Marking testPrivateSpaceLockingBehaviour as disabled.
Temporarily disabling the test as there are failures
seen.
Will be renabled, once the RCA of errors is found.

Bug: 339179262
Test: NA
Flag: NA
Change-Id: I4e4a0b9f8b7290e5be27770a4ded2355a2cc74de
2024-05-08 16:30:07 +01:00
Jeremy Sim
41eadd1a91 Fix bug with double-relayout of Overview Actions View
This CL refactors Overview Actions View so that a separate view, R.id.group_action_buttons, is used for buttons related to grouped tasks. This also changes the way visibility is handled with actions buttons -- instead of all buttons living on one bar and being toggled on and off, sometimes the whole bar is toggled on and off (to change from single task actions to group actions and vice versa).

This prevents the same view from having its visibility changed twice in in one layout and causing the wrong visibility to be rendered.

Fixes: 333844287
Test: Manual
Flag: ACONFIG com.android.wm.shell.enable_app_pairs NEXTFOOD
Change-Id: I1b6be4637ac8c8d424e7633c437fca376ecdd757
2024-05-07 11:18:24 -07:00
Treehugger Robot
22283fd1b8 Merge "Use TaskContainer as source of truth around Task handling" into main 2024-05-07 15:00:24 +00:00
Alex Chau
5b15bfe20b Use TaskContainer as source of truth around Task handling
- Renamed TaskIdAttributeContainer into TaskContainer so it's shorter
- Make mTaskContainers the source of truth for Task handling, removing mTask, mSecondaryTask, mTaskIdContainer and use mTaskContainers to derive all related information
- Remove mTasks/mSnapshotViewMap in DesktopTaskView and replace with mTaskContainers
- Mark methods that assumes a single Task as deprecated e.g. getTask, getItemInfo, getThumbnail to discourage further usage of such methods; "First" is added to the method name to make it explicit only first Task is considered; getTaskContainers is encouraged to access such information

Bug: 249371338
Test: Manual
Flag: None
Change-Id: Ieb15e0e8432913c89dc46c1011f0148095c665f8
2024-05-07 11:51:26 +01:00
Himanshu Gupta
8b0d1fb614 Merge "Adding Tapl test for locking/unlocking Private Space" into main 2024-05-07 09:57:59 +00:00
Himanshu Gupta
bf51b4882e Adding Tapl test for locking/unlocking Private Space
In this test:
1. Private Space is created.
2. Lock Button is clicked, locked view is verified.
3. Unlock Button is clicked, unlocked view is verified.
4. Private Space is removed.

Doc: go/private-space-tapl

Bug: 322882655
Test: TaplPrivateSpaceTest
Flag: NA
Change-Id: I1c399a96ea14a4464113576d31eed8db1caf1f2a
2024-05-06 20:03:23 +01:00
Federico Baron
aed966daae Merge "Add screenrecord and demote TaplTestsTrackpad#switchToOverview" into main 2024-05-03 23:54:32 +00:00
fbaron
afe67917d1 Add screenrecord and demote TaplTestsTrackpad#switchToOverview
Flag: NONE
Test: TaplTestsTrackpad#switchToOverview
Bug: 336606166
Change-Id: Id0e55f20db2a3cfcdb3e16909f76f3b902b5eeaf
2024-05-03 13:51:39 -07:00
Treehugger Robot
a3009176a9 Merge "Give bubble team owners on the correct launcher bubble dirs" into main 2024-05-02 19:47:20 +00:00