Commit Graph

77151 Commits

Author SHA1 Message Date
Fengjiang Li 2b5deb2fb9 Merge "[Test Week] Add VibratorWrapperTest" into main 2024-07-19 23:28:13 +00:00
Fengjiang Li 979adecc7b [Test Week] Add VibratorWrapperTest
Number of new tested methods: 9

Bug: 353303621
Test: This is the unit test
Flag: NONE - unit test
Change-Id: Id6dde920d6365823cf859e97c7c0cfbb25e7270d
2024-07-19 14:10:32 -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 f3fde3f58c Merge "[Test week] add tests for InstallSessionHelper" into main 2024-07-19 18:00:20 +00:00
Sihua Ma f2abd671d1 Merge "Add unit test for RoundedCornerEnforcement" into main 2024-07-19 17:13:08 +00:00
Fengjiang Li 1749bf0308 Merge "[Test Week] Add missing @RunWith(AndroidJUnit4.class) annotation" into main 2024-07-19 17:07:39 +00:00
Fengjiang Li 74861537f6 Merge "[Test Week] Add ScreenOnTrackerTest" into main 2024-07-19 17:07:26 +00:00
Sebastián Franco 5217ae7fa3 Merge "Refactoring FolderPagedView to make it more testable" into main 2024-07-19 16:59:35 +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
Charlie Anderson b6e8ab0d21 [Test week] add tests for InstallSessionHelper
9 public methods tested
no previous test class

Bug: 353303621
Test: unit tests
Flag: TEST_ONLY
Change-Id: Ib113c00c10ed0aca8c996db493a84077026bf6c8
2024-07-19 09:46:40 -04: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
Johannes Gallmann 35f77be929 Merge "Fix onUserInteraction not called with 3-button-nav and enableOnBackInvokedCallback=true" into main 2024-07-19 09:46:51 +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
Fengjiang Li b7b3137261 [Test Week] Add ScreenOnTrackerTest
Number of new tested methods: 5

Bug: 353303621
Test: This is the unit test
Flag: NONE - unit test
Change-Id: Ieae1ed9bb215a52a12fef919c8dd407291c2b0f9
2024-07-19 00:49:58 -07:00
Fengjiang Li cda1c12ebe [Test Week] Add missing @RunWith(AndroidJUnit4.class) annotation
Bug: 353303621
Test: This is the unit test
Flag: NONE - unit test
Change-Id: Ieb8f8ac3a8a94defe5f9ed2b8ca9812fd2ac1ba6
2024-07-18 22:29:18 -07:00
Fengjiang Li 3a33017797 Merge "[Test Week] Add SystemUiControllerTest" into main 2024-07-19 03:00:19 +00:00
Liam Lee Pong Lam 0002e9cfc9 Merge "Add unit tests for SettingsChangeLogger" into main 2024-07-19 01:53:21 +00:00
Andrew Cole 4a680b1374 Merge "Test Week - AccessibleDragLstenerAdapterTest" into main 2024-07-19 00:53:21 +00:00
Fengjiang Li abc4a9589a Merge "[Test Week] Add AllAppsRecyclerViewPoolTest" into main 2024-07-19 00:33:51 +00:00
Fengjiang Li a74d9d74c9 Merge "[Test Week] Add ViewPoolTest" into main 2024-07-19 00:33:38 +00:00
Fengjiang Li 5337a1ba31 Merge "[Test Week] Replace verifyZeroInteractions with verifyNoMoreInteractions in RunnableListTest" into main 2024-07-19 00:31:51 +00:00
Jon Miranda 6d5ab854d1 Merge "Synchronize the app launch and taskbar stash animations." into main 2024-07-19 00:26:33 +00:00
Jon Miranda cde962dcb7 Synchronize the app launch and taskbar stash animations.
Introduce FLAG_IGNORE_IN_APP to prevent taskbar from stashing prematurely
due to HomeTransitionListener signal.

Bug: 345768019
Fixes: 319162553
Test: Launch an app, note the two animations are synced
      Verified by locally introducing a startDelay (since otherwise it is hard to tell)
Flag: com.android.launcher3.enable_scaling_reveal_home_animation
Change-Id: Ibb64e0321f33cf81e337fc7c1b2c3edfb23e6ba4
2024-07-19 00:26:13 +00:00
Sihua Ma cda4805e62 Add unit test for RoundedCornerEnforcement
Number of methods covered: 4

Test: atest NexusLauncherRoboTests:RoundedCornerEnforcementTest
Test: SysUI studio
Flag: TEST_ONLY
Bug: 353303621
Change-Id: I488ce4a6617b96d4937a7030cd25831bcefadca1
2024-07-18 23:57:09 +00:00
Sebastian Franco cda3427fea Refactoring FolderPagedView to make it more testable
Bug: 353588686
Test: FolderPagedViewTest.kt
Flag: TEST_ONLY
Change-Id: I2a2efd9f9b2a6ac32153f8102613a3af5afc1ecf
2024-07-18 23:33:21 +00:00
Mykola Podolian e80618db64 Merge "Prepare BubbleBarViewController to support persistent task bar." into main 2024-07-18 23:16:47 +00:00
Fengjiang Li f257aef6d7 [Test Week] Add SystemUiControllerTest
Number of new tested methods: 4

