Commit Graph

1916 Commits

Author SHA1 Message Date
SongFerngWang
d94ac12190 To fix waiting too long issue when psim -> esim
if the user swithes slot from psim to esim, then the settings
need to wait the simSlotMapping completed and it has a timer to avoid
UI stay here too long.

Since the framework did not sned the carrier config changed with vaild
subId in MEP + psim->esim case, it cause the settings does not know the
simSlotMapping completed and it stay here until timeout.

For MEP case, changing this condition as SimSlotStatusChanged

Bug: 273813956
Test: atest UiccSlotUtilTest
Change-Id: Ic09dbcb3629fe13770f3ad301c0a396d6745969f
2023-07-07 10:22:49 +00:00
Matías Hernández
aaddfd88e9 Merge "Settings: don't try to allow NLSes with too-long component names" into udc-dev am: 4d34eb2c7a
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/23726247

Change-Id: If35fbb5c16a642b56de29012ce43ecd7f068d5b8
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-06-28 17:14:55 +00:00
Hao Dong
be823bc598 Wait for systemui udfps overlay ready to show settings udfps enroll view.
Previously, we show settings's udfps enroll animation view (the fingerprint icon and progress view) once the FingerprintEnrollEnrolling is shown.
However, touch events have to wait for systemui's udfps overlay to be valid. This CL lets settings's udfps enroll view wait for systemui's overlay.
1. Sets udfps enroll animation view's default visibility Gone.
2. Propagates FingerprintManager#onUdfpsOverlayShown to
   FingerprintEnrollEnrolling and when it's called, set the enroll view
   visible.

Besides, this CL renames onPointerDown() and onPointerUp() with Udfps.

Bug: 280718879
Test: atest FingerprintEnrollEnrollingTest
Change-Id: Ieed3e74c182828918785edcacb021f19a3665f2a
2023-06-26 20:21:05 +00:00
Matías Hernández
027f0a46ae Settings: don't try to allow NLSes with too-long component names
* NotificationAccessConfirmationActivity (triggered through CompanionDeviceManager) -> Don't show the dialog, bail out early similarly to other invalid inputs.
* NotificationAccessSettings (from Special App Access) -> No changes, but use the canonical constant now.
* ApprovalPreferenceController (used in NotificationAccessDetails) -> Disable the toggle, unless the NLS was previously approved (in which case it can still be removed).

Fixes: 260570119
Fixes: 286043036
Test: atest + manually
Change-Id: Ifc048311746c027e3683cdcf65f1079d04cf7c56
2023-06-21 17:02:32 +02:00
tom hsu
0a4458a9d1 [Settings] Imporve MMS message UI state update
- When activity entered from outside, the MMS message is not udpated.
   Therefore, add a update behavior to onStart()

Bug: 281566495#5
Test: Manual test passed
Test: atest passed.
Change-Id: I3e5994ad0dbcdd1b78ae3e10e3cb564ce210e93e
2023-06-14 12:28:59 +08:00
Han Xu
15da26329f Add manufactured year into hardware info page am: b452bc9f9d
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/23629342

Change-Id: I53f6c06271bb862cd16e2f3cb48886f764686d40
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-06-12 17:43:44 +00:00
Han Xu
b452bc9f9d Add manufactured year into hardware info page
Bug: 285471557
Test: manual visually
Change-Id: Iaab254ac6ee77217e29d89524d782577f44119cb
2023-06-12 17:43:55 +08:00
Weng Su
7171e0a29b Show "Not available" summary when hotspot speed is unavailable
- Show "Not available" summary when hotspot bands (5 GHz and 6 GHz) are unavailable

- Update debug logs to track down issues

Bug: 285769583
Test: manual test
atest -c WifiHotspotSpeedSettingsTest
atest -c WifiHotspotSpeedViewModelTest

Change-Id: If1050c120b4b612d3a9adbe886c2f12db82b793e
2023-06-08 21:38:01 +08:00
Weng Su
25d259e3e2 Restrict SimDialogActivity
- Restrict UI if user is a guest

- Restrict UI if user has DISALLOW_CONFIG_MOBILE_NETWORKS

Bug: 262242946
Bug: 271849181
Test: manual test
atest -c SimDialogActivityTest

Change-Id: I227400aa71880895d8356f3d2961cb610ad2a357
2023-05-29 07:03:19 +00:00
Treehugger Robot
24db1f3393 Merge "Restrict Printing Settings" into tm-qpr-dev am: 5fa6d3b7dc
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/23296956

