Commit Graph

1218 Commits

Author SHA1 Message Date
minch c7a66bd4af Migrating the remaining getTaskViewAt(0)
Migrating the remaining `getTaskViewAt(0)` to `getFirstTaskView()`.

Flag: EXEMPT as no functionality changes
Bug: 379942019
Test: Manual
Change-Id: I083626b0ca62b88d06f508dfc15d9f64112f1a6a
2024-12-11 23:50:53 +00:00
Treehugger Robot 8bba339d80 Merge changes Ifd8f10f5,I14f66628 into main
* changes:
  Update LauncherSwipeUpHandlerV2Test setup to account for RecentsWindowFactory
  Update TaplTestsQuickstep to expect recents window states when enabled
2024-12-11 02:40:01 +00:00
Treehugger Robot 11537828ad Merge "Fising some tests bugs, assuming primary user is user 0" into main 2024-12-10 23:50:28 +00:00
Schneider Victor-Tulias 76e1676c7f Update TaplTestsQuickstep to expect recents window states when enabled
Flag: com.android.launcher3.enable_fallback_overview_in_window
Fixes: 382527932
Test: TaplTestsQuickstep
Change-Id: I14f66628105fab5d8c39ae7f9fd9ebfa61a268b7
2024-12-10 16:17:57 -05:00
Sunny Goyal 89551b71be Fising some tests bugs, assuming primary user is user 0
Bug: 383091872
Bug: 383183795
Bug: 383088668
Test: Presubmit
Flag: EXEMPT test fix
Change-Id: I551f13fc3d51bf1c2718f0582f8ee76d51067896
2024-12-10 12:09:33 -08:00
Treehugger Robot 278ab17033 Merge "Fixing missing userId in various shell commands" into main 2024-12-10 00:50:10 +00:00
Randy Pfohl 6cbf910d9a Merge "initial commit for multicontext management for recent windows" into main 2024-12-09 22:27:52 +00:00
Sunny Goyal 3dfaba2d8c Fixing missing userId in various shell commands
Bug: 380276168
Test: atest TaplMemoryTests
Flag: EXEMPT testfix
Change-Id: I87026eaf6340a2a43cbc899d262879259e339fc5
2024-12-09 10:36:06 -08:00
randypfohl 81962e6fac initial commit for multicontext management for recent windows
Test: Built and ran locally

Flag: com.android.launcher3.enable_fallback_overview_in_window

Bug: 379746094

Change-Id: Ic48b4ef2471a3d6d5eb2e9bacdf00e7d71a87778
2024-12-06 11:17:01 -08:00
Tony Wickham ab8fa5e67e Merge "Factor in userId for updateHotseatItemsFromRunningTasks" into main 2024-12-04 00:31:48 +00:00
Tony Wickham db64e1b3d1 Factor in userId for updateHotseatItemsFromRunningTasks
Test: onRecentTasksChanged_inDesktopMode_sameHotseatPackage_differentUser_isInShownTasks
Test: Pin personal Chrome, open work Chrome in desktop mode; ensure a
new work icon is created in the running apps section
Flag: com.android.window.flags.enable_desktop_windowing_taskbar_running_apps
Bug: 376818660

Change-Id: Ie5cf3ab8e839456e6bd774de8a4398835e790019
2024-12-04 00:31:36 +00:00
Schneider Victor-Tulias 1df3836591 Use the RecentsWindowTracker in FallbackRecentsTest rather than RecentsActivity's ActivityTracker when flag is enabled
Test: pre/postsubmit
Fixes: 381548102
Flag: EXEMPT checking broken tests
Change-Id: I5764c661c53c383a80fbd568e839a5f3d2633427
2024-12-02 16:40:32 -05:00
Gustav Sennton 68648283a8 Use bugfix flags for desktop mode transitions (exit, applaunch, alttab)
The transitions changes are bug fixes / polish, so use bugfix flags
for these changes.
An existing non-bugfix flag cannot be changed into a bugfix flag, so
instead we create new flags with the bugfix type.

Bug: 380224768
Bug: 380225486
Bug: 380224832
Test: manual - disable main flags, use bugfix flags
Flag: com.android.window.flags.enable_desktop_windowing_enter_transition_bugfix
Change-Id: I1c9ea635a362db741f4a632e6360aee87c12750e
2024-11-28 12:32:34 +00:00
Alex Chau 09f2433253 Log various TaskView properties in TaksContainer.itemInfo
- Extracted itemInfo creation in to TaskViewItemInfo and added a test
- Created a standalone atom for TaskView, logging data we want (please refer to the bug)
- Convert TaskView atom to StatsLog data in StatsLogCompatManager
- Simplified DesktopSystemShortcutTest and ExternalDisplaySystemShortcutTest to avoid extra testing on DesktopModeStatus

