Commit Graph

2001 Commits

Author SHA1 Message Date
Tracy Zhou
33132dc48c Dynamically adjust the paddings of the contextual buttons
- Dynamically adjust the paddings of both start and end contextual containers in different layouts

Test: manual
Bug: 230395757

Change-Id: I2c6a1350e0dab36f6d5100b8d4e2012d8a97cd9b
2023-10-13 20:10:44 -07:00
Tracy Zhou
6bfdfd011b Merge "Correct signal for showing contextual buttons for taskbar" into main 2023-10-13 21:04:13 +00:00
Sunny Goyal
4588031286 Merge "Moving onboarding prefs to use LauncherPrefs" into main 2023-10-12 20:51:45 +00:00
Tracy Zhou
f11604ee49 Correct signal for showing contextual buttons for taskbar
Apparently isContextualButtonShowing is not the right signal. Checking on dp.isGestureMode instead

Fixes: 300849078
Test: manual
Change-Id: Iac44bb4adbbdd5faf52100c88c2a4a6d95d58b98
2023-10-12 10:43:46 -07:00
Jon Miranda
330b7754c6 Fix bug where All Apps button loads in late in taskbar.
We need to re-create the icon alignment controller if the
stash status changes, otherwise it will use an old value.

Bug: 296414290
Test: home to app then quickly unstash
Change-Id: I35f23842f289fce95d102a9a93dc94cd033fa8cc
2023-10-12 17:14:49 +00:00
Tracy Zhou
fbc01a0b4f Fix transient task bar not automatically stashed in app when ENABLE_TASKBAR_NO_RECREATION is enabled
Currently the task bar root layout consumes all the events and does not pass the events to drag layer, without explictly routing those events

Fixes: 303910224
Test: go to an app, swipe home, and then go back to the app. Make sure the task bar is stashed
Change-Id: I6f5e481c267dad25544118134ff95b0cb9bb1a45
2023-10-11 11:25:45 -07:00
Tracy Zhou
de28c115b2 Fix phone mode task bar inset values not correctly initialized
We rely on contentHeightToReportToApps and tappableHeightToReportToApps (that ultimately call into DeviceProfile) of TaskbarStashController to initialize the insets. However, DeviceProfile only initializes those values when isTaskbarPresent is true. Rather than completely changing the initialization of DeviceProfile, we special case in TaskbarStashController that uses the bar height for inset

Bug: 274517647
Test: turn on FLAG_HIDE_NAVBAR_WINDOW and TASKBAR_NO_RECREATION, make sure the insets are correct in both 3 button and gesture nav mode
Change-Id: I164a6e2c9f9d24888155b45325ee8ce46ca2c39f
2023-10-10 13:02:16 -07:00
Sunny Goyal
cd44740567 Moving onboarding prefs to use LauncherPrefs
Bug: 301661768
Test: Presubmit
Flag: N/A
Change-Id: Iec8a5e739f394a152d5ffc57b01e0449e94b4084
2023-10-10 11:47:33 -07:00
Tracy Zhou
f14c534ec5 Merge "Set correct stashed task(nav) bar height with taskbar/navbar unification" into main 2023-10-10 05:08:02 +00:00
Tracy Zhou
5bd641e3f5 Merge "Fix task bar crashing in small screen with task bar / nav bar unification on" into main 2023-10-09 20:26:25 +00:00
Vinit Nayak
4f850a42a0 Merge changes I9e56ddbe,I8767deea into main
* changes:
  Disallow taskbar long click when in split selection state
  Add method to determine if launcher is in split selection state
2023-10-07 00:20:24 +00:00
Jagrut Desai
f56bfabaa4 Merge "Change Taskbar Window height logic for taskbar pinning." into main 2023-10-06 23:33:30 +00:00
Vinit Nayak
114293fb56 Disallow taskbar long click when in split selection state
* This is specifically when contextual is initiated on home
screen and then user swipes up into overview.
* We no longer want to rely on LauncherStates for split specific
management

Bug: 295981634
Test: Start split on home, swipe up to overview, long press on
taskbar app icons, nothing happens
Flag: ENABLE_SPLIT_FROM_WORKSPACE_TO_WORKSPACE