Change-Id: Ifa1155d2a3ae19ff743b29b47e088d5d42724f70
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-05-26 17:44:20 +00:00
Yuxin Hu
67c72c01cb Merge "Fix "Enable ANGLE" switch behavior when Developer Option Switch is off" into udc-dev 2023-05-25 18:08:10 +00:00
Treehugger Robot
1fd77775cb Merge "[Settings] Use background thread to get VoNr state." into udc-dev 2023-05-25 06:25:55 +00:00
tom hsu
97a1fc643e [Settings] Use background thread to get VoNr state.
- TelephonyManager#isVoNrEnabled may not send back the result in time,
   so use different thread and timer to prevent ANR.

Bug: 282876876
Test: atest passed
Change-Id: Ie6cc0f8a459f5ebed930e457dacb9b742df70fad
2023-05-25 10:56:03 +08:00
Yuxin Hu
0183cfd816 Fix "Enable ANGLE" switch behavior when Developer Option Switch is off
Fix below bugs:
1) When developer option switch is turned off,
"Enable ANGLE" switch is not disabled. Fixed it in
GraphicsDriverEnableAngleAsSystemDriverController::update().

2) When user turns off developer option switch,
a restart is not always mandatory. However, we should ask
user to restart the device is "Enable ANGLE" is forced to
change due to developer option switch turning off.
Fixed it in DevelopmentSettingsDashboardFragment::onSwitchChanged().

3) When user turns off developer option switch and
the reboot dialog pops up, user can dismiss the dialog by
not clicking either POSITIVE_BUTTON or NEGATIVE_BUTTON.
We should enforce user to click the button and disallow the
option to dimiss the dialog by touching screen areas
outside the window's bounds.
Fixed it in DisableDevSettingsDialogFragment.java.

Did a few clean-up and in
GraphicsDriverEnableAngleAsSystemDriverController.java, and updated
unit test to reflect new code behavior.

Bug: b/270994705
Test: m; flash and device can boot.
Test: atest -c GraphicsDriverEnableAngleAsSystemDriverControllerJUnitTest
Test: atest GraphicsDriverEnableAngleAsSystemDriverControllerTest
Test: atest SettingsRoboTests:FreeformWindowsPreferenceControllerTest
Test: atest SettingsRoboTests:DesktopModePreferenceControllerTest

Change-Id: I199b2fe59b6ad948b753793254c822a293d8b40d
2023-05-24 01:37:35 +00:00
TreeHugger Robot
f6c0e2d4dd Merge "Avoid hotspot band updates when country code is inactive" into udc-dev 2023-05-19 07:40:54 +00:00
Weng Su
8b7e0d7c88 Avoid hotspot band updates when country code is inactive
- The SAP usable channels cannot be queried when the country code is not activated, causing UI to display wrong design

Bug: 280554293
Test: Manual test
atest -c WifiHotspotRepositoryTest

Change-Id: I58e8879438d7a630808aa2c4b69f21eb19968ab1
2023-05-19 12:51:50 +08:00
Weng Su
4c1dd91695 Restrict Printing Settings
- Don't show Printing Settings if the user is restricted by UserManager.DISALLOW_PRINTING

Bug: 269122009
Test: manual test
atest -c PrintSettingsFragmentTest

Change-Id: I15db778ebc4de3c8a76505043fab1ee02db3f290
2023-05-18 18:40:48 +08:00
Zoey Chen
74ab90bb53 Merge "[Regional Preference] Set numbering system when select it" into udc-dev 2023-05-17 09:44:45 +00:00
Zoey Chen
14c81c17ce [Regional Preference] Set numbering system when select it
Should not return original locale, return the locale which is set unicodeLocaleKeyword instead

Bug: 282879594
Bug: 283036197
Test: atest NumberingSystemItemControllerTest
Change-Id: Ic572f20175ea0428be98f30fe865d826b61dcca6
2023-05-17 05:47:53 +00:00
Yuxin Hu
174bd2ab74 Merge "Toggle switch back when user dismisses dialog by tapping screen" into udc-dev 2023-05-16 18:24:14 +00:00
TreeHugger Robot
ab32753382 Merge "[Use] Replace settings LocalePreference with androidx LocalePreference" into udc-dev 2023-05-16 03:51:45 +00:00
Yuxin Hu
2cbb587f81 Toggle switch back when user dismisses dialog by tapping screen
The reboot dialog can be dismissed when user:
1) Clicks any button on the reboot dialog
2) Taps any screen area outside of reboot dialog

We want to toggle back the "Enable ANGLE" switch
whenever the user chooses to not reboot the device
immetiately.

