Commit Graph

11086 Commits

Author SHA1 Message Date
Merissa Mitchell a779330a56 Fix NPE from NavbarButtonsViewController on FEATURE_PC devices.
When FEATURE_PC is enabled on a device,
DesktopNavbarButtonsViewController is instantiated. Previously,
DesktopNavbarButtonsViewController saves an internal copy of
mControllers and the mControllers field in NavbarButtonsViewController
is left unset. This was not a problem because mControllers in
NavbarButtonsViewController was not used in any code that was not
overridden by DesktopNavbarButtonsViewController.

ag/17944073 added some code that accesses mControllers in
NavbarButtonsViewController. Even though the code would be skipped for
FEATURE_PC devices (due to the TaskbarUIController check, which is
overridden by DesktopTaskbarUIController) in the end, it still caused an
NPE.

DesktopNavbarButtonsViewController does not require most of the button
updates done in NavbarButtonsViewController. Regardless, this CL
provides a workaround to avoid the NPE by setting mControllers in
NavbarButtonsViewController in FEATURE_PC devices.

Bug: 296623609
Bug: 297260211
Test: Manual; build and launch sdk_gpc emulator. Ensure that no crash
occurs

Change-Id: Ica22359b96fd0a277c575a238abb194d762e81ea
2023-08-24 17:22:48 -07:00
Treehugger Robot fd77e2350a Merge "Adding support for clearing overview suggestion state when overview is disabled" into udc-qpr-dev am: 830524d883 am: 646722fdaf
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24516473

Change-Id: If42b71351fa049457d4660f56dde56a9a375c6d5
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-08-24 23:27:38 +00:00
Treehugger Robot 646722fdaf Merge "Adding support for clearing overview suggestion state when overview is disabled" into udc-qpr-dev am: 830524d883
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24516473

Change-Id: I74804233367ebab71086b6f6f0d27c881f8927e5
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-08-24 22:44:29 +00:00
Vinit Nayak ddc9d5eb73 Merge "Add back gesture support when split selection active" into main 2023-08-24 22:27:39 +00:00
Treehugger Robot 830524d883 Merge "Adding support for clearing overview suggestion state when overview is disabled" into udc-qpr-dev 2023-08-24 22:19:01 +00:00
Mady Mellor dd1b2af955 Merge "Set a view id for the bubble dismiss view (launcher)" into main 2023-08-24 21:48:52 +00:00
Andy Wickham ce2f0de10f Merge "Use new AssistUtils(Base) to override SysUI Assist invocations." into udc-qpr-dev am: 5ed1b4001b am: 77baaf6f25
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24454133

Change-Id: If7c2b5051faa713baa3aed6cee8c5d1f44fa5594
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-08-24 20:10:53 +00:00
Andy Wickham 77baaf6f25 Merge "Use new AssistUtils(Base) to override SysUI Assist invocations." into udc-qpr-dev am: 5ed1b4001b
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24454133

Change-Id: I90a87cf156213c2dfad374f3410f9ac766b69711
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-08-24 20:05:48 +00:00
Andy Wickham 5ed1b4001b Merge "Use new AssistUtils(Base) to override SysUI Assist invocations." into udc-qpr-dev 2023-08-24 19:36:12 +00:00
Vinit Nayak 3f5e3ad419 Hold WeakReference to split callback
Bug: 297135374
Change-Id: I6763cd56fe25735998bf11ec9c682831b5d80beb
2023-08-24 18:55:06 +00:00
fbaron 6707ddd016 Add logs around hotseat suggested apps
Bug: 295892343
Test: n/a
Flag: no flag
Change-Id: Id6f464c8614317f58f6886734ad1f9b9709d6aa3
2023-08-24 11:15:46 -07:00
Vinit Nayak 654604037a Add back gesture support when split selection active
* Currently this exits the current launcher state
back to homescreen whenever back is performed while
split selection is active.
* Open UX question if that needs to be changed.

Test: Did back gesture from workspace, overview, all apps
http://recall/-/cMb5xTTxhmZtFt04eYnmQj/g0kpGTsqlj0RSt4OfDBkpf
Bug: 295449659
Flag: ENABLE_SPLIT_FROM_WORKSPACE_TO_WORKSPACE
Change-Id: I74fe51aaf4301fb723d2e69e6b1b39d127f492d8
2023-08-24 17:52:37 +00:00
Andy Wickham f7554ff718 Use new AssistUtils(Base) to override SysUI Assist invocations.
AssistUtils#getSysUiAssistOverrideInvocationTypes(): Sent
over SysUiProxy to request overriding these invocation types.

