Commit Graph

90 Commits

Author SHA1 Message Date
Vinit Nayak
209dd03b69 Send corrent SUW insets for taskbar portrait vs landscape
* There were two separate blocks of code for sending insets
for Taskbar during SUW, consolidate those
* We also weren't changing Taskbar window height corresponding
to the added insets/change of height for different
orientations in SUW

Fixes: 253538830
Test: Went through SUW and switched orientations,
no back button overlap

Change-Id: Ifb3bc1c20a793ef062bf338a3bdf933b8ae98c28
2022-11-24 10:29:16 -08:00
Sunny Goyal
d859060860 Merging MultiValueAlpha with MultiPropertyFactory
Bug: 246644619
Test: Presubmi
Change-Id: Id5abc5f3169544656f1139ae17ca59e34ac65dac
2022-10-24 14:38:18 -07:00
Vinit Nayak
2a2fbfe319 Use updateButtonLayoutSpacing() for all states
* During a merge conflict we prevented
updateButtonLayoutSpacing() from running if device was
in setup mode, however the code that does setup layout
is in there.

Fixes: 254589281
Test: Went through setup, back button shows up
where expected

Change-Id: Ib496bfc0e3ac9023a9fc5071867c3779721ab8ab
2022-10-20 23:11:33 -07:00
Vinit Nayak
d6c5147524 Landscape 3 button nav on taskbar phone supported
* TODO: Seascape bar positioning, add tests

Change-Id: I542be2f2f682d8c8a9cdd9bb6c667c44ca167f3e
Merged-In: I542be2f2f682d8c8a9cdd9bb6c667c44ca167f3e
2022-10-17 13:59:18 -07:00
Vinit Nayak
2081742cb7 First pass at Taskbar layout UI polish for SUW
Bug: 231906478
Change-Id: I5d55d1e33f928d4b8034c356565a0f9d8bc5c3fb
2022-10-12 00:04:27 +00:00
Vinit Nayak
7523b94105 Hide back button if IME shows in SUW
Fixes: 230830643
Test: Visually see no back button when IME
shows up on enter pin screen

Change-Id: Icdde92d39962c3891a56bb07de5b16a22635729e
2022-09-29 15:47:15 -07:00
Vinit Nayak
c7295ee37a Add margin to SUW back button
* navButtonsLayoutParams marginEnd was removed, and
SUW was relying on that value to add margins to
SUW back button, but was returning 0.

Fixes: 242999939
Test: Visually observed in SUW test activity
adb shell am start -n com.google.android.setupwizard/.SetupWizardTestActivity

Change-Id: I5ffc421e9b731b0d9c7b7c48eab807d4419721b1
2022-09-29 15:47:15 -07:00
Brian Isganitis
731ef0c301 Properly color taskbar nav buttons when slide-in view is shown.
Supports overriding the current nav bar color with one that would be
visible over a slide-in view.

Demo:
https://drive.google.com/file/d/1MB26QM5qeeyVB6Bj14IGoPCWVT_P7K-3/view?usp=sharing&resourcekey=0-wnMgciNrUXC_l7gI3JFm8A

Test: Manually with light and dark themes, as well as All Apps and EDU
views.
Fix: 248359789

Change-Id: I134ae719b10f3de78ea18220a835de56a82ecb02
2022-09-26 11:41:38 -07:00
Winson Chung
3f649ef892 Update Launcher for removed shared wrappers
- Launcher can reference system code directly now

Bug: 219861883
Test: Builds/Presubmit
Change-Id: I3f656b6c7fce93243ccb7591e52441e99137dec6
Merged-In: I3f656b6c7fce93243ccb7591e52441e99137dec6
2022-09-14 17:14:32 +00:00
Pat Manning
401f6bb0d4 Undim kids nav icons on a11y focus and click.
Fix: 241298057
Test: manual
Change-Id: I9a330bde4641a01b4d19dc83c8f25f56a69328c8
2022-09-01 12:42:04 +01:00
Vinit Nayak
89be3a4c6d Merge "Show 3 button nav on phone in Taskbar (1/2)" into tm-qpr-dev 2022-08-10 03:06:53 +00:00
Vinit Nayak
8a3d05587e Show 3 button nav on phone in Taskbar (1/2)
* TODO: Landscape/seascape support,
        Separate nav spacing out into
        separate class/add tests