Change-Id: I9e56ddbe1f536be779d4848769a993724d5395da
2023-10-06 14:42:22 -07:00
Brian Isganitis
447b09057a Merge "Prevent NPE from changing all apps visibility in shared state." into main 2023-10-06 20:59:33 +00:00
Brian Isganitis
f79785065b Merge "Have dragged search items return to All Apps icon if cancelled." into main 2023-10-06 20:44:06 +00:00
Tracy Zhou
cfbf3ff695 Set correct stashed task(nav) bar height with taskbar/navbar unification
Again caused by DeviceProfile not initiating task bar stashed and unstashed height in folded state with unification code

Test: Make sure that task(nav) bar has the correct height in both folded and unfolded state
Bug: 274517647
Change-Id: I0d86cfccc6f096bc983f87c57fdfac9800fd4d41
2023-10-05 22:51:10 -07:00
Tracy Zhou
0812a9495c Fix task bar crashing in small screen with task bar / nav bar unification on
A few params are not set in device profile when task bar (in large screen) is not present, and hence the calculation below causes a crash

Test: Make sure that it doesn't crash in small screen gesture nav mode
Bug: 274517647
Change-Id: I3a61a64ac931fac4aee1a3c40ed54ab9ded298a7
2023-10-05 16:40:48 -07:00
Tracy Zhou
27d7769000 Fix task bar crash in gesture nav mode with task bar / nav bar unification on
a11yButton is reserved for 3-button mode so it can be null. Also TaskbarNavLayoutter is used for large screen both in gesture nav and 3-button mode, so need to check isContextualButtonShowing to add contextual buttons

Fixes: 300849078
Test: Make sure that it doesn't crash in large screen gesture nav mode
Change-Id: I9d0694b7f4c95461f24efb2af1af905e68e3cd8d
2023-10-04 20:17:23 -07:00
Brian Isganitis
8f3342967c Prevent NPE from changing all apps visibility in shared state.
Also setting to false in onCloseBegin since this is an earlier signal
than onClosed.

Test: Manual (regular + recreate by toggling dark theme)
Fix: 301705545
Flag: No
Change-Id: Ifb356d4f1346f7af15a375ad7b88d2d8be227328
2023-10-04 15:32:37 -04:00
Brian Isganitis
d5684000f9 Have dragged search items return to All Apps icon if cancelled.
Test: Manual
Fix: 303302706
Flag: ENABLE_ALL_APPS_SEARCH_IN_TASKBAR
Change-Id: Id2a06b38a987566b8e334125a050196a2845921e
2023-10-04 15:03:59 -04:00
Tracy Zhou
b1122a4ad3 Merge "Fix some merge issues in repositioning contextual buttons for taskbar/navbar unification" into main 2023-10-04 04:00:24 +00:00
Jagrut Desai
0dce287a6c Change Taskbar Window height logic for taskbar pinning.
- Breakout CL part 6
- This is a breakout cl from ag/24272821 to make it more readable and atomic.
- This cl makes default taskbar window height to be transient when the taskbar pinning flag is on, so we don't see taskbar window cutoff during animation.

Test: Manual, Visual
Bug: 265170176
Flag: ENABLE_TASKBAR_PINNING
Change-Id: I37e8ad0f2c4d144476828f101019dcacdea7acb2
2023-10-03 16:53:32 -07:00
Liran Binyamin
5bec1164b9 Merge "Make the bubble bar flag dynamic in Launcher." into main 2023-10-03 17:47:11 +00:00
Liran Binyamin
e41e6185e4 Make the bubble bar flag dynamic in Launcher.
Changing the flag currently requires a reboot, because it is read once when the process starts and never changes.
This change triggers a re-read of the flag value from SystemProperties whenever Taskbar is recreated.
This allows setting the flag as part of integration tests for bubble bar.

Bug: 273994695
Test: Manual:
       - turn flag off
       - create bubbles
       - observe floating bubbles are added
       - turn flag on
       - change navigation mode to gesture navigation
       - observe bubble bar becomes visible
