Commit Graph

10437 Commits

Author SHA1 Message Date
Charlie Anderson
511421c12f Adds logging for Launcher restore metrics in Launcher and LoaderTask
- Adds flag for indicating when we are loading after a restore, separate from the pending restore flag
- Adds many success/failure scenario metrics when loading and binding items

Flag: ACONFIG enable_launcher_br_metrics DEVELOPMENT
Test: locally verified
Bug: 307527314
Change-Id: I9d2660f6d9d7cd5813072201e96b1a64aec4ea4b
2023-12-18 19:32:02 +00:00
Greg Kaiser
486c96be87 Merge "Revert "App Pairs: Implement Overview Actions View button"" into main 2023-12-18 15:15:59 +00:00
Greg Kaiser
45ba84268c Revert "App Pairs: Implement Overview Actions View button"
Revert submission 25143701-app-pairs-action-button

Reason for revert: Causes P0 b/315292030

Reverted changes: /q/submissionid:25143701-app-pairs-action-button

Change-Id: I1fcbb9f333ca29c5db255232dc9475dec465ac81
2023-12-18 14:53:19 +00:00
Liran Binyamin
ca516b0249 Merge "Make BubbleBarView initially hidden" into main 2023-12-18 14:23:57 +00:00
Jeremy Sim
789414190f Merge "App Pairs: Implement Overview Actions View button" into main 2023-12-18 05:07:36 +00:00
Jeremy Sim
e1fcb5390b App Pairs: Implement Overview Actions View button
[App Pairs 6/?]

This patch includes:
- Ability to "save app pair" from Overview Actions
- The actions bar is not longer hidden for GroupedTasks; instead the individual buttons for "Select", "Screenshot", and "Split screen" are toggled off and "Save app pair" is toggled on.

Note: This patch introduces a slight regression (b/315545418) where users are now able to long-press to select text on task 1 of a paired GroupedTaskView (previously we did not let them select text on either task for consistency.) Will follow up with a fix -- see bug for details.

Flag: ACONFIG com.android.wm.shell.enable_app_pairs DEVELOPMENT
Bug: 315545418
Bug: 315292030
Test: Manual, all action buttons still work and "Save app pair" appears and disappears correctly
Change-Id: I0eb1fa9520ba14074ede3480e771b340cf2f6e2c
2023-12-18 02:25:22 +00:00
William Leshner
c43435c063 Merge "Handle widget taps in WidgetPickerActivity." into main 2023-12-15 23:20:23 +00:00
Liran Binyamin
447ddf0b63 Make BubbleBarView initially hidden
The BubbleBarView visibility is updated as part of the initial state change.
This CL fixes the issue where switching from floating bubbles to bubble bar
ends up in a state where both the handle and the bar are visible.

Note: once the initial TAPL tests land I will add a test for mode switching

Flag: LEGACY persist.wm.debug.bubble_bar DISABLED
Fixes: 316356971
Test: Manual
      - Add bubble in floating mode
      - Switch to bubble bar
      - Observe that the bubble bar is not visible (only the handle is)
Change-Id: Ib8fc76f90dbf1fee83e594b7f28eed00f1589ae1
2023-12-15 15:49:37 -05:00
Jeremy Sim
8379c985f0 Merge "Fixes crash when launching app pairs with intent+intent" into main 2023-12-15 09:50:00 +00:00
Jeremy Sim
9330619ee0 Fixes crash when launching app pairs with intent+intent
This CL adds a new case for app pair launches. When we launch app pairs with intents, we receive initialTaskId and secondTaskId as -1, which was previously unhandled and caused a crash. With this change, we find the left/top app leash a different way, by looking for windowingMode=WINDOWING_MODE_MULTI_WINDOW and endAbsBounds.left/top == 0.