Bug: 219035565
Change-Id: I8f5c007f04ea4d6df15962772806356181d764ff
2022-08-09 13:25:50 -07:00
Pat Manning
f3783291ec Skip button layout spacing call when kids nav bar is active.
Fix: 240530037
Test: manual.
Change-Id: Ibf777dfdaab3c81da8feed581a0297f09a62539d
2022-08-05 10:35:07 +00:00
Schneider Victor-tulias
f6003ff070 Merge "Fade out the taskbar icons when animating to overview in 3 button nav." into tm-qpr-dev 2022-07-26 17:29:33 +00:00
Vinit Nayak
c7293179d0 Space out 3 button nav on taskbar
* Add additional margin on nav buttons if
there's overlap w/ contextual button
* End spacing is dependent on grid layout

Bug: 223724516
Test: Tested on unfolded with different
grid sizes.

Change-Id: Ie814f35cd1f35629744050ee3f7242c5a8599883
2022-07-25 13:15:11 -07:00
Schneider Victor-tulias
3f6c473164 Fade out the taskbar icons when animating to overview in 3 button nav.
Bug: 231213105
Test: from home, opened recents, then went back home, then went back to recents, resumed an app, then went back to recents and resumed the same app (both in 3-button and gesture nav)

Change-Id: I83b1b33cafb95353f36a126b93fcaf3b536d3bf4
2022-07-19 11:35:37 -07:00
Tracy Zhou
1092ccacbf Merge "Show IME switcher only when physical keyboard is connected in 3 button nav (instead of also when virtual keyboard is visible)" into tm-qpr-dev 2022-06-29 21:27:17 +00:00
Tracy Zhou
6663ebba3e Merge "Perform haptic feedback on nav button key press" into tm-qpr-dev 2022-06-27 22:55:42 +00:00
Tracy Zhou
849a0c4e81 Show IME switcher only when physical keyboard is connected in 3 button nav (instead of also when virtual keyboard is visible)
Bug: 226489759
Test: connect to a physical keyboard in 3 button nav and make sure the ime switcher shows; and doesn't show with virtual keyboard
Change-Id: Ib9a5880eb1bd6d5b877a9f3789ce858f399c4910
2022-06-24 23:40:41 -07:00
Tracy Zhou
804feb76e7 Fix ime switcher not showing for 3-button nav
Bug: 226489759
Test: connect to a physical keyboard in 3 button nav and make sure the ime switcher shows
Change-Id: Iabde149e8bcd1edacff8e039f956628c69341ecb
2022-06-24 11:17:40 -07:00
Tracy Zhou
0a0fcb809c Perform haptic feedback on nav button key press
Fixes: 203614307
Test: manual
Change-Id: Icaea3f5e436522f23202c20fcc7f7c5dbe309372
2022-06-23 14:29:34 -07:00
Tony Wickham
9a54d2aa43 Hide taskbar while VoiceInteractionWindow is visible
- Fade out icons (or stashed handle if stashed)
- Move background to APPLICATION_OVERLAY layer (behind VIW)
  - Only for gesture nav
- On home screen in 3 button mode, translate buttons down when assistant
  is invoked

Test: Invoke assistant, ensure it draws above taskbar background and
taskbar stops drawing icons or stashed handle
Bug: 225200928

Change-Id: I7807d30df8f358295b8231d89217c7413f32c6f9
Merged-In: I7807d30df8f358295b8231d89217c7413f32c6f9
2022-06-09 05:21:42 +00:00
Brian Isganitis
a9a78117c7 Have separate DeviceProfile instances for taskbar and all apps windows.
We want to scale down the DeviceProfile for taskbar, but the all apps
window should rely on the original DeviceProfile.

Test: Manual
Fix: 232907361
Change-Id: Ia09f674ada9e445c1d7278fa94c536ea9de13ef9
Merged-In: Ia09f674ada9e445c1d7278fa94c536ea9de13ef9
2022-05-25 18:11:51 +00:00
TreeHugger Robot
8d5c3e91cf Merge "Remove long press on home button for kids mode." into tm-dev 2022-05-09 19:22:11 +00:00
Pat Manning
52bb52aeb4 Remove long press on home button for kids mode.
Fix: 229961238
Test: manual
Change-Id: Idb50d4e142b1d1b0539a71b7a727d00dc76c6a68
2022-05-09 16:57:33 +01:00
Vinit Nayak
b1436b0ae7 Extend recents button hitbox on tablet
* Extends hitbox when recents is tapped
when going from taskbar to overview.
* Extended region lasts for 400ms after
the animation ends.