Change-Id: I277ea6aa2c8d3ab04094537bf4cd31630310dfec
2023-10-03 10:49:30 -04:00
Tracy Zhou
5b3c85564f Fix some merge issues in repositioning contextual buttons for taskbar/navbar unification
Fixes: 300849078
Test: Rotate around, and make sure the rotation button stays in the same corner
Change-Id: Ifb7904117f4ae8b28f2d14b27fbb39fe1a82e6ae
2023-10-03 01:09:56 -07:00
Tracy Zhou
fe38407873 Merge "Repostion contextual buttons upon layout changes" into main 2023-10-02 20:15:31 +00:00
Schneider Victor-tulias
8f795844e9 Merge "Refactor the BorderAnimator for simplicity" into main 2023-10-01 17:27:16 +00:00
Schneider Victor-tulias
7335bcf7f5 Refactor the BorderAnimator for simplicity
The internal implementation of BorderAnimator does not need to be as exposed. refactored the class to be simpler to implement

Flag: ENABLE_KEYBOARD_QUICK_SWITCH, ENABLE_CURSOR_HOVER_STATES
Bug: 302334949
Test: check border animation in keyboard quick switch and recents view
Change-Id: I8a2e4fa0abc5af743352cd6409aee9f2912b41a2
2023-09-29 15:08:05 -04:00
Fengjiang Li
576c7ff4d7 Merge "Don't preinflate all apps for taskbar in AllAppsStore#setApps" into main 2023-09-29 16:16:58 +00:00
Jagrut Desai
f9ad6ab8bb Merge "Add more debugs logs to TaskbarManager" into udc-qpr-dev am: f2412770e2 am: 7a150d07d7
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24829188

Change-Id: Ia5fae16bbb40ac5553b92380f8b1f7f592cb201e
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-29 05:04:26 +00:00
Jagrut Desai
7a150d07d7 Merge "Add more debugs logs to TaskbarManager" into udc-qpr-dev am: f2412770e2
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24829188

Change-Id: I4abe9d51d2fb4e0b740484dcb5e08c3198848b39
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-29 03:57:48 +00:00
Jagrut Desai
f2412770e2 Merge "Add more debugs logs to TaskbarManager" into udc-qpr-dev 2023-09-29 02:39:18 +00:00
Jagrut Desai
c1bd53c3f0 Add more debugs logs to TaskbarManager
- adding more logs to TaskbarManager to investigate taskbar being present in folded state of the device.

Test: Presubmit
Bug: 254119092
Flag: not needed
Change-Id: I81c475f1c6bbc8d5b7874ddc45e8778861b61cd0
2023-09-28 15:46:22 -07:00
Fengjiang Li
e92556819b Don't preinflate all apps for taskbar in AllAppsStore#setApps
Triggering all apps pre-infation at AllAppsStore#setApps is too late for taskbar, because it is in same frame when user opens all apps from taskbar. We should find an earlier entry point to pre-inflate all apps for taskbar.

Test: Verify taskbar is rendered correctly. Also verify we no longer pre-inflate all apps for taskbar in perfetto trace
Change-Id: If1f8c616b6be7f64ea16807f4b7a8b75da55d038
2023-09-28 14:29:07 -07:00
Brian Isganitis
a5cdbe5d4e Merge "Fix Taskbar AllApps touch interception when above EDU." into main 2023-09-28 21:17:55 +00:00
Liran Binyamin
44bd688301 Merge "Let the bubble bar handle gestures over the bubble bar." into main 2023-09-27 15:39:16 +00:00
Tracy Zhou
a9194c54ef Repostion contextual buttons upon layout changes
Also make sure the contextual buttons are centered in its respective orientation

Fixes: 300849078
Test: Rotate around, and make sure the rotation button stays in the same corner
Change-Id: Ibc40739eff050f258b938ccf94c2056ed1ee596b
2023-09-26 19:09:59 -07:00
Tracy Zhou
aa366d03cd Merge "Fix wrong 3 button order in landscape mode sometimes" into main 2023-09-26 23:58:47 +00:00
Liran Binyamin
d7f1942d4a Let the bubble bar handle gestures over the bubble bar.
This change introduces a motion event flag to signal that the gesture
is being originated over the bubble bar (similar to the nav bar gesture flag). Downstream consumers use this flag to ignore the event in order
to allow the bubble bar to handle it.

The black screen in b/293348900 seemed to be related to the recents
shell transition closing the app that was in the foreground before
swiping on the bubble bar handle. Not sure why it ended up with a black
screen, but this change avoids starting the recents transition entirely.

Demo: http://recall/-/bJtug1HhvXkkeA4MQvIaiP/BSxLROoflr1i2yy0v6Y4G

