Commit Graph

577 Commits

Author SHA1 Message Date
shaoweishen
c1438d80f4 [Physical Keyboard] Null check before using layout descriptor
If descriptor is null, pass null to LayoutSelectedCallback.onSelected to
get default layout preview image.

Bug: 396006944
Flag: com.android.settings.keyboard.keyboard_and_touchpad_a11y_new_page_enabled
Test: atest
packages/apps/Settings/tests/robotests/src/com/android/settings/inputmethod/

Change-Id: I6b454a5f0b95c571cac15258977aab5ee12d4327
2025-03-13 14:47:18 +00:00
shaoweishen
b547394a56 [Physical Keyboard] Update seekbars
Update seekbars color and style.

Bug: 374030364
Bug: 399285693
Flag: com.android.settings.keyboard.keyboard_and_touchpad_a11y_new_page_enabled
Test: atest
packages/apps/Settings/tests/robotests/src/com/android/settings/inputmethod/

Change-Id: I251a7241b614114a5bb9d5090fcd22cb873ebc51
2025-03-12 00:50:15 -07:00
Shaowei Shen
e4fed1e6b0 Merge "[Physical Keyboard] Listen input devices change" into main 2025-03-06 19:25:51 -08:00
David Padlipsky
d83aa9b83c Merge "Map pointer speed slider on mouse page to control mouse speed" into main 2025-03-05 11:52:40 -08:00
shaoweishen
0c07f16443 [Physical Keyboard] Listen input devices change
Create new fragment which listen input device change, when input device
detached while pages show, it will exist correctly.

Bug: 399284521
Flag: com.android.settings.keyboard.keyboard_and_touchpad_a11y_new_page_enabled
Test: atest
packages/apps/Settings/tests/robotests/src/com/android/settings/inputmethod/

Change-Id: I3d6b9a4558866a8c4a3aa4fc30e500b8b6be90cd
2025-03-05 03:48:24 +00:00
David Padlipsky
99b20e5c36 Map pointer speed slider on mouse page to control mouse speed
Currently, the pointer slider on the mouse settings page is actually
controlling touchpad pointer speed. Modify this to instead control the
mouse pointer speed.

Bug: 398034722
Test: Manually on device
Flag: com.android.settings.keyboard.keyboard_and_touchpad_a11y_new_page_enabled
Change-Id: I66cec4ef0a758e250bab89c194073eb408402431
2025-02-28 19:42:09 +00:00
shaoweishen
4da457f8a9 [Physical Keyboard] Update Input Setting Dialog
1. update button style to use custom one
2. use scrollview so it won't be truncated in shorter screen

Bug:389973784
Flag: com.android.settings.keyboard.keyboard_and_touchpad_a11y_new_page_enabled
Test: atest
packages/apps/Settings/tests/robotests/src/com/android/settings/inputmethod/

Change-Id: I57765e88751b6090606d56bbe2335813ef7fd2fc
2025-02-21 07:10:40 +00:00
shaoweishen
5daef3cfee [Physical Keyboard] update color of Dialog
1. update color of slider in dialog to increase contrast
2. not showing device name in Mouse key page if there's only one device
   connected
Bug: 374030364
Bug: 377464791
Flag: com.android.settings.keyboard.keyboard_and_touchpad_a11y_new_page_enabled
Test: atest
packages/apps/Settings/tests/robotests/src/com/android/settings/inputmethod/

Change-Id: I94d7859ba1dfdad7fdca2ee750a5afeb881756f4
2025-02-18 03:47:41 +00:00
Vaibhav Devmurari
9dc7367909 Merge "Flag cleanup: keyboard_a11y_(bounce/slow/sticky)_keys_flag" into main 2025-02-11 04:03:17 -08:00
shaoweishen
538cc35aed [Physical Keyboard] Fix bugs for input keys dialog
set content description on custom radio button and seekbar.
fix typo

Bug: 374229004
Bug: 374229189
Bug: 374229597
Bug: 389973787
Flag: com.android.settings.keyboard.keyboard_and_touchpad_a11y_new_page_enabled
Test: atest
packages/apps/Settings/tests/robotests/src/com/android/settings/inputmethod/

Change-Id: I3df4b1558c2bad73d9411a0160725d7a35590cc3
2025-02-06 02:21:06 -08:00
Shaowei Shen
086c8b7955 Merge "[Physical Keyboard] Move Dialog to DialogFragment" into main 2025-02-06 02:20:41 -08:00
Shaowei Shen
259cc0f30d Merge "[Physical Keyboard] Correct key string for mouse key" into main 2025-02-06 01:33:54 -08:00
shaoweishen
0afe4b3e90 [Physical Keyboard] Correct key string for mouse key
Bug:381247635
Flag: com.android.settings.keyboard.keyboard_and_touchpad_a11y_new_page_enabled
Test: atest
packages/apps/Settings/tests/robotests/src/com/android/settings/inputmethod/