This change adds the function to toggle the
"Enable ANGLE" switch back when:
1) User clicks "Cancel" on reboot dialog.
2) User taps screen area outside of reboot dialog
to dismiss the reboot dialog.

Bug: b/270994705
Test: m; flash and device can boot.
atest -c GraphicsDriverEnableAngleAsSystemDriverControllerJUnitTest

Change-Id: I84fde5ea5bae9d8793bcef30f4c37d832152ae43
2023-05-16 01:58:25 +00:00
Zoey Chen
0d1638c3d3 [Use] Replace settings LocalePreference with androidx LocalePreference
Bug: 263861083
Test: atest and manual test
Change-Id: I7af48074278df0b12c83500f0d2b61eb279e70be
2023-05-15 07:28:05 +00:00
Milton Wu
abfb8a5e9d Fix FaceUpdater.enroll unit test fail in aosp
Ignore related tests

Bug: 281627891
Test: atest FaceUpdaterTest
Change-Id: I028a7dd7fd2e56889ac27051678ca954c896da20
2023-05-14 02:57:05 +00:00
Zoey Chen
4d917d990f Merge "[Panlingual] Do not show dialog in recycle. Set LocaleEditor as the parent fragment and control the dialog." into udc-dev 2023-05-12 03:37:37 +00:00
Zoey Chen
fb6b6b0bcc [Panlingual] Do not show dialog in recycle. Set LocaleEditor as the
parent fragment and control the dialog.

Keep the dialog and the locale list after rotation

Bug: 279527362
Change-Id: I349fd9d0fea5b43a8bbb2a23fa60fc4c5436c5cf
Test: make RunSettingsRoboTests -j128 ROBOTEST_FILTER=LocaleListEditorTest
Test: atest LocaleDialogFragmentTest
2023-05-12 02:40:13 +00:00
Yuxin Hu
6e3aba5366 Merge "Add AndroidJUnitTest for developer option switch" into udc-dev 2023-05-11 20:48:57 +00:00
Yuxin Hu
715a70603c Add AndroidJUnitTest for developer option switch
Bug: b/270994705
Test: m -j45
atest SettingsRoboTests:GraphicsDriverEnableAngleAsSystemDriverControllerTest
atest -c GraphicsDriverEnableAngleAsSystemDriverControllerJUnitTest

Change-Id: Idbb93458a64894c3eba78a8f9373c40e3ddf35c5
2023-05-11 17:59:21 +00:00
Derek Jedral
9c67ee1eb1 Merge "Remove feature flag for active unlock" into udc-dev 2023-05-09 17:17:11 +00:00
Derek Jedral
501f3635dc Remove feature flag for active unlock
Active Unlock was guarded behind a feature flag for two main purposes.
1) To select the unlock intent or biometric failure layout. We've
   settled on unlock intent, so we no longer need the biometric failure
   codepath.
2) To guard the feature rollout. However, the additional platform guard
   is not necessary, since this feature availability is still guarded
   based on whether the secure settings are flipped to valid targets.
In order to keep the scope of this CL small, useBiometricFailureLayout
always returns false. Another CL will clean up all areas where it and
useUnlockIntentLayout are referenced.

Test: make RunSettingsRoboTests
Bug: b/280306741
Change-Id: I331afe9654b72249d461007c087e7f81783d7625
2023-05-08 12:46:36 -07:00
Chaohui Wang
2901125674 Fix flicker in SIM card page
Before fix, the DefaultSubscriptionController will set an empty summary
before data is ready.

Not set the summary before data is ready to fix.

Also fix the ignored tests.

Fix: 277301125
Test: Manual on Mobile Settings
Test: Unit test
Change-Id: I07d964b9f9ce21f8f168cb775eea188e48172c5d
2023-05-08 19:07:28 +08:00
Chaohui Wang
ab8a130674 Clean up DefaultSubscriptionController.getSummary
Which is always overridden by subclass after Change
I7d29b58ca5476ae0bb6fe2e04fecb96164cb1ada

This is a no op.

Bug: 277301125
Test: Manually with Mobile Settings
Test: Unit test
Change-Id: Ifa5928e1026b18c33f2bdd51fdcba267249dcee5
2023-05-08 18:56:06 +08:00
TreeHugger Robot
3a2b8e81e5 Merge "[Settings] Remove WFC enabled state condition of querying Telecomm." into udc-dev 2023-05-04 14:57:36 +00:00
Tom Hsu
99e03458fa Merge "[Settings] Fix NPE from updating subinfo changed." into udc-dev 2023-05-04 04:21:51 +00:00
Becca Hughes
b21df6c5fc Align settings with new mocks
Test: ondevice
Bug: 278919696
Change-Id: I274126bce3616596c4a81dd3385f0844d8bdbf71
2023-05-02 23:50:22 +00:00
Becca Hughes
ddf359d0f8 Fork autofill default app selection
We are merging the default app selection for autofill
with credman so this forks the existing UI (so we can
flag it off).