Fixes: 294421126
Bug: 293348900
Test: Manual:
      - Add bubble to the bubble bar
      - Swipe up over the bubble bar
      - Observe that the bubble bar expands

      - Launch application
      - Swipe up on the bubble bar handle
      - Observe that the bubble bar expands

Change-Id: Iea15829de97edb6bfbfb7007388865230faaf736
2023-09-26 12:02:27 -04:00
Brian Isganitis
4749dc8db1 Fix Taskbar AllApps touch interception when above EDU.
Test: Manual
Fix: 301643091
Flag: No
Change-Id: I804031a0cfc4620b39551fb5badab7ac7008fb5f
2023-09-22 16:45:17 -04:00
Felix Stern
c4edad6814 Merge "Use stashedTaskbarHeight for IME insets override" into udc-qpr-dev am: 795dc83c72 am: db1028ea85
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24834321

Change-Id: I69f30281881fc6ec5631f0ec3b5495434567ed2a
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-22 19:06:08 +00:00
Schneider Victor-tulias
5fc26f3861 Merge "Update KeyboardQuickSwitch for TAPL testing" into main 2023-09-22 18:26:48 +00:00
Felix Stern
db1028ea85 Merge "Use stashedTaskbarHeight for IME insets override" into udc-qpr-dev am: 795dc83c72
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/24834321

Change-Id: Iec4d3327d606cf5d607b8b68d7c640e737199d72
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-22 18:07:44 +00:00
Schneider Victor-tulias
e95326dfdd Update KeyboardQuickSwitch for TAPL testing
- Added a res id to KeyboardQuickSwitchView for TAPL testing
- Updated KeyboardQuickSwitch focus and scroll initialization
- Logging KeyEvents for TAPL testing
- Updated scrolling logic to wait for initial layout
- Fixed activity leak in KeyboardQuickSwitchViewController

Flag: ENABLE_KEYBOARD_QUICK_SWITCH
Bug: 267520665
Test: TaplTestsKeyboardQuickSwitch
Change-Id: I1d45d948c0e185504d994f7ef1d34f173c2243a9
2023-09-22 11:04:43 -04:00
Cosmin Băieș
df2ceac06c Use stashedTaskbarHeight for IME insets override
Previously [1] we removed the explicit insetsSizeOverride from the
Taskbar for the IME window, as we now [2] enable hiding the IME nav bar.
This would now send the normal insets the taskbar reports. When running
on pre/postsubmit, with test harness setup, the non-transient taskbar
would show, which is bigger than the IME's navigation bar height.

Due to the current logic in InsetsSource#calculateInsets, this leads to
the IME window receiving top navigation bar insets instead of bottom.
As the IME nav bar is now treated as a (fixed on bottom) caption bar,
the two would no longer overlap, and thus lead to a double insets
dispatch, and also a (temporarily) bigger IME window, for IMEs that set
their decorView height to WRAP_CONTENT (e.g. MockIME used in testing).

This instead keeps the previous insetsSizeOverride for IME, and uses the
stashedTasbarHeight when in gesture nav, which should account for both
transient and normal taskbars.

 [1]: I86079cb6670a2ae3b6fa883694f8af81df212408
 [2]: I8793db69fb846046300d5a56b3b0060138ef4cd5

Bug: 297000797
Test: atest WindowInsetsControllerTests#testDispatchApplyWindowInsetsCount_ime
Change-Id: I102a8bc1f8869ebbce9f8f1fefa651d49a9538ec
2023-09-22 14:16:03 +00:00
Andy Wickham
3582efc2f1 Merge "Adds SystemActionConstants" into main 2023-09-21 22:31:10 +00:00
Mady Mellor
b604e71fe8 Merge "Fix bubbles taskbar scrim showing when notification panel is shown" into main 2023-09-21 01:25:07 +00:00
Treehugger Robot
e745dda409 Merge "Use default taskbar stash duration when opening/closing all apps from taskbar." into main 2023-09-20 17:54:36 +00:00
Andy Wickham
e257408101 Adds SystemActionConstants
This includes the previously added Taskbar System Action, as well
as a new one for Screen Search.

Bug: 299321919
Test: Manual
Change-Id: I4a8fa1dde402dc2de5f448cb2edbe712e128ff12
2023-09-19 22:12:40 +00:00
Brian Isganitis
a4497e55b2 Merge "Remove onTaskCreated for hiding Taskbar overlay." into main 2023-09-19 21:20:38 +00:00