Fixes: 225885714
Test: Manual, added unit test
Change-Id: I8766279c1a5bf6867f8d69ddd3af2aa3565deec2
2022-05-06 17:04:47 -07:00
Schneider Victor-tulias
9b6babf839 Translate the 3 navigation buttons to/from their in-app position when animating to/from the -1 screen, all apps and widgets.
Bug: 221455508
Test: opened all apps, widgets, -1 screen, notifications shade and keyboard in various combinations and orders; locked screen, launched app, returned home with the back/home buttons, opened overview
Change-Id: Ia0b406aacf72b34bd6b7ff1c01278ab6895a7da4
Merged-In: Ia0b406aacf72b34bd6b7ff1c01278ab6895a7da4
(cherry picked from commit 9c1a452a1d)
2022-05-02 18:45:01 +00:00
Tony Wickham
36c9d888d8 Move taskbar insets logic to TaskbarInsetsController
Test: TaplTestsTaskbar; manually stash/unstash taskbar, open IME
Bug: 215411414
Change-Id: I73622dc020c4f8c8b3d317fcb1dd072bcfc3d274
Merged-In: I73622dc020c4f8c8b3d317fcb1dd072bcfc3d274
2022-04-20 19:27:48 +00:00
Tracy Zhou
0439fcdd5c Do not append additional delimiters
Fixes: 227665358
Test: N/A
Change-Id: I6ec0bca286c0824e474f04a61b7d855858490120
2022-03-31 17:15:46 -07:00
Vinit Nayak
c750e3d3aa Hide taskbar when launcher receives nav and keyguard showing
* On large screen we receive notification shade expanded
signals even on keyguard.
* Add a check to not show taskbar if keyguard is showing

Fixes: 223465924
Test: Taskbar doesn't show on 3 button nav except
on bouncer, as expected.

Change-Id: I4a7ea14422eda13ae8571793ed7ba1a1964072d6
2022-03-23 14:09:25 -07:00
Yohei Yukawa
697ae451d4 Use config_imeDrawsImeNavBar in Launcher
With this CL, the Launcher starts checking

  config_imeDrawsImeNavBar [1]

instead of

  config_navBarInteractionMode

when determining whether the IME should render the back and IME
switcher buttons or not.

There should be no observable behavior change as long as

  config_navBarInteractionMode

is set to true when the gestural navigation is enabled.

Bug: 216118048
Test: presubmit
Change-Id: Ia8269e240e0b18e1c7b8bd550dbb197ad58a6dbc
2022-02-08 07:47:29 -08:00
TreeHugger Robot
790146d1d8 Merge "Do not translate taskbar icons in kids mode when IME present." 2022-01-28 15:05:15 +00:00
Pat Manning
05ff09c52c Do not translate taskbar icons in kids mode when IME present.
Test: manual
Bug: 203749295
Change-Id: I6958ed95f1199c1178487134b92ff3ef0f15da2e
2022-01-28 12:22:17 +00:00
Pat Manning
e9a36099db Merge "Animate icon dimming in taskbar when force showing in immersive mode." 2022-01-28 10:24:07 +00:00
Tony Wickham
f6e98fdc9c Don't add IME back and switcher buttons if IME renders them
- Also cache InputMethodService.canImeRenderGesturalNavButtons() since it doesn't change at runtime

Test: Enable persist.sys.ime.can_render_gestural_nav_buttons setprop, then ensure we don't draw IME back button or switcher button when gesture nav is enabled
Test: We still show back button in setup, regardless of nav mode
Bug: 205803355
Change-Id: Iab8c47521ab9e561881e4ffb45142888e4c427e4
2022-01-27 20:15:19 +00:00
Pat Manning
900ef936ad Animate icon dimming in taskbar when force showing in immersive mode.
Test: manual
Bug: 203748818
Change-Id: Iab3c65db502e7dbde3141429e9ae70eec1fabde1
2022-01-27 17:59:35 +00:00
Tony Wickham
c4f2560b0f Merge "Don't create new nav bar layer when IME is rendering nav buttons" 2022-01-25 20:17:43 +00:00
TreeHugger Robot
3e25f29128 Merge "Add log dumps for taskbar state" 2022-01-21 15:05:32 +00:00
Tony Wickham
27c41677b1 Don't create new nav bar layer when IME is rendering nav buttons
Test: Edit folder name in taskbar, ensure we don't create a new window
Fixes: 214571910
Change-Id: I9a1385dbed2df7a4ee141485c8bbfb521457d853
2022-01-21 00:08:19 +00:00
Schneider Victor-tulias
fa0bfee97a Add log dumps for taskbar state
Test: created bugreport and checked logs
Bug: -
Change-Id: Ic0c2330b18c8daf181ae5b236e0c4b212d630fa3
2022-01-20 14:41:25 -08:00
Merissa Tan
d41ce4980d Create new DesktopNavbarButtonsViewController class.
This CL creates a new DesktopNavbarButtonsViewController class to allow
for taskbar buttons and status icons customization on desktop
environment.

Recall: http://recall/clips/e008d2de-36d3-47f6-954a-5ce18bac69a5

Bug: 213964564
Bug: 196757951
Test: Switch between different system navigation modes and verify the
desktop taskbar buttons stay on screen.

Change-Id: Ie7a9a044fad3b60cd37d910b8eb78c8734aadfd5
2022-01-18 17:10:15 -08:00
Tony Wickham
7b40594bc7 Merge changes I36f6cfb8,I7c784765
* changes:
  Create new window for Taskbar Nav Buttons when taskbar is focusable
  Make taskbar focusable when folder is open to get IME input
2022-01-14 17:12:08 +00:00
Tony Wickham
66971f87e1 Create new window for Taskbar Nav Buttons when taskbar is focusable
Test: Open folder from taskbar, edit name, ensure back button displays above IME and that IME sends input to the taskbar folder name
Bug: 205803170
Change-Id: I36f6cfb835aa7da280f15ea4b0aed8923ce8a012
2022-01-12 14:22:47 -08:00
Pat Manning
2c4a1d8f7a Create taskbar for kids mode.
Test: manual
Bug: 203749295
Change-Id: I52c05cf8685e6e921bb717e9714d1cb2e5f4a351
2022-01-07 11:25:04 +00:00
Winson Chung
3ed9d508bd Merge "Fix some small related to back button alpha" into sc-v2-dev am: 75867ae0ba am: 747dae3bb2
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/16487030

Change-Id: I1392f9f16613ef9fb0add480260d9d5af3fbed16
2021-12-16 22:58:29 +00:00
Winson Chung
e62a1996b7 Fix some small related to back button alpha
- Skip updating nav button dark intensity if we're setting it manually
  while SUW is running
- There should only be one alpha StatePropertyHolder for the same view
  otherwise when updating the properties it can clobber a previous state

Bug: 204384193
Test: Disable dark mode on SUW and verify nav buttons show
Change-Id: I450c3a5697954d9b464bdd622847beb2d01f3802
2021-12-16 17:47:53 +00:00
TreeHugger Robot
368eb46da5 Merge "Set navBarDarkIntensity based on dark theme in SUW" into sc-v2-dev am: f9f90d6dc2 am: 5ebda13e05
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/16482607

Change-Id: I8babe4bae067d8feab9d80c41b48994a33bf19df
2021-12-16 00:50:57 +00:00
Tony Wickham
70d237d8f3 Set navBarDarkIntensity based on dark theme in SUW
- Also remove old tinting based on textColorPrimary, as it's no longer necessary with dark intensity tinting.

Test: Run SetupWizardTestActivity in both dark and light theme, ensure back button visible
Fixes: 204384193
Change-Id: I2dc2e94bc0318ded62419b9ae0eed719db289d7f
2021-12-15 21:37:15 +00:00
Shuming Hao
33e97f1ca4 Merge changes from topic "kingyo-new-buttons-master"
* changes:
  Toggle notification panel when new buttons are clicked in taskbar
  Add new buttons to taskbar
2021-12-15 16:49:19 +00:00
Daichi Hirono
db5960de5e Add new buttons to taskbar
Cherry picked from commit 53db50dd0b2bd6ed1842b25396c9c52b7abe1157
after resolving conflicts

The CL adds two new buttons for desktop usage.
No listeners are registered yet.

Recall: http://recall/clips/f52b70ed-c437-4374-a492-e4b7c802520a

Bug: 198355239
Test: m, verify that new buttons are added

Change-Id: I1d4a12da3041e113a978c37c9e36ec085d15e8b3
2021-12-10 16:24:24 -08:00