Test: ondevice
Bug: 278919696
Change-Id: I96bcf1ff86b169a182b9974f7384c45b474c3d5d
2023-05-02 20:31:14 +00:00
tom hsu
21860761e8 [Settings] Remove WFC enabled state condition of querying Telecomm.
- Query WFC enabled state by querying Telecomm may have problem.
 - Only use ImsMmTelManager API to check WFC enabled state.

Bug: 278108377
Test: atest passed
Change-Id: I6d1122bcf66ed5cd274e99b7b4f13558ab922162
2023-05-02 12:57:35 +00:00
tom hsu
fa0bdabc6a [Settings] Fix NPE from updating subinfo changed.
- Refactor code to avoid NPE.

Bug: 278721219
Test: make passed
Test: atest MobileDataPreferenceControllerTest passed
Change-Id: I1fe57b8835677335ae9102cfff71451060ea4f78
2023-05-02 11:40:12 +00:00
Tom Hsu
bd9263b391 Merge "[Settings] UI part: Add metrics for language" into udc-dev 2023-04-28 02:49:59 +00:00
Zoey Chen
cfaa13442c [Settings] UI part: Add metrics for language
Bug: 279915462
Test: atest
Change-Id: Ie13c57b2b398beb48dfe0ac289ec336483575445
2023-04-27 15:55:45 +00:00
Becca Hughes
99f1d5448d DO NOT MERGE Hide provider from this list if autofill provider
Since we are merging the two lists we should
hide the provider from this list to avoid
duplicates.

Test: local & unit
Bug: 279205251
Change-Id: I70ec4a4bda13bdcd5fd8f82f6ba6045e94d5daa9
2023-04-26 21:23:30 +00:00
Treehugger Robot
9cdf565458 Merge "Restart Wi-Fi tethering automatically if configuration change" into udc-dev 2023-04-26 03:59:47 +00:00
Matías Hernández
c49cb1014c Merge "Tweak refresh of notification channel group preferences" into udc-dev 2023-04-25 14:00:14 +00:00
SongFerngWang
c054498357 Replace the SlicePreference with Preference am: 794fc58235
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/22755956

Change-Id: I5e9032624347b27acb02eafd28002744d92b5f2f
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-04-25 06:23:25 +00:00
Zoey Chen
c31cf3d3b4 Merge " [Settings] UI part: Add metrics for numbers preferences" into udc-dev 2023-04-25 03:00:20 +00:00
Zoey Chen
10fa1b8aec [Regional Pref] Remove Calendar controller and related Fragement
Bug: 275003276
Bug: 264483854
Change-Id: I2431ea55a7a69db8a4f661a125a6ca218ce41a94
2023-04-24 10:27:10 +00:00
Zoey Chen
4aa05e58bb [Regional Pref] 1. Add metrics for user changes the First day of week 2.
Refactor to Settings design

Bug: 275003276
Bug: 264483854
Change-Id: Ibea987b6e51fd76c89a0ff5269da6e99171f6b1c
2023-04-24 10:26:52 +00:00
Zoey Chen
5d2ce38d3a [Regional Pref] 1. Add metrics for user changes the Temperature unit 2.
Refactor to Settings design

Bug: 275003276
Bug: 264483854
Change-Id: Ib886ace45db8cfd7dd0f468d03a0aa0551f1f5c4
2023-04-24 10:25:44 +00:00
Zoey Chen
af05cf7e0e [Settings] UI part: Add metrics for numbers preferences
Bug: 275003276
Test: local test
Change-Id: I2455252f3ed7f5355a363a79076113bd4452732d
2023-04-24 10:22:03 +00:00
Matías Hernández
8c40305ad6 Tweak refresh of notification channel group preferences
Previously, we were discarding and re-adding all channel preference switches when a group was toggled. This caused the group switch itself to flicker and sometimes lose the a11y focus as well. Because the group toggle is always at the top, it's not necessary to ever re-sort it (which is the main reason for doing the remove+add dance).

This CL also resurrects ChannelListPreferenceControllerTest which was disabled.

Fixes: 248056830
Test: atest ChannelListPreferenceControllerTest

Change-Id: I5672c102d4571430e26ad6bee92d8c88794214ae
2023-04-24 11:39:59 +02:00