Fixes: 316050315
Test: Clear all running tasks from Overview, launch app pair, no longer crashes
Flag: ACONFIG com.android.wm.shell.enable_app_pairs DEVELOPMENT
Change-Id: Ic356d71ad267f079242213ebc59322bf1fb86b7c
2023-12-15 17:17:24 +09:00
Tracy Zhou
3e3ee0b190 Merge "Fix crash from folding/unfolding" into main 2023-12-15 03:49:38 +00:00
Tracy Zhou
95c4c8d268 Fix crash from folding/unfolding
This is fundamentally caused by the phone device profile not having task bar related attributes, which crashes in icon alignment animation. We had resolved it by skipping this animation based on isPhoneMode check. However, we passed in launcherDp instead of taskbarDp (from TaskbarActivityContext) which doesn't always have the most up to date information in race conditions (e.g. repetitively fold/unfold)

Fixes: 311431054
Test: repetively fold/unfold, make sure it doesn't crash
Change-Id: I65f600112da4123d337b3f59a2fe6dd13ac7af74
2023-12-14 18:39:42 -08:00
Anushree Ganjam
493ee68819 Merge "[Refactor] Use constants from Cuj.java instead of InteractionJankMonitorWrapper." into main 2023-12-14 19:14:28 +00:00
Tony Wickham
2c00a542c2 Merge "Fix layering issue when launching from side TaskView" into main 2023-12-14 01:05:01 +00:00
Anushree Ganjam
b8a71816e1 [Refactor] Use constants from Cuj.java instead of InteractionJankMonitorWrapper.
Bug: 303105164
Test: Manual
Flag: NA
Change-Id: I05a36fc0421502cd472dd79035b73a69d05592d2
2023-12-13 16:43:16 -08:00
Saumya Prakash
fc97e5339b Merge "Check that onAttach() is called before onResume() to prevent NPE." into main 2023-12-13 20:57:20 +00:00
Tony Wickham
1e60b1a4c4 Fix layering issue when launching from side TaskView
Fully reverted the change in ag/24840504, and instead make use of
prefixOrderIndex to ensure translucent overlays launch on top of
the underlying task.

Test: Swipe up from an app to Overview (phone), scroll over one
task, click on the live tile you came from; ensure animates well
Test: Open an app, launch a translucent overlay, e.g. Volume
Dialog, swipe up to Overview and relaunch the live tasks; ensure
the overlay stays on top throughout the animation
Fixes: 310765248
Flag: ACONFIG com.android.launcher3.enable_grid_only_overview TEAMFOOD

Change-Id: I0708bf3c060ba84089722d0bd9480a4f4bd2b8e2
2023-12-13 19:59:08 +00:00
Charlie Anderson
797ed83700 Merge "Add wrapper for logging backup & restore metrics from Launcher" into main 2023-12-13 19:33:26 +00:00
Tracy Zhou
f2643521ec Merge "Introduce taskbar_phone_size" into main 2023-12-13 18:04:04 +00:00
Johannes Gallmann
820460b12a Merge "Fix predictive back to home with pinned taskbar" into main 2023-12-13 15:01:45 +00:00
Tracy Zhou
9ccd5d4257 Introduce taskbar_phone_size
In small screen, we use 48dp for nav bar height, while it's 60dp for task bar.

Bug: 230395757
Test: manual
Change-Id: Ia7083a1b2246981466e1163404c63b645a6bf5b1
2023-12-13 00:38:15 -08:00
Jon @
ea4c701579 Merge "Move taskbar clean up so that it only gets called when user swipes up to go home." into main 2023-12-13 06:52:04 +00:00
Tracy Zhou
f441fd67d3 Make sure the task bar stays unstashed upon configuration change
So we recreate task bars when configuration is changed, if ENABLE_TASKBAR_NAVBAR_UNIFICATION = true. In order for unstashed state to propagate, we need to save STASHED_IN_APP_AUTO in TaskbarSharedState.

Fixes: 311429718
Test: Unstash the task bar in app, rotate, make sure the task bar stays unstashed
Change-Id: I7db773725ea89976612e9e91af5b6911d0ec5fc0
2023-12-12 19:33:42 -08:00
Jon Miranda
20fdc7b508 Move taskbar clean up so that it only gets called when user swipes up to go home.
This fixes the bug where the flag gets set when user taps on nav handle, which
results in the taskbar animation playing.

Flag: N/A
Test: open app
      wait for taskbar to finish stashing*
      tap on nav handle
      nothing happens (desired affect)
      * I will address tapping on taskbar while its animating in a separate change