Fix: 341320349
Test: TaskViewItemInfoTest, DesktopSystemShortcutTest, ExternalDisplaySystemShortcutTest
Flag: EXEMPT logging
Change-Id: Icf04ff2b1670c3f3d5f6a66f99c0d28314efaf21
2024-11-27 10:41:43 +00:00
Winson Chung bf84fe574e Merge "Update OHM regions whenever other regions change" into main 2024-11-22 21:23:21 +00:00
Winson Chung ce1a73829f Update OHM regions whenever other regions change
- Speculative fix, there are some scenarios where we update the swipe
  touch/assistant regions without updating the OHM regions

Bug: 362039326
Flag: EXEMPT bugfix
Test: Manual
Change-Id: If5c558623073e5185827ae17a162dacf322c74a4
2024-11-22 16:53:22 +00:00
Schneider Victor-Tulias df1ac14415 Add unit testing for InputConsumerUtils
Flag: EXEMPT unit testing
Bug: 371020209
Test: InputConsumerUtilsTest
Change-Id: Ia3f9c13dae7650dc0ae37b48b1d75e84cac60142
2024-11-19 15:39:57 -05:00
Treehugger Robot 8a0d3fd363 Merge "Test KQS gets dismissed in certain situations" into main 2024-11-13 23:26:46 +00:00
Toni Barzic 121f6880dd Test KQS gets dismissed in certain situations
Adds tests that verify the KQS gets properly dismissed when user swipes
home while Keyboard Quick Switch UI is shown.

Bug: None

Test: atest TaplTestsKeyboardQuickSwitch
Flag: EXEMPT tests
Change-Id: I6da053f297eedb297c0d40a7414883fbd69b94e5
2024-11-13 21:28:21 +00:00
Schneider Victor-tulias 2e8707dffb Merge "Add debug logs to TaplStartLauncherViaGestureTests" into main 2024-11-12 20:34:46 +00:00
Schneider Victor-Tulias b04492825d Add debug logs to TaplStartLauncherViaGestureTests
Flag: EXEMPT test debug
Bug: 373497052
Test: TaplStartLauncherViaGestureTests
Change-Id: I501f50afac09068db4193da9d98236887fd6e410
2024-11-12 10:59:47 -05:00
Treehugger Robot 48770752e2 Merge "Register transitions for Desktop app launch + minimize animations" into main 2024-11-12 13:55:29 +00:00
Gustav Sennton 39c006e792 Register transitions for Desktop app launch + minimize animations
In other CLs we pass specific RemoteTransitions to Shell for app
launches and unminimize actions. Those CLs cover Launcher actions like
the keyboard alt-tab shortcut, or launching an app from Taskbar.
This CL covers launches that don't originate from Launcher, e.g.
launches through intents.

Test: DesktopAppLaunchTransitionManagerTest
Bug: 369966416
Flag: com.android.window.flags.enable_desktop_app_launch_transitions
Change-Id: I82fd72f870c1e38efe5a8ce533a60f282c10203c
2024-11-12 09:16:34 +00:00
Sunny Goyal 5ad2d9f53c Moving some tests off TAPL
Bug: 377772352
Test: Presubmit
Flag: EXEMPT test refactor
Change-Id: I679ae043d617b74a61a682d802c38cc904d2d0c5
2024-11-08 11:09:59 -08:00
Treehugger Robot 7347a81e41 Merge "Handle Desktop app launches from Taskbar/AllApps icon clicks." into main 2024-11-08 01:04:15 +00:00
Gustav Sennton da2c2c0f7f Handle Desktop app launches from Taskbar/AllApps icon clicks.
- Provide both launch and minimize animations from
  DesktopAppLaunchTransition
- Add support to TaskbarRecentAppsController to check whether an app is
  visible vs. minimized vs. not showing at all in Desktop Mode
- Use DesktopAppLaunchTransition when clicking a Taskbar/AllApps app
  icon (when in Desktop Mode and the app is not visible) to animate the
  app launch
- The animation / transition is passed to Shell through ActivityOptions

Note: this CL does not add animations for launching managed/work
profile apps. That will be handled in b/376819104.

Test: launch apps in Desktop from Taskbar/AllApps
Bug: 327428659
Flag: com.android.window.flags.enable_desktop_app_launch_transitions
Change-Id: I44be96b9c53718b2082d2f630e1921356785fc4b
2024-11-07 23:06:24 +00:00
Sunny Goyal 8bbe47c31b Moving Wait to kotlin
Making LauncherInstrumentation optional and removing some reduntant constants.
This allows less dependency on AbstractLauncherUITest