Change-Id: I3ebeee285d33d3e25082a523da2d1d188f3b36bc
2025-02-05 06:50:49 +00:00
shaoweishen
50ea6b06d5 [Physical Keybaord] Fix Mouse key image truncate
Seperate Images in Mouse Key page to apply scaling.

Bug: 389665773
Flag: com.android.settings.keyboard.keyboard_and_touchpad_a11y_new_page_enabled
Test: atest
packages/apps/Settings/tests/robotests/src/com/android/settings/inputmethod/

Change-Id: I207c13fb99fa5c01c08c7ca92eae2d1d5781a830
2025-02-04 08:35:11 +00:00
shaoweishen
120b2d46f7 [Physical Keyboard] Move Dialog to DialogFragment
Move Bounce key and Slow key Dialog to DialogFragment, dialog will not
be dismissed when screen rotate.

Bug: 390243451
Bug: 374037603
Flag: com.android.settings.keyboard.keyboard_and_touchpad_a11y_new_page_enabled
Test: atest
packages/apps/Settings/tests/robotests/src/com/android/settings/inputmethod/

Change-Id: Ide87dbf8214f411941114281e7a5e8c81f75bdd4
2025-02-03 09:32:02 +00:00
Vaibhav Devmurari
a55fbee143 Flag cleanup: keyboard_a11y_(bounce/slow/sticky)_keys_flag
Bug: 294546335
Test: manual
Flag: EXEMPT cleanup
Change-Id: I02c632291dae1639af51b6fb23db1a534eaf03c6
2025-02-01 02:46:57 -08:00
Vaibhav Devmurari
9ffa4d241f Flag cleanup in Settings: keyboard_layout_preview_flag
Test: manual
Bug: 293579375
Flag: EXEMPT cleanup
Change-Id: I1f13ab0ab46883622d024f982faba26b1dce0152
2025-01-29 03:54:40 -08:00
Yuhan Yang
d168aaf197 Add metric for mouse scrolling setting changes
Bug: 383555305
Bug: 384795606
Test: m statsd_testdrive
Flag: com.android.hardware.input.mouse_scrolling_acceleration
Change-Id: I9148f13bde2c31373778648fc9b078f5cceffc1c
2025-01-22 11:33:12 -08:00
Harry Cutts
1d28b612fe Merge "Give input team ownership of mouse-related settings files" into main 2025-01-20 02:57:18 -08:00
Michael Checo
c19ccd3bed Merge "Add preference toggle for touchpad acceleration setting" into main 2025-01-17 15:19:57 -08:00
Harry Cutts
f4e8617821 Give input team ownership of mouse-related settings files
Bug: 245989146
Change-Id: I5961839b290af88784da525ff937ff6d6f148963
Test: none
Flag: EXEMPT only changing OWNERS
2025-01-17 07:32:17 -08:00
Josep del Río
733f174fbd Merge "Fix multiple layouts marked as selected" into main 2025-01-16 01:33:54 -08:00
Michael Checo
f47182fe0c Add preference toggle for touchpad acceleration setting
Bug: 387184135
Test: verified on DUT
Flag: com.android.hardware.input.pointer_acceleration
Change-Id: Ic49af4676eaeca6135296fa825d28c8a52af7dc2
2025-01-15 17:59:50 +00:00
YuhanYang
c772324c12 Grey out scrolling speed slider bar
When ever the mouse scrolling acceleration settings is toggled to
set "enabled", the mouse scrolling speed slider bar should be
greyed out.

Bug: 383555305
Bug: 384795606
Test: Local DUT with aconfig flags enabled, verified settings appears
      and is togglable. Verified toggle affects scrolling acceleration.
Flag: com.android.hardware.input.mouse_scrolling_acceleration
Change-Id: Ib96a4437864a0395c8c185bbd8cfb13f3979c84f
2025-01-14 23:15:47 +00:00
Shaowei Shen
e61a297e85 Merge "[Physical Keyboard] Fix bug for Mouse key page" into main 2025-01-13 21:15:13 -08:00
Shaowei Shen
7ebd08bd57 Merge "[Physical Keyboard] Show correct format in a11y key dialog" into main 2025-01-13 21:14:44 -08:00
Yuhan Yang
a12887ff9c Merge "Add mouse scrollling speed slide bar" into main 2025-01-13 19:37:02 -08:00
shaoweishen
2eebf46f40 [Physical Keyboard] Fix bug for Mouse key page
Add default Locale to get keycode for mouse key.