AssistUtils#tryStartAssistOverride(): Called by OverviewProxy
(TouchInteractionService) for previously requested overrides.
Also used within Launcher for Taskbar and QSB to override
other invocation logic. May return false to indicate that
the override was not handled, so a fallback may be desired.

Bug: 295874732
Test: Manual
Change-Id: I488f3b7da1feb2663feab5d04dfa8d605c070efb
2023-08-23 15:49:02 -07:00
Liran Binyamin a624495513 Merge "Handle touches on the bubble bar in Overview" into udc-qpr-dev am: 5e7ca0c0b3 am: 8482a8d7b6
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24512108

Change-Id: I5d0740b6b25968212199fd3f383e78e38ca68afd
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-08-23 20:03:06 +00:00
Treehugger Robot 52b0632649 Merge "Taskbar: use ENABLE_HIDE_IME_CAPTION_BAR" into udc-qpr-dev am: 7c183e2987 am: 5137e0561c
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24511367

Change-Id: Icd169ccf8dfb6f60d06b50a3151fb37828225958
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-08-23 19:59:55 +00:00
Liran Binyamin 8482a8d7b6 Merge "Handle touches on the bubble bar in Overview" into udc-qpr-dev am: 5e7ca0c0b3
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24512108

Change-Id: I76d072fbf6bad5d0b779b8a753e934ccb23a8ec2
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-08-23 19:15:22 +00:00
Treehugger Robot 5137e0561c Merge "Taskbar: use ENABLE_HIDE_IME_CAPTION_BAR" into udc-qpr-dev am: 7c183e2987
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24511367

Change-Id: I8eb92f31d8a02603e38f78263425803d232d957e
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-08-23 19:11:41 +00:00
Randy Pfohl 73a7064c1a Merge changes I3394267d,Idf9ef20e into udc-qpr-dev am: f18305ac08 am: e50232a877
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24503147

Change-Id: I2a156efb7dd5acd749f5dfc75e87d5e5cd9a6f17
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-08-23 18:24:25 +00:00
Vinit Nayak e2b8dcab77 Merge "Null out Activity in split controller" into udc-qpr-dev am: 0989216160 am: 87f6c0aed6
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24503472

Change-Id: Ie9425a34a99418852eb352e0d7da71a935f33674
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-08-23 18:22:26 +00:00
Pat Manning 8eff50626f Do not consume hover events not coming from cursor for a11y. am: c7087e8f9f am: e040d5be5b
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24446431

Change-Id: Ied5c4978242696d72b28987bd7633511819f721a
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-08-23 18:10:28 +00:00
Treehugger Robot d91a5858a2 Merge "Clean up RECEIVE_UNFOLD_EVENTS_FROM_SYSUI flag" into udc-qpr-dev am: a5f24d709e am: 6c7fdd42cc
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24501121

Change-Id: Idc0265fc910f5e5ece0d9a97f2c09cf4a4a0c925
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-08-23 18:07:34 +00:00
Tracy Zhou 89e44432d4 Merge "Init nav mode in TaskbarActivityContext between fold/unfold" into udc-qpr-dev am: b038bac666 am: 5eae18306c
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24493282

Change-Id: I405d3817876db08d3c6156cae9b342c9e5456683
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-08-23 18:06:51 +00:00
Randy Pfohl e50232a877 Merge changes I3394267d,Idf9ef20e into udc-qpr-dev am: f18305ac08
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24503147

Change-Id: I88dbb4b6fd28916964b48ddbbe4dd13dab67a904
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-08-23 17:53:06 +00:00
Vinit Nayak 87f6c0aed6 Merge "Null out Activity in split controller" into udc-qpr-dev am: 0989216160
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24503472

Change-Id: Icb070c092a4097015a20eabaa7d755f7f2e157bc
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-08-23 17:52:53 +00:00
Pat Manning e040d5be5b Do not consume hover events not coming from cursor for a11y. am: c7087e8f9f
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24446431

Change-Id: Ia46648d8d4ff9f338d5f21e910c540b45e154681
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-08-23 17:52:29 +00:00
Treehugger Robot 6c7fdd42cc Merge "Clean up RECEIVE_UNFOLD_EVENTS_FROM_SYSUI flag" into udc-qpr-dev am: a5f24d709e
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24501121

Change-Id: Ieb275c6a69efc1e061fd38a284b9218f61b18433
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-08-23 17:43:52 +00:00
Tracy Zhou 5eae18306c Merge "Init nav mode in TaskbarActivityContext between fold/unfold" into udc-qpr-dev am: b038bac666
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24493282

Change-Id: I3bfd26f70ba8b7b968c3a5fa610a59f458fd07b8
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-08-23 17:42:00 +00:00
Liran Binyamin 90d3a422f8 Cap the width of the bubble bar when collapsed
When the bubble bar is collapsed we now show at most 2 bubbles.