Bug: 377772352
Test: Presubmit
Flag: EXEMPT test refactor
Change-Id: I7cf78d6acc5fef0359dee141a06fd51ff9d4f5a8
2024-11-07 13:51:27 -08:00
Shamali P 531c227c45 Update widget predictor to apply prediction filter
When enough widgets are not passing the filter, additional randomly
 selected widgets are added.

The count to decide whether to add more is a configuration, so that,
if some OEMs don't want any suggestions, can override the value to 0.

Bug: 356127021
Flag: com.android.launcher3.enable_tiered_widgets_by_default_in_picker
Test: Unit tests
Change-Id: Iffa8619149a1a4b468d367fc7bbee381be59469d
2024-11-07 14:01:52 +00:00
Gustav Sennton 6241d7ef46 Merge "Support Desktop unminimize animations, and move app-state logic" into main 2024-11-07 11:08:04 +00:00
Treehugger Robot 43da2538ff Merge "Add OverviewDesktop test to verify carousel behavior on swipe up" into main 2024-11-06 15:50:18 +00:00
Jordan Silva f048c99de4 Add OverviewDesktop test to verify carousel behavior on swipe up
This CL updates a test to verify the behaviour while swiping up from a fullscreen app to Overview and checking if that TaskView is between DesktopTasks (right side) and Grid Tasks (left side).
The test adds the following validations:
- Launches adjacent task while DesktopTask is at the center of the screen
- Swipe up from a fullscreen app to Overview to validate whether the task is between other tasks and desktop tasks.
- Fling back to DesktopTask to dismiss the adjacent focused task

Fix: 353948167
Flag: com.android.launcher3.enable_large_desktop_windowing_tile
Test: TaplTestsOverviewDesktop
Change-Id: Iaa15d4061c3b6ba8fc0d03416b4721cdf3f047c3
2024-11-06 13:58:41 +00:00
Winson Chung bc5637296a Merge "2b/ Update launcher to use GroupedTaskInfos" into main 2024-11-05 15:43:01 +00:00
Gustav Sennton 461caa7c5f Support Desktop unminimize animations, and move app-state logic
- Support Desktop unminimize animations through
    1. keyboard alt-tab shortcut
    2. taskbar hotseat icon click (TaskItemInfo)
    3. taskbar running-app icon click (GroupTask)
- move taskbar running-app state logic from TaskbarViewController to
  TaskbarRecentAppsController.

Test: manual - ensure the transitions above cause unminimize animations
Bug: 369966334
Flag: com.android.window.flags.enable_desktop_app_launch_alttab_transitions

Change-Id: I20322bdf58bc69cff360bf26e533e0732d5297b9
2024-11-05 13:39:46 +00:00
Winson Chung d8ddd4c023 2b/ Update launcher to use GroupedTaskInfos
Bug: 346588978
Flag: EXEMPT adding new flag enable_shell_top_task_tracking
Test: Build SystemUI & Launcher
Test: atest WMShellUnitTests

Change-Id: I1e41712d9f94649f4381d4235d8f2925df71e2b2
2024-11-01 22:52:09 +00:00
Tony Wickham 0f954d9d3b Merge "TaskbarManager now sets TaskbarUIController for RecentsWindowManager" into main 2024-10-31 20:17:21 +00:00
Tony Wickham 87455f28fc TaskbarManager now sets TaskbarUIController for RecentsWindowManager
- FallbackTaskbarUIController can take in a generic
  RecentsViewContainer parameter, i.e. RecentsActivity or
  RecentsWindowManager.
- When changing Overview targets to RecentsWindowManager, which is not
  an Activity, we still update the TaskbarUIController

Test: Switch between default Home activities with the flag on and off,
ensure Taskbar works as expected in each case (3P vs 1P launcher).
Flag: com.android.launcher3.enable_fallback_overview_in_window
Fixes: 368030750
Fixes: 365775636

Change-Id: Ife775e8c226f8c73ec9e1f97b4a6f2972f6c905f
2024-10-30 20:21:26 +00:00
Yuichiro Hanada ca23e23655 Merge "Move the animator for the minimization to WMShell" into main 2024-10-29 23:19:09 +00:00
Jordan Silva 7054095b16 Add TAPL test for dismiss DesktopTaskView
This CL adds 2 new E2E Tapl tests for checking dismiss DesktopTaskView.
- dismissFocusedTask_thenDesktopIsCentered validates the following scenarios:
  - Scenario: When Focused Task is in the center of the screen, with 1 other task in the grid and 1 desktop task.
  - When focused task is dismissed, the next task in the grid takes its place to be the next focused task at the center of the screen.
  - When the last focused task is dismissed, the desktop task takes its place at the center of the screen.

- dismissDesktopTask_thenFocusedTaskIsCentred validates the following scenarios:
  - Scenario: When Desktop Task is in the center of the screen, with 1 focused task and 1 task in the grid.
  - When focused task is dismissed, the next task in the grid takes its place, adjacent to desktop task.
  - When desktop task is dismissed, the focused task takes its place at the center of the screen.