Bug: 353303621
Test: This is the unit test
Flag: NONE - unit test
Change-Id: I2c2b8101853b4b5a6562fe26dfa6b7358f0be17e
2024-07-18 15:47:26 -07:00
Fengjiang Li 5ad7a20e90 [Test Week] Add ViewPoolTest
Number of new tested methods: 3

Bug: 353303621
Test: This is the unit test
Flag: NONE - unit test
Change-Id: I13f1a7bad41c07368cff3d544120d1f41c92b603
2024-07-18 15:25:07 -07:00
Fengjiang Li 30d02c20bf [Test Week] Add AllAppsRecyclerViewPoolTest
Number of new tested methods: 2

Bug: 353303621
Test: This is the unit test
Flag: NONE - unit test
Change-Id: Ic210b5ad7988c9e8d060c959fb2a425068c82511
2024-07-18 15:19:42 -07:00
Fengjiang Li 2eeb08f216 [Test Week] Replace verifyZeroInteractions with verifyNoMoreInteractions in RunnableListTest
Fix: 354021767
Bug: 353303621
Test: This is the unit test
Flag: NONE - unit test
Change-Id: I85945c0a0f64ca0a65d28d66f3c47d83d0943c3b
2024-07-18 15:05:10 -07:00
Fengjiang Li f28a059e5b Merge "[Test Week] Move SimpleBroadcastReceiver to multivalentTests folder" into main 2024-07-18 21:06:30 +00:00
Brandon Dayauon 3188bd08ae Merge "Don't add floatingMaskView if it will not fit." into main 2024-07-18 20:53:14 +00:00
Andrew Cole 6ace1c0d3a Test Week - AccessibleDragLstenerAdapterTest
Refactored AccessibleDragListnerAdapter to kotlin for null safety and removed a explicit call to Launcher. Added tests for all public methods
* Refactored 1 class
* Tested 1 class previously untested
* Tested 4 public methods

Bug: 353303621
Test: AccessibleDragListnerAdapterTest
Flag: TEST_ONLY

Change-Id: I7db70330f5e76b8f7298304314584e88e067c139
2024-07-18 12:34:17 -07:00
Charlie Anderson c22b0ea47b Merge "[Test Week] unit tests for LauncherRestoreEventLoggerImpl" into main 2024-07-18 18:44:15 +00:00
Charlie Anderson ba9705c4ab Merge "[Test week] unit tests for ItemInfoMatcher" into main 2024-07-18 18:44:05 +00:00
Liran Binyamin a2aa555faf Merge "Update bubble notification dot drawing" into main 2024-07-18 18:42:01 +00:00
Shamali P 54bd36ef81 Move out picker related methods from widgets model
* The WidgetsBaseEntry and related types are specific to picker UI.
So, moved them to a entry builder class.

Bug: 353347512
Flag: EXEMPT BUGFIX
Test: Unit test
Change-Id: I42b3083b42ee03dc8d548e7464689ea270a36f22
2024-07-18 18:35:19 +00:00
Liam, Lee Pong Lam c56711c669 Add unit tests for SettingsChangeLogger
Bug: 353584526
Flag: EXEMPT bugfix
Test: Unit tests
Change-Id: Ib1bac2471d9cc467b8b6697ae4d79f561eea75e4
2024-07-18 18:32:36 +00:00
mpodolian f667c3bc3b Prepare BubbleBarViewController to support persistent task bar.
Added required resources for the transient taskbar. Unified
BubbleBarViewController logic for the persistent taskbar.

Bug: 350065038
Flag: com.android.wm.shell.enable_bubble_bar
Test: atest
Change-Id: I24e6d2d43bf8145cdcc71c75da0cb6f6e84373da
2024-07-18 19:17:12 +01:00
Sebastián Franco 45bad7252e Merge "Refactoring FolderPagedView to make it more testable" into main 2024-07-18 17:02:54 +00:00
Alex Chau 1c1547f5f9 Merge "Enable RecentsModel cache preloading for TTV refactoring" into main 2024-07-18 16:45:43 +00:00
Alex Chau 7e26ff8063 Enable RecentsModel cache preloading for TTV refactoring
- Enabled preloading so thumbnails are loaded faster after Launcher restarts

Fix: 353927953
Test: Manual
Flag: com.android.launcher3.enable_refactor_task_thumbnail
Change-Id: I8710495dee672eb0449c01522451578f30ad84aa
2024-07-18 16:44:35 +00:00
Jorge Gil e2c2302aef Merge "Re-enable FREEFORM task shortcut when DW is unsupported" into main 2024-07-18 16:30:20 +00:00
Alex Chau 33d0b14384 Merge "Update bug id of a TODO" into main 2024-07-18 16:21:31 +00:00
Fengjiang Li 5c4c3bcbf3 [Test Week] Move SimpleBroadcastReceiver to multivalentTests folder
Bug: 353303621
Test: This is the unit test
Flag: NONE - unit test
Change-Id: I82a59b6d090df7a246ba283bbfa286c99417c876
2024-07-18 09:20:49 -07:00
Charlie Anderson 48ff57d7d1 [Test week] unit tests for ItemInfoMatcher
7 public methods tested
no previous test class

Flag: TEST_ONLY
Bug: 353303621
Test: unit tests
Change-Id: Ie327ab790b46326ee97165706c126c8ad0de7776
2024-07-18 11:59:01 -04:00