Fixes: 295020145
Test: Manual
      - Add 1 bubble to the bubble bar
      - Collapse bubble bar
      -- Observe that only that bubble is visible
      - Expand the bubble bar
      -- Observe that both that bubble and the overflow are visible
      - Add another bubble
      -- Observe that 2 bubbles are visible when collapsed
      - Add another bubble
      -- Observe that only the first 2 bubbles are visible when collapsed
Change-Id: I5f534f53eefe9a920b8b3258813d67d021c5f2a8
2023-08-23 07:40:56 +00:00
Liran Binyamin 5e7ca0c0b3 Merge "Handle touches on the bubble bar in Overview" into udc-qpr-dev 2023-08-23 07:13:16 +00:00
Treehugger Robot 7c183e2987 Merge "Taskbar: use ENABLE_HIDE_IME_CAPTION_BAR" into udc-qpr-dev 2023-08-22 22:05:32 +00:00
Mady Mellor c62e37305d Set a view id for the bubble dismiss view (launcher)
There is a flake in the drag to dismiss bubble test, I think it's
because sometimes it misses the dismiss target since the test drags
the bubble to the bottom of the screen instead of the target location.

In attempt to fix this I'm setting an ID on the dismiss target to
look up where it is on screen and drag the bubble to it directly.

Test: treehugger
Bug: 296933279
Change-Id: I7949aa0131020651214e9ebaa834dda8fc25971a
2023-08-22 20:56:27 +00:00
Sunny Goyal 52a7f05681 Adding support for clearing overview suggestion state when overview is disabled
Bug: 297037290
Test: Presubmit
Flag: N/A
Change-Id: I38f7fd38564c7c529cbd9aa5acead08b181b1b92
2023-08-22 13:46:29 -07:00
Randy Pfohl f18305ac08 Merge changes I3394267d,Idf9ef20e into udc-qpr-dev
* changes:
  Adding some logging to track test failure in post submit
  enable testWidgets for postsubmit for long term debugging
2023-08-22 17:14:40 +00:00
Vinit Nayak 0989216160 Merge "Null out Activity in split controller" into udc-qpr-dev 2023-08-22 16:21:45 +00:00
Adrian Roos f45ebad9be Taskbar: use ENABLE_HIDE_IME_CAPTION_BAR
With ENABLE_HIDE_IME_CAPTION_BAR, we no longer need to update the navigation bar override. This was already applied for the navigation bar, but not the task bar. Mirrors the NavigationBar.java change in
I8793db69fb846046300d5a56b3b0060138ef4cd5.

Bug: 289748734
Change-Id: I86079cb6670a2ae3b6fa883694f8af81df212408
Test: presubmit
2023-08-22 16:07:37 +00:00
Liran Binyamin 80f20a2183 Handle touches on the bubble bar in Overview
If the bubble bar is visible and we're in Overview, set the touchable region
of the Taskbar to include the bubble bar bounds.

Fixes: 290197298
Test: Manual
      - Add multiple bubbles to the bubble bar
      - Go to Overview
      - Tap on the bubble bar
      -- Observe that the bubble bar expands
      - Tap on different bubbles
      -- Observe that the bubble bar updates correctly
      - Tap outside the bubble bar
      -- Observe that the bubble bar collapses
      - Tap outside of the bubble bar again
      -- Observe that the launcher state changed and we are in Home
Change-Id: I722778ee41b50ebca57431bb303da89104d25090
2023-08-22 09:13:15 -04:00
Pat Manning c7087e8f9f Do not consume hover events not coming from cursor for a11y.
Fix: 283041221
Test: TaplTestsTransientTaskbar
Flag: ENABLE_CURSOR_HOVER_STATES
Change-Id: I95e9ded6873173ea001c82d6319716a2d48b3bad
2023-08-22 09:17:04 +00:00
Treehugger Robot a5f24d709e Merge "Clean up RECEIVE_UNFOLD_EVENTS_FROM_SYSUI flag" into udc-qpr-dev 2023-08-22 09:09:51 +00:00
Tracy Zhou b038bac666 Merge "Init nav mode in TaskbarActivityContext between fold/unfold" into udc-qpr-dev 2023-08-22 06:48:01 +00:00
Sunny Goyal 5442cbc300 Clean up RECEIVE_UNFOLD_EVENTS_FROM_SYSUI flag
Bug: b/270397209
Test: Presubmit
Flag: RECEIVE_UNFOLD_EVENTS_FROM_SYSUI
Change-Id: I4f87777fd27b5489557742b58e25dc5488b7d32b
2023-08-22 04:31:09 +00:00
Luca Zuccarini b38e61a339 Animate depth from the right value on Taskbar All Apps launches.
`MyDepthController` in `QuickstepTransitionLauncher` assumes that we
want the background to always animate the same way, matching the rest
state of the workspace (depth == 0). However, in Taskbar All Apps the
background is visible, and depth != 0. We now initialize the one-off
`DepthController` for launches to take into account the latest depth set
by the top level `DepthController`, so there is no jumpcut at the
beginning of the animation.