Fix: 353948500
Flag: com.android.launcher3.enable_large_desktop_windowing_tile
Test: TaplTestsOverviewDesktop
Change-Id: Ie2aa28cd2b30a2bf10e877721416399bcf47acf6
2024-10-28 12:25:25 +00:00
Yuichiro Hanada c90fcf26c4 Move the animator for the minimization to WMShell
to share the animator with the minimize button.

Flag: EXEMPT refactoring
Bug: 369349585
Test: manual
Change-Id: I42325913313a85e1086ab6bc4151f60cb3bc4605
2024-10-28 16:53:47 +09:00
Schneider Victor-Tulias 8463dc47eb Generalize ActivityTracker to support RecentsWindowManager
Continued quick switch couldn't work using existing infrastructure until RecentsWindowManager could be properly tracked by ActivityTracker. Refactored ActivityTracker into ContextTracker to support this.

Also refactored ActivityInitListener into ContextInitListener to fit the updated pattern.

Flag: com.android.launcher3.enable_fallback_overview_in_window
Fixes: 366023051
Test: RecentsWindowSwipeHandlerTestCase; Attempted continued quick switch from home and launched app
Change-Id: Ic38ebf3611ef22fbfd1ddeb79d72d8a3621940a0
2024-10-22 15:29:59 -04:00
Schneider Victor-tulias 892ad69191 Merge "Improve test isolation in AbstractLauncherUiTests" into main 2024-10-17 19:22:37 +00:00
Treehugger Robot fc4420dc3e Merge "Add animation runner for alt-tab desktop app launch" into main 2024-10-17 18:48:31 +00:00
Winson Chung a2dea77229 Using synthetic recents transitions for Recents in Window
Bug: 366021931
Flag: com.android.launcher3.enable_fallback_overview_in_window
Test: manual with enableFallbackOverviewInWindow=true
Change-Id: I26fbc96373b55f0a4a87756fa99347f0e4f4361b
2024-10-16 13:23:17 -07:00
Schneider Victor-Tulias 07669e9575 Improve test isolation in AbstractLauncherUiTests
- Removing suspicious duplicate uses of AbstractLauncherUiTest.initialize to prevent unnecesary launcher restarts
- Adding UiDevice#pressHome to AbstractLauncherUiTests.verifyLauncherState to ensure the next test starts with a known clean state

Flag: EXEMPT test fix
Fixes: 372956489
Test: AbstractLauncherUiTest
Change-Id: Id68ece4ab195a4f6c47aa401eb50a91b8ff70e10
2024-10-16 13:18:36 -04:00
Treehugger Robot 242d5b9e26 Merge "Revert "Add screenrecord for testWorkspaceSwitchToAllApps"" into main 2024-10-15 17:58:28 +00:00
Gustav Sennton 6bb9d56ded Add animation runner for alt-tab desktop app launch
Create a remote transition supporting alt-tab app-launches (app launches
caused by a user using alt-tab to select a minimized app) and any
minimization caused by hitting the window limit during such an app
launch.

Test: manual, and WindowAnimatorTest
Bug: 349791584
Flag: com.android.window.flags.enable_desktop_app_launch_alttab_transitions
Change-Id: I6474fff351f3d7681ca25cd7331e4955e3d1c6e0
2024-10-15 17:34:53 +00:00
Graciela Putri 19c00bb849 Merge "Add task menu item to move task to external display" into main 2024-10-15 16:51:20 +00:00
Federico Baron 44854ed9d5 Revert "Add screenrecord for testWorkspaceSwitchToAllApps"
This reverts commit 1d12cbcd23.

Reason for revert: bug resolved

Change-Id: Ie5a15594cb3b168c5368f6bd54aab2c6a9d718ae
2024-10-15 16:11:10 +00:00
fbaron 1d12cbcd23 Add screenrecord for testWorkspaceSwitchToAllApps
Flag: EXEMPT TEST_ONLY
Test: TaplTestsQuickstep#testWorkspaceSwitchToAllApps
Bug: 371615571
Change-Id: Ib2ce1d1b56b1710e65bad8eaa5de89949ec22c7e
2024-10-14 09:42:20 -07:00
Graciela Wissen Putri 2f4ccc63b6 Add task menu item to move task to external display
Call SystemUiProxy.moveToExternalDisplay to move existing Overview task to desktop in external display

Bug: 372872848
Test: atest
NexusLauncherTests:com.android.quickstep.ExternalDisplaySystemShortcutTest
Flag: com.android.window.flags.move_to_external_display_shortcut
Change-Id: I096a9839956ab5cab86bd0aaabc625a8587ca42a
2024-10-14 15:14:01 +00:00