Bug: 387152641
Bug: 386907528
Flag: com.android.settings.keyboard.keyboard_and_touchpad_a11y_new_page_enabled
Test: atest packages/apps/Settings/tests/robotests/src/com/android/settings/inputmethod
Change-Id: I8cc4a08449c13b426ffa24ddc29fd16407b064c8
2025-01-13 09:10:01 +00:00
Josep del Rio
342f2af05f Fix multiple layouts marked as selected
There is a bug in the layout picker that causes all layouts with
the same name to be selected when the layout picker is open.

Bug: 389057831
Flag: EXEMPT minor bugfix
Test: Flashed on device
Change-Id: I22e6b1b5497df8a2a8ebe2e353d913affd250c06
2025-01-10 14:36:44 +00:00
shaoweishen
f1ac7f64cb [Physical Keyboard] Show correct format in a11y key dialog
Format decimals in dialog to avoid inconsistent through languages.

Bug: 388330691
Test: atest SettingsRoboTests
Flag: com.android.settings.keyboard.keyboard_and_touchpad_a11y_new_page_enabled
Change-Id: Icbf1eec2b31614768efb079f4cbeec1fd5b73ef5
2025-01-10 09:49:29 +00:00
YuhanYang
d5e44a0795 Add mouse scrollling speed slide bar
Bug: 383555305
Bug: 84795606
Test: Local DUT with aconfig flags enabled, verified slide bar
      appears and can be updated.
      Verified adjusting slide bar affects scrolling speed.
Flag: com.android.hardware.input.mouse_scrolling_acceleration
Change-Id: Ia66f88ce855ab152a161ef3f81ab643415fad517
2025-01-09 16:32:22 +00:00
Harry Cutts
adfb3a489d Merge changes I32ba2b6b,I3f473d28,I717eb2a2 into main
* changes:
  Touchpad: add @NonNull annotations to controller constructors
  Touchpad: mark MetricsFeatureProviders final
  Touchpad: fix some NullAway warnings
2025-01-09 02:38:54 -08:00
Shaowei Shen
43c9d7d26e Merge "[Physical Keyboard] Fix L18n test bugs" into main 2025-01-09 01:39:02 -08:00
Harry Cutts
fb0b459cf0 Touchpad: add @NonNull annotations to controller constructors
...and to some of the preference controller base classes, too, since I
had to work those out anyway.

Bug: 245989146
Test: m
Flag: EXEMPT unable to flag this kind of change
Change-Id: I32ba2b6b8c05c1379b4d921350050979b1866805
2025-01-08 16:36:43 +00:00
Harry Cutts
0e4edf9527 Touchpad: mark MetricsFeatureProviders final
(Fixing some warnings from Android Studio)

Bug: 245989146
Test: m
Flag: EXEMPT refactor
Change-Id: I3f473d281e8a22d108a52e56e6e53ca056e4a829
2025-01-08 16:33:35 +00:00
Harry Cutts
ae3e005ff9 Touchpad: fix some NullAway warnings
Change I930e9fc85e09e03da3513e5f8443077fa8ea91b0 triggered some NullAway
warnings that are unrelated to the change, but some are trivial to fix,
for example by replacing member variables with local ones.

At the same time, add some `@NonNull` annotations to overriding methods
on Android Studio's recommendation.

Test: check touchpad gesture tutorial and pointer speed settings work
Test: $ atest SettingsRoboTests:com.android.settings.inputmethod
Bug: 245989146
Flag: EXEMPT refactor
Change-Id: I717eb2a2d68a46dce8ebaa95bef1183d09380f51
2025-01-08 11:53:14 +00:00
Harry Cutts
509fd17515 Touchpad: replace references to "trackpad" with "touchpad"
When we first added the touchpad settings we hadn't settled on whether
to refer to them as "touchpads" or "trackpads" yet. We've since settled
on "touchpad", but that's left us with some Settings code referring to
one and some to the other. Let's standardize on "touchpad" since that's
consistent with user-facing strings and the rest of the input codebase.

This CL doesn't change string identifiers, as I believe that would cause
them to get different Translation Console IDs and thus be retranslated.

Bug: 245989146
Test: m
Test: check strings and icons are still displayed correctly in the
      touchpad settings and tutorial, and that settings toggles and the
      tutorial still work
Test: atest SettingsRoboTests
Flag: EXEMPT refactor
Change-Id: I930e9fc85e09e03da3513e5f8443077fa8ea91b0
2025-01-08 11:52:45 +00:00
Shaowei Shen
4166f1b7bd Merge "[Physical Keyboard] Add Metrics event for keyboard relates pages" into main 2025-01-07 01:42:25 -08:00
YuhanYang
c3426d0a87 Add preference toggle for mouse scrolling acceleration
Bug: 383555305
Bug: 384795606
Test: Local DUT with aconfig flags enabled, verified settings appears
and is togglable. Verified toggle affects scrolling acceleration.

Flag: com.android.hardware.input.mouse_scrolling_acceleration
Change-Id: Ibba2bb1c3cb57b98ad34a5851bae7b9d73e48d74
2025-01-06 23:48:43 +00:00
Treehugger Robot
54bb776d5a Merge "Touchpad: remove individual gesture settings" into main 2025-01-06 09:05:06 -08:00
shaoweishen
1f436509f0 [Physical Keyboard] Fix L18n test bugs
1. update string to match with Markup
2. a space for label keys as suggested

Bug: 387267421
Bug: 387572420
Flag: com.android.settings.keyboard.keyboard_and_touchpad_a11y_new_page_enabled
Test: atest packages/apps/Settings/tests/robotests/src/com/android/settings/inputmethod
Change-Id: I787cf6ff4e15509d669317a0d968235a08b4dc43
2025-01-06 10:03:53 +00:00
Harry Cutts
d4a469b4ca Touchpad: remove individual gesture settings
These were never plumbed in, never mind launched, and are sometimes
causing confusion in design discussions when people have the feature
flag turned on. Let's remove them.

Bug: 245989146
Test: check System > Touchpad > Touchpad gestures option is removed even
      when the flag's enabled
Flag: EXEMPT removing code controlled by a legacy sysprop-based flag
Change-Id: I22ca19faf6fed430bb3f0733867716a02514ac8d
2024-12-31 11:47:51 +00:00
Michael Checo
f9a89f1c77 Add preference toggle for mouse pointer acceleration setting
Bug: 384552392
Test: verified on DUT
Flag: com.android.hardware.input.pointer_acceleration
Change-Id: I45de5bdd2456cfb4fab6d1398bdc5d8f7b9efddb
2024-12-27 13:03:59 -08:00
shaoweishen
33f62b4e01 [Physical Keyboard] Add Metrics event for keyboard relates pages
Bug: 377602364
Flag: com.android.settings.keyboard.keyboard_and_touchpad_a11y_new_page_enabled
Test: atest packages/apps/Settings/tests/robotests/src/com/android/settings/inputmethod
Change-Id: I28fc5c7676dcce2ad4aa63ea5745f5597558b0c1
2024-12-25 07:39:49 +00:00
Pat Manning
b50acbfeea Update pointer fill option backgrounds for color contrast and touch
target size.

Fix: 374885995
Fix: 374886964
Test: Manual.
Flag: EXEMPT Bugfix.
Change-Id: Ibf09bfae4a93868ac3605748854ccaaa10847eb6
2024-12-18 14:56:45 +00:00
Treehugger Robot
c3fecca761 Merge "Remove old PK settings pages that are unused" into main 2024-12-17 19:50:54 -08:00
shaoweishen
06fe204a69 [Physical Keybaord] Add keyboard touchpad/Mouse page - part2
screenshot: https://screenshot.googleplex.com/A4yihXmkTTo2nM3.png

Add seperate controllers in page and guard with flag.
Original controller will be disabled if flag is off.

This is part of feature for keyboard setting update.
document: go/new-a11y-touchpad-mouse-page

Bug: 377602364
Test: atest SettingsRoboTests
Flag: com.android.settings.keyboard.keyboard_and_touchpad_a11y_new_page_enabled
Change-Id: I20bf7c65a7f9adc734c7382f23a92d1eb41822f1
2024-12-12 23:28:50 -08:00
Vaibhav Devmurari
58c4286ec9 Remove old PK settings pages that are unused
Test: manual
Bug: 330517633
Flag: EXEMPT cleanup
Change-Id: I2e0e21cf13ae39a09cd8c7b3697bbf18188e1fa8
2024-12-10 18:49:26 +00:00
Marcelo Arteiro
8577c10535 Migrate materialColor* attributes into colors
The new color were already introduces in a previous CL ag/30322786

This CL is about replacing the attribute usage by the new color resources, which should work the same but cannot be overwritten, or styled, guaranteeing consistency across the OS.

The old attributes will be removed in CL: ag/29910036

Bug: 374273611
Test: presubmit
Flag: EXEMPT Un-flaggable refactor of private color resources
Change-Id: I05b5261054bcb6de40e4e40d633025495f3dd01f
2024-12-06 16:55:33 +00:00
Treehugger Robot
25ff6453fb Merge "Touchpad: remove tap dragging flag" into main 2024-12-03 02:33:57 +00:00