Commit Graph

2087 Commits

Author SHA1 Message Date
Charlie Anderson
ce255ff6fd Fix NPE for where intent.package is null but targetpkg is not.
- Also update WorkspaceItemProcessorTest with a new test and to use real intent instead of mock

Bug: 330250727
Test: unit tests
Flag: N/A
Change-Id: I77e17901f4754c301ca20b3c6f93bbe29bead59b
2024-04-18 17:48:27 -04:00
Federico Baron
6188ec4157 Merge "Make hotseat column span responsive" into main 2024-04-16 17:17:55 +00:00
Brandon Dayauon
31e713ee4c Merge changes If93e3975,Ifed45f06 into main
* changes:
  Fix views being visible after closing private space.
  Set attach consumer after animation finished
2024-04-16 15:14:26 +00:00
fbaron
e4b0b71faa Make hotseat column span responsive
Flag: NONE
Test: DeviceProfileDumpTest, DeviceProfileAlternativeDumpTest, HomeScreenImageTest
Bug: 325084912
Change-Id: Ifa9e8066662a1ab053f66b8800b739d813d2dab8
2024-04-16 06:19:16 +00:00
Winson Chung
240956e7d8 Merge "Use shared method for updating the runtime status flags for an item info" into main 2024-04-16 02:59:54 +00:00
Stefan Andonian
0d2cc9e87c Merge "Revert^2 "Remove Unused parts of LauncherPrefs causing cyclical dependency."" into main 2024-04-16 02:42:04 +00:00
Stefan Andonian
1a626d2d05 Revert^2 "Remove Unused parts of LauncherPrefs causing cyclical dependency."
This reverts commit a80997d9eb.

Bug: 324670265
Test: Locally tested this, as well as ran it through post-submit via go/abdt with the fix.
Flag: NA
Reason for revert: Root-caused the issue with this, and will push the fix along with this revert.

Change-Id: I4bda53d94dfdb865883fef6ceec9dacd0b87f015
2024-04-15 18:28:25 +00:00
Anushree Ganjam
6642ea0d48 Merge "Add new class for SetPropRule and move outside ShellCommandRule." into main 2024-04-15 17:41:15 +00:00
Brandon Dayauon
a271511240 Set attach consumer after animation finished
Its possible after the animation that attached view's alpha can still be stuck at 0 and never change.
This only happens when the view isn't in range to animate and after onBind() is already called.

Also added flag guarding to the animation as it seems to be forgotten since the big CL change moving
everything to privateProfileManager.

bug: 333506236
Test locally: https://screenshot.googleplex.com/8Kk6rLaczMPwr49 and https://screenshot.googleplex.com/9wXHeNuiCVFEMp6
manually: before https://drive.google.com/file/d/15hSqaUVjwE-lLp6IIv_mqwYbn_ITzR7s/view?usp=sharing
after: https://drive.google.com/file/d/15m7Al5H3vldFgIaQfFyulm1h92_Mgd0H/view?usp=sharing
Flag: ACONFIG com.android.launcher3.Flags.private_space_animation trunkfood

Change-Id: Ifed45f065b536bca5e8878b1bb95d16caf136ed6
2024-04-15 10:12:08 -07:00
Winson Chung
21cf4439d2 Use shared method for updating the runtime status flags for an item info
- The method AppInfo#updateRuntimeFlagsForActivityTarget should also
  both add and remove runtime flags to match the current state

Bug: 323112914
Test: atest NexusLauncherTests
Change-Id: If87acf1e2324f98cf1d96d194eac13a93fa432c1
2024-04-14 06:19:49 +00:00
Anushree Ganjam
8cac99a8dc Add new class for SetPropRule and move outside ShellCommandRule.
Clean up the mEnableInputTransportPublisherRule from TaplWidgetPickerTest since b/325377690 is fixed now.

This is follow up for ag/26419353.

Bug: 325377690
Test: Manual
Flag: NA
Change-Id: Id55000ac3cb4b88097ad00b97773c39a725711b8
2024-04-12 16:45:18 -07:00
Jagrut Desai
49d4429881 Fixing TaplUninstallRemoveTest#uninstallWorkspaceIcon test
Test: Presubmit
Bug: 319501259
Flag: NONE
Change-Id: I9566b947bc7d5d64953a8c637fefd4fa37cca87c
2024-04-12 11:37:27 -07:00
Vadim Tryshev
2a6ce15290 Merge "Removing users synchronously" into main 2024-04-12 17:19:36 +00:00
Brandon Dayauon
c1de065650 Merge "Fix stale header height being used in scroll to header calculation" into main 2024-04-12 17:00:40 +00:00
Brandon Dayauon
5da04b231f Fix stale header height being used in scroll to header calculation
- This fixes the inconsistency of how far down is needed to scroll to since
the values used to calculate the header during drawOnScrimWithScaleAndBottomOffset() is faulty.
- Tweaked the row to scroll to when there are tabs vs no tabs. When there are no tabs, its possible the
header gets cut off most of the time hence subtracting by 1 will help this problem.

bug:332543940
Test locally: https://screenshot.googleplex.com/5y4vYiQcnSMKcA6
manual - before: https://drive.google.com/file/d/14Zj_FyO-3bVfXwuxaqgG_DXMELYS5bQn/view?usp=sharing
after with tabs:
after 5x5: https://drive.google.com/file/d/16rjaut6VqBMxG6uLQSnVTLRhUQnAANZ5/view?usp=sharing
after 4x5: https://drive.google.com/file/d/16jCPN8BewwuIQobt0t6tdVouUKpp1CdI/view?usp=sharing
after 4x4: https://drive.google.com/file/d/16VFQb5s6IfrpjRU9PmLlAJWjh1zIo77o/view?usp=sharing
after 3x3: https://drive.google.com/file/d/16VFQb5s6IfrpjRU9PmLlAJWjh1zIo77o/view?usp=sharing
after 2x2: https://drive.google.com/file/d/16N6Myuv9VtXgI1p4sIuV23iupea7jYLQ/view?usp=sharing

after no tabs:
after 5x5: https://drive.google.com/file/d/17H1oF_9fJnrtSqmJJqQyyn4upuM2CsoG/view?usp=sharing
after 4x5: https://drive.google.com/file/d/178Vu3SvnvSPODIfaR0oz6-jPVYDDNMaA/view?usp=sharing
after 4x4: https://drive.google.com/file/d/16yt_5ePPR7kwSrZlo5Sj3x0DqHoQKqYP/view?usp=sharing
after 3x3: https://drive.google.com/file/d/17HqebtHWcEHg-i9AfqHEVdl4YnQhX06P/view?usp=sharing
after 2x2: https://drive.google.com/file/d/17HqebtHWcEHg-i9AfqHEVdl4YnQhX06P/view?usp=sharing

after tablet:
landscape: https://drive.google.com/file/d/16JQGs0A3ifKpgqrpQwIzssrXbH-OC0Ej/view?usp=sharing
portrait: https://drive.google.com/file/d/16LmLnOEB6XkuAkAcgvP2mKHe5QQqG1oh/view?usp=sharing

Flag: ACONFIG com.android.launcher3.Flags.private_space_animation TRUNKFOOD

Change-Id: If8a70cc71e9cff4a7f8d3b648e3e59c414e40ee5
2024-04-11 16:22:11 -07:00
Vadim Tryshev
2c72271915 Removing users synchronously
Bug: 302400996
Test: presubmit
Flag: N/A
Change-Id: Iac1863039cbb9d612abe416b7aee135eec25f223
2024-04-11 15:59:41 -07:00
Randy Pfohl
c21b0000b5 Revert^2 "fixing tests to match new abstraction"
8e4c0b7afb

Change-Id: I9875d6f9c16f1406d0818164a98e790c2b101650
2024-04-11 08:58:22 -07:00
Priyanka Advani
8e4c0b7afb Revert "fixing tests to match new abstraction"
Revert submission 26414135-RecentsViewContainer

Reason for revert: Probable culprit for b/333767026. Will be verifying through ABTD for confirmation and before submitting the revert.

Reverted changes: /q/submissionid:26414135-RecentsViewContainer

Change-Id: Ibafc66cf3677d24e7912d55cb45c948cb6519df7
2024-04-10 21:31:14 +00:00
randypfohl
f75709e78b fixing tests to match new abstraction
This change will let us move from activity to other parent views for recent viewss

Change-Id: I2424d94f799f87b2d2262da96b289aac6dfadee9
2024-04-10 09:14:38 -07:00
Sunny Goyal
efc3c46419 Fixing null check causing test breakage
Bug: 333609600
Test: Presubmit
Flag: None
Change-Id: Ic44df00ba945c79010c2cf99a034cca2b5d6c161
2024-04-09 17:04:46 -07:00
Sunny Goyal
3b00e7909a Merge "Using resource override instead of code-swap for ApiWrapper" into main 2024-04-09 20:33:20 +00:00
Alex Chau
55ef24c229 Merge "Add task menu item to move task to Desktop" into main 2024-04-09 20:31:47 +00:00
Sunny Goyal
11117d9b2a Using resource override instead of code-swap for ApiWrapper
Bug: 330920490
Flag: None
Test: Presubmit
Change-Id: Iac19f32e64d2c76ed5b4f8592943ee4ae7af51b5
2024-04-09 11:14:44 -07:00
Vadim Tryshev
5940c59a2c Merge "Honoring @PortraitLandscape annotation in presubmit" into main 2024-04-09 16:26:14 +00:00
Alex Chau
3c0729c462 Add task menu item to move task to Desktop
- Call SystemUiProxy.moveToDesktop to move existing Overview tasks to desktop
- Animation polish will be handled separately
- Refactored AbstractFloatingView method into a helper to allow testing

Fix: 320310347
Test: DesktopSystemShortcutTest, AbstractFloatingViewHelperTest
Flag: ACONFIG com.android.window.flags.enable_desktop_windowing_mode DEVELOPMENT
Change-Id: I2e4e04182e46ba4750e0683ee1789ba8fada06ea
2024-04-09 16:35:55 +01:00
Uwais Ashraf
7a0150d02e Use script to auto-enable all tests that are currently working
Fix: 325088906
Test: presubmits passing, gradle robo run passing locally
Flag: NA
Change-Id: I481bfe9caeb8cc18b3e01ec8b7a58fb0eb36fdaa
2024-04-08 20:59:23 +00:00
Treehugger Robot
adbdfe2ac7 Merge "Fix failing LauncherIntentTest." into main 2024-04-08 16:43:28 +00:00
Sebastián Franco
5ccac93d0a Merge "Adding even more tracing for the tests" into main 2024-04-05 18:26:54 +00:00
Himanshu Gupta
b04262784d Fix failing LauncherIntentTest.
Bug: 332894108
Test: atest Launcher3Tests
Flag: NA
Change-Id: I654a45d5a9371aa9da74ae89a0513bf203e27981
2024-04-05 18:11:06 +01:00
Brandon Dayauon
bcb6a62297 Merge "Apply icon alpha animation to expand/collapse private space." into main 2024-04-05 04:18:48 +00:00
Brandon Dayauon
5cbe7605f6 Apply icon alpha animation to expand/collapse private space.
This change is more so to the Alt 3 motion spec:
https://docs.google.com/presentation/d/1zRwJ8cZbwMleXHfC2hX4CJJMGSI954FK0V3ksXl7fyE/edit#slide=id.g2baced0bfd0_1_25

bug: 299294792
bug: 325455879
Test: locally: https://screenshot.googleplex.com/BYCwSH3yRvkkZ3v and https://screenshot.googleplex.com/44byrRx5GUQkncw
manual video:
expand and collapse from header: https://drive.google.com/file/d/1-qRdcbo6lNvUPOx4QWL6wVhTRzl2TVtE/view?usp=sharing
from toast and close container after locking: https://drive.google.com/file/d/1-ix4CcOIzMhsJH3uZdJA1vcV8BvY91T9/view?usp=sharing
Flag: ACONFIG com.android.launcher3.Flags.private_space_animation TRUNKFOOD

Change-Id: I4cde4b8626cf3271880fee697f2fb6bc780eab60
2024-04-04 14:54:28 -07:00
Vinit Nayak
247c6ac8ec Merge "Allow app pairs in folders" into main 2024-04-04 17:55:34 +00:00
Treehugger Robot
14381e119d Merge "Fix failing test." into main 2024-04-04 11:18:25 +00:00
Jeremy Sim
a596f589c4 Allow app pairs in folders
This CL substantially refactors folders to be able to take contents of type AppPairInfo. App pairs can now be moved in and out of folders, and launch from folders.

This CL contains only logic and model changes; animation and style changes (for dropping items into folders, color changes to app pair surfaces, etc.) will be in a following CL. Another CL (hopefully) will contain tests. I'm planning to submit them together, but this patch should also be able to stand alone with no issues (except janky transitions).

Bug: 315731527
Flag: ACONFIG com.android.wm.shell.enable_app_pairs TRUNKFOOD
Test: Manual, more to follow in another CL.
Change-Id: I73732fcaefbdc61bf6e02a5be365962b8bbc3e41
2024-04-03 16:47:42 -07:00
Himanshu Gupta
2cf24c84bf Fix failing test.
Moving to All Apps view is not required as we are
already on the same view during `moveToSearchView`
invocation.

Bug: 329152799
Test: LauncherIntentTest#testAllAppsIntent
Flag: NA
Change-Id: Ia618eaa1999a9db663dd09bb7c150b5a51dedc36
2024-04-03 18:51:33 +01:00
Sebastián Franco
0e0a7ed6ba Merge "Adding screen record to testEmptyPageDoesNotGetRemovedIfPagePairIsNotEmpty" into main 2024-04-03 15:26:31 +00:00
Sebastián Franco
966156e363 Merge "Fix widget dissapearing because of change of appWidgetId" into main 2024-04-02 18:52:21 +00:00
Sebastian Franco
2b724ec00d Adding screen record to testEmptyPageDoesNotGetRemovedIfPagePairIsNotEmpty
Bug: 329935119
Test: NA
Flag: NA
Change-Id: I86c0620d6207b09f04c8038932ed34f4444a6626
2024-04-02 11:42:17 -07:00
Sebastian Franco
951138676e Adding even more tracing for the tests
I want to see how far back the resolution of the test is not
working properly.

Bug: 322823478
Test: NA
Flag: NA
Change-Id: If6d63ad5b350e67e10d515292f47c9e0c13e01b2
2024-04-02 11:03:09 -07:00
Sebastian Franco
3d04c1f3fc Fix widget dissapearing because of change of appWidgetId
When migrating the widgets might dissapear because the appWidgetId
can change and when migrating it's no longer valid.

Bug: 324931424
Bug: 330583877
Test: ValidGridMigrationUnitTest
Test: GridMigrationTest
Flag: NA
Change-Id: Ie41a01470814b252f6bb7e4409d3382951a1d70d
2024-04-01 20:19:20 -07:00
Vadim Tryshev
c22a62a1a4 Honoring @PortraitLandscape annotation in presubmit
Bug: 187761685
Test: presubmit
Flag: N/A
Change-Id: Icf0d06fc244e894ab8d5c9e8c5cddeb78b847a26
2024-04-01 18:06:25 -07:00
Jeremy Sim
da4ba9336e Merge "Reparent folders and app pairs" into main 2024-03-30 03:06:44 +00:00
Jeremy Sim
742630c2f8 Reparent folders and app pairs
Previously, app pairs and folders shared a common data model, FolderInfo. Now we need to separate them, so a new type, CollectionInfo, will serve as the parent of both types.

Bug: 315731527
Fixes: 326664798
Flag: ACONFIG com.android.wm.shell.enable_app_pairs TRUNKFOOD
Test: Manual, unit tests to follow
Change-Id: Ia8c429cf6e6a376f2554ae1866549ef0bcab2a22
2024-03-29 15:39:28 -07:00
Brandon Dayauon
4958ecfadb Merge "Move adding views logic to privateProfileManager" into main 2024-03-29 04:03:42 +00:00
Brandon Dayauon
136f9d6f8a Move adding views logic to privateProfileManager
- Have the animation happen according to the state of private space.
- Have the transition happen only once by setting the current transition to null at the end of transition and by ensuring
where the transitions are allowed.
- Removing controller class.

- The onClick controls the enablement of the profile. On reset (when getting the transition) is what controls the animation
during expand.

tldr- In the collapse case:  execute() is called -> animation happens  -> addPsHeader
tldr- Expand case: post() is called -> addPsHeader -> animation happens.

Collapse:
onClick() -> AACV.onAppsUpdated() that resets & apply/RUNS runnable because EXECUTE
-> AAList.onAppsUpdated() (which is called at the same time animating happens which we should cancel and do at end callback)
-> AAList.onAppsUpdated() gets called again

Expand:
onCLick() -> AACV.onAppsUpdated() that resets & apply runnable
-> AAList.onAppsUpdated() (no animation running)
-> AAList.onAppsUpdated() (no animation running)
-> addPrivateSpaceHeader
-> then unlockAction() runnable because its posted at this point

bug: 326206132
bug: 330444548
bug: 299294792
Test: manually locally and presubmit: https://screenshot.googleplex.com/9wavvwKQ8hY6oUw & https://screenshot.googleplex.com/BiqmidLFjPwS28j
video: https://drive.google.com/file/d/1XGhmTncdUFtJj188_l7alGyyNz_fhXNw/view?usp=sharing

Scrolling fix before: https://drive.google.com/file/d/1XykDm4UELoCvcwZdj8ZlJ6TszptB8W0W/view?usp=sharing
scrolling fix after when not a lot of apps: https://drive.google.com/file/d/1Y4VY1eX7WE8ShSLXRrT56ieBdAuJo_zn/view?usp=sharing
scrolling fix after with a lot of apps: https://drive.google.com/file/d/1Y58c-Z9xnU1GILp0Ih-oLORXYkMB-jWn/view?usp=sharing
Flag: ACONFIG com.android.launcher3.Flags.private_space_animation

Change-Id: I8d03ae60e2c9fe0ec145c4b0a2e9604b9e6e9017
2024-03-28 17:39:42 -07:00
Sebastián Franco
0ec7c1e4a8 Merge "Generate grid migration cases and test if they are valid" into main 2024-03-28 16:31:37 +00:00
Sebastian Franco
efab2489d6 Generate grid migration cases and test if they are valid
This makes sure the grid migration logic always produces
valid results.

Bug: 313900847
Bug: 323525592
Flag: NA
Test: ValidGridMigrationUnitTest.kt
Change-Id: I76b19e1fa315f8a997afad34e5a4df7cc465b0c2
2024-03-27 14:03:07 -07:00
Sunny Goyal
77954bae4e Cleaning up some build configurations
> Removing Launcher3Go-without-quickstep
> Removing src_ui_overrides to src_no_quickstep
> Removing unnecessary code swpa for GO builds

Bug: 330920490
Flag: None
Test: Presubmit, everything builds
Change-Id: I5746dbc7c5a37c1d99d78b55bf2a6adce1a711c9
2024-03-26 17:16:52 +00:00
Schneider Victor-tulias
02e57b3d62 Add ExtendedLongPressTimeoutRule to all AbstractLauncherUiTest
When devices run slow in pre/post-submit, it is possible for a drag to be processed at a long press before the first move event can be created and dispatched. Added a rule to artificially increase this long press timeout in tests.

Flag: N/A
Fixes: 319257820
Test: TAPL tests
Change-Id: I24e0f3baec15db7558351d0cb2bd93a4e49640e8
2024-03-25 11:22:31 -04:00
Treehugger Robot
9a8a3091ba Merge changes from topic "revert-26664190-revert-26605558-robolectric-enable-androidx-rules-OWMAZEJUYZ-JTFGVYILBL" into main
* changes:
  Revert^2 "Move FastBitmapDrawableTest to Robolectric"
  Revert^2 "Include AndroidX test rules in Robolectric tests"
2024-03-23 00:14:35 +00:00