Bug: 292108880
Change-Id: I75870050225bdd951c69224d272d0bd5a3d6d4ea
2023-12-13 02:51:28 +00:00
Brandon Dayauon
cc5db6183f Merge "Include a developer option sliding flag to toggle the different amount of apps to show" into main 2023-12-13 00:01:08 +00:00
Brian Isganitis
59c8b69ef4 Merge "Split AFVs that controller should not intercept from TYPE_ACCESSIBLE." into main 2023-12-12 20:47:46 +00:00
Jagrut Desai
2be2b93256 Merge "TaskbarPinningController Unit Tests" into main 2023-12-12 16:19:00 +00:00
Sergey Pinkevich
2adff1b7c0 Merge "Update secondary grid translation" into main 2023-12-12 13:06:40 +00:00
Sunny Goyal
6263ac3894 Merge "Adding support for getting task overlay" into main 2023-12-12 08:25:18 +00:00
Jeremy Sim
160225029d Merge "App Pairs: Launch animation" into main 2023-12-12 00:58:49 +00:00
Jagrut Desai
70de8a4823 TaskbarPinningController Unit Tests
Test: Presubmit
Bug: 265439107
Flag: NONE

Change-Id: I5da3558adf88126b07c5d6217ee4fbbcc1e2e348
2023-12-11 14:46:55 -08:00
Brian Isganitis
98057e7451 Merge "Have Taskbar overlay window consume IME insets." into main 2023-12-11 22:21:22 +00:00
Charlie Anderson
489f1ada5c Add wrapper for logging backup & restore metrics from Launcher
Bug: 25177913
Flag: ACONFIG com.android.launcher3.enable_launcher_br_metrics DEVELOPMENT
Test: locally

Change-Id: I220721f705eb7244a1f13ef8997682999d799f51
2023-12-11 17:01:28 -05:00
Tracy Zhou
6c24bf7c8e Merge "Do not set isImmersive in TaskbarDelegate" into main 2023-12-11 22:00:33 +00:00
Tracy Zhou
901b190153 Merge "Pass in navigation bar panel context created by task bar when taskbar navbar unification is on" into main 2023-12-11 21:47:59 +00:00
Brian Isganitis
7eae1e6124 Split AFVs that controller should not intercept from TYPE_ACCESSIBLE.
TYPE_ACCESSIBLE no longer works for certain cases (see bug). This also
simplifies TouchControllers that would otherwise add or remove from
TYPE_ACCESSIBLE (such as ALL_APPS_EDU and TASKBAR_OVERLAYS).

Fix: 315507902
Test: Manual
Flag: N/A
Change-Id: I6f5d218dab87a8bcc8e7805d0ced9a6678f09c8e
2023-12-11 21:31:38 +00:00
Saumya Prakash
ec514d054c Check that onAttach() is called before onResume() to prevent NPE.
Sometimes, the context is null in TutorialController which leads to an
NPE when relying on context specific functions. This change checks that
context is null and if so, defers the context specific functions that are
called until after onAttach() is called.

Fix: 307781152
Test: Set context to null in onResume() and check that the tutorial
continues like normal
Flag: None

Change-Id: I66e345f8361315787534bb88b9c1d12278708d78
2023-12-11 15:59:24 -05:00
Brian Isganitis
36ffc96382 Have Taskbar overlay window consume IME insets.
Test: Manual
Flag: N/A
Fix: 301321668
Change-Id: Ia12dec7560bd3a0269a9efdccaecc032c70b1630
2023-12-11 19:50:53 +00:00
Brandon Dayauon
96901c4541 Include a developer option sliding flag to toggle the different amount of apps to show
Bug: 299294792
Test: Verified SearchTransitionController didn't regress by turning off BACKGROUND_DRAWABLES flag.
Flag: ACONFIG com.android.launcher3.Flags.enable_private_space DEVELOPMENT
Change-Id: I78ee3a9dbc2d60f1b7acaa5834a8c656217a07d8
2023-12-11 11:27:31 -08:00
Sergey Pinkevich
83462a488b Update secondary grid translation
In order to properly animate task on the vertical axis we need to update `taskSecondaryTranslation`.

Bug: 304782953
Flag: ACONFIG com.android.launcher3.enable_grid_only_overview TEAMFOOD
Test: manual

Change-Id: I1afe78d4eb1575e9c967ff594cffedd7d3620541
2023-12-11 15:25:29 +00:00
Tracy Zhou
f3e5382042 Do not set isImmersive in TaskbarDelegate
allow_gesture and immersive_mode are opposite of each other, and currently we set one or another, check one or another in different places. We should consolidate the two. Hence, we are removing all references of immersive_mode (allow_gesture has more usages).

Bug: 313033827
Test: N/A
Change-Id: I52d86c37cb39ef0bc04a04a0fa78d2b051a0e56e
2023-12-10 21:18:22 -08:00
Jeremy Sim
23fcbf2f73 App Pairs: Launch animation
[App Pairs 7/?]

This patch implements the app pair launch animation from icon. Adds a new function, composeFadeInSplitLaunchAnimator(), in SplitAnimationController, that builds the combined launcher + shell animation.

Bug: 309618233
Flag: ACONFIG com.android.wm.shell.enable_app_pairs DEVELOPMENT
Test: Manual
Change-Id: I8e95f629ae2a71f1bd6cbb356f5e33233e5c2906
2023-12-11 13:09:06 +09:00
Jeremy Sim
d761f5c3bd Merge "App Pairs: Implement Taskbar functionality" into main 2023-12-09 02:20:45 +00:00
Vadim Tryshev
151751c014 Merge "Fixing non-sending wallpaper animation finish event" into main 2023-12-08 23:33:53 +00:00
Jeremy Sim
2987d95ba4 App Pairs: Implement Taskbar functionality
[App Pairs 8/?]

This CL adds taskbar functionality for app pairs:
- Ability to drag an app pair icon to Taskbar
- App pair launch from Home Taskbar
- App pair launch from Overview Taskbar
- App pair launch from in-app Taskbar

KNOWN ISSUES:
- Bug (b/315190686): if user is inside a running split pair and attempts to launch the same pair from an app pair icon on taskbar, Overview tiles get temporarily messed up (recoverable by leaving Overview)
- User can attempt to split with an app pair icon on the Taskbar. This should result in a "can't split with this" bounce animation on the SplitInstructionsView (to be implemented). Currently does nothing.

Bug: 274835596
Flag: ACONFIG com.android.wm.shell.enable_app_pairs DEVELOPMENT
Test: Manual
Change-Id: I5256547af236fc2deeb192d60bfe1f2b7ddc5647
2023-12-08 15:07:45 -08:00
Saumya Prakash
55fdc45ecc Merge "Ensure Taskbar stashes when launching an app from folder" into main 2023-12-08 22:59:45 +00:00
Sunny Goyal
41aca1e7b3 Adding support for getting task overlay
Test: Verified the flow in Launcher
Bug: 273828110
Flag: LEGACY USE_ACTIVITY_OVERLAY DISABLED

Change-Id: Ia61f4f165e328335820a33ceea2b810ac5e6c3af
2023-12-08 14:39:50 -08:00
Vinit Nayak
fe22e7fa4d Merge "Only launch from split taskView if it's visible to user" into main 2023-12-08 22:34:33 +00:00
Vadim Tryshev
3277cbdb17 Fixing non-sending wallpaper animation finish event
Wallpaper animation may be interrupted with an animation to go to Normal state.
Then the animation won't succeed, but it will still end.

Bug: 315074923
Flag: N/A
Test: presubmit
Change-Id: I15a106de78030f6935978539d333cc85ee95b4e7
2023-12-08 14:11:55 -08:00
Saumya Prakash
86285d477d Ensure Taskbar stashes when launching an app from folder
We use the folder closing callback to trigger a call to stash the
taskbar if an app was launched. We can check whether an app was launched
from a folder based on whether a folder's view is open when
an app is launched. This ensures that the taskbar only stashes after the
folder is done animating.

Flag: NA
Fix: 295296529
Test: Launched an app in a folder on taskbar. Also ensured that other
taskbar behavior remains unchanged.

Change-Id: Ib5a797186978ee960e44b6b62c833eead03bccd0
2023-12-08 20:16:15 +00:00