Note that in my opinion we should use the same `DepthController` for all
cases, rather than having this one-off. I'm looking into the feasibility
of that change, but for now this fixes the issue at hand.

Fix: 292959100
Flag: N/A
Test: manual, see videos in the bug

(cherry picked from commit 627d67549f)
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:3e91646d123abbe58ccc0544746145ce5024b923)
Merged-In: Id90e8e728cc3e2ccf7d92148fbb0d6ff3e6fd6ca
Change-Id: Id90e8e728cc3e2ccf7d92148fbb0d6ff3e6fd6ca
2023-08-22 02:15:08 +00:00
Nick Chameyev 14b4f9edcc [Unfold animation] Do not preemptively start the animation if it has run already
Currently if we open an app, unfold the device and then go to home
screen we will start the unfold animation preemptively in Launcher
because Launcher activity will receive updated configuration change
(where isTablet = true) only after going back to home screen, not
when unfolding the device.

This causes a problem because SystemUI won't send the unfold animation
events after going back home as the animation has already run, so we
end up with wrongly started animation in Launcher.

This CL fixes the issues by checking if SystemUI has finished the
animation (or if it is currently running) to avoid preemptive animation
start in this case. This is done by subscribing to the original
unfold transition progress provider which emits progress events
sent through IPC from SystemUI.

Bug: 285150685
Bug: 293131586
Test: open an app on folded screen, unfold, go to home screen =>
  check that icons are not squished
Test: fold/unfold when launcher is open
(cherry picked from commit 6d756970e7)
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:2e53f5ef97a02d25f508774e82985e24dc2f4d2d)
Merged-In: Ic437ff4d19cbd5764635f3007d99880622150f5b
Change-Id: Ic437ff4d19cbd5764635f3007d99880622150f5b
2023-08-22 02:14:49 +00:00
Vinit Nayak b620af4612 Null out Activity in split controller
Bug: 295225524
Change-Id: I59aaed3fca07d611088cec0a4bfafc658a151bb2
2023-08-21 23:40:51 +00:00
Treehugger Robot 0bf390490a Merge "Pass extras Bundle in onRecentsAnimationStart" into main 2023-08-21 23:25:16 +00:00
Tracy Zhou d9d17ce133 Init nav mode in TaskbarActivityContext between fold/unfold
In RotationButtonController, we show the floating rotation button either when the bar is visible, or when the device is in gesture nav mode, even in an immersive app. The issue here is that mNavMode is not correctly initialized after the device is unfolded.

Fixes: 272164624
Test: Open townhall. Fold and then unfold. Tilt the device and make sure the floating rotation button shows.
Change-Id: I09025132fdca5c764e66d9ac21f29b853741d257
2023-08-21 22:38:13 +00:00
Treehugger Robot 0dbd72188b Merge "Add null check for mRecentsView when recents animation is canceled" into udc-qpr-dev am: 2a1df8879f
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24499166

Change-Id: I47fae5b187a2bb2a50e0ff78ce9672cdd50ba6b3
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-08-21 22:14:42 +00:00
Treehugger Robot 2a1df8879f Merge "Add null check for mRecentsView when recents animation is canceled" into udc-qpr-dev 2023-08-21 21:50:54 +00:00
randypfohl ecffb20ba8 Adding some logging to track test failure in post submit
Test: not needed

Bug: 295069071

Change-Id: I3394267dbbd808544e2759737c7d139c5ba4121f
2023-08-21 14:49:25 -07:00
Vinit Nayak b23cdf1f93 Pass extras Bundle in onRecentsAnimationStart
* Bundle will contain SplitBounds if recents
animation contains splitscreen targets
* Key to use is SplitBounds#KEY_RECENTS_BUNDLE

Test: Swiping up with single + split tasks
Bug: 254378592
Change-Id: I51f4063aa62ae22a43ffb3712ae6a837156f32d8
2023-08-21 21:32:54 +00:00
Treehugger Robot 4dc9893028 Merge "Remove Change Navigation Mode option for Taskbar Divider Popup Menu" into udc-qpr-dev 2023-08-21 19:41:19 +00:00