Commit Graph

21554 Commits

Author SHA1 Message Date
Samuel Huang
4f454b43c6 Fix the "Use this SIM" switch does not disable during phone calls
If the registration failed (e.g., device doesn't support satellite), SatelliteManager will not emit the current state by callback. We send `false` value by ourself to make sure the flow has initial value.

Bug: 315928920
Test: atest, manual
Change-Id: Ic87f71bc576cfb1f8e4053c5784fca401adaec08
2024-04-26 05:54:40 +00:00
Samuel Huang
fea80bf236 Merge "Ignore ACTION_PRIMARY_SUBSCRIPTION_LIST_CHANGED event if satellite session is started" into 24D1-dev 2024-04-26 03:08:53 +00:00
Samuel Huang
faa640e8fc Ignore ACTION_PRIMARY_SUBSCRIPTION_LIST_CHANGED event if satellite session is started
When satellite session is started, we need to suppress the 'Choose SIM for mobile data' and 'Update preferred SIM' dialogs to prevent user turn on SIM.

Bug: 334139957
Test: atest, manual
Change-Id: Id56a98f3d1cfd38875173a643c992393d3dbeec8
2024-04-25 13:34:43 +00:00
Rafael Higuera Silva
36d99e8b09 Extract and fix logic for showing rac dialog.
Added tests to make sure the logic makes sense.

Bug: 335745726
Test: make, manual, atest SubscriptionUtilRoboTest, atest SubscriptionUtilTest, atest ResetNetworkTest
Change-Id: I7092f2747f1ca1f9ef4dc99275a916b9e24d8b28
2024-04-25 01:34:47 +00:00
Thomas Nguyen
c6005fb22a Disable SIM On/Off operation when device is in a Satellite session
Bug: 330585109
Test: SatelliteManagerTestOnMockService SatelliteSessionControllerTest SatelliteControllerTest
Manual test with demo and real mode

Change-Id: Iade6426981f76a0b9b71828e0c86d3088c3e974e
2024-04-24 16:35:13 +00:00
Chaohui Wang
4f5920c3f5 Not include user input in regex
Check prefix and remove prefix first, to avoid include user input in
the regex to fix.

Fix: 335136289
Test: manual - on SIMs
Test: unit test
Change-Id: Iff4dcfc3662c744d00b586d05e64b4f5fe33a0d8
2024-04-22 04:56:57 +00:00
Rafael Higuera Silva
6389239f76 Merge "Add logic to log interaction of RAC warning dialog." into 24D1-dev 2024-04-18 16:28:38 +00:00
Treehugger Robot
f02cfc9526 Merge "Add logic to log interaction of RAC warning dialog." into 24D1-dev 2024-04-17 17:30:24 +00:00
Samuel Huang
316e7bf3e6 Disable SIM On/Off operation when device is in Satellite Enabled Mode
Cherry-picking ag/26965536 into the 24D1-dev branch caused conflicts. Therefore, manually create this CL to migrate the MobileNetworkSwitchController to Kotlin and utilize Compose.

Bug: 315928920
Test: atest, manual
Change-Id: I215b5a4615a3b3da6fc160f76c85c814210cc3ef
Merged-In: I7aaaf43b4c449129197e7cc92565d274ffdd2d8c
2024-04-16 09:52:00 +00:00
Pajace Chen
d9b44a8b9c Add charging string V2 for settings
Apply charging string V2 for settings

Bug: 328546483
Test: Manual test
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:6f3c97f60a966a8ec357ba4d15b19d9d7a04b34d)
Merged-In: Ic68bf4231da81d865faa285bca97a929abe26a42
Change-Id: Ic68bf4231da81d865faa285bca97a929abe26a42
2024-04-12 06:23:55 +00:00
Samuel Huang
f2ed0ec752 Avoid SIM card on/off dialog pop-up if satellite is enabled
In order to support Satellite SOS, device will have two modems, one for TN, one for NTN(satellite).

When device switches to satellite mode, PSS only disables TN eSIM (and not TN PSIM). Since NTN image only supports eSIM, there is no need to disable TN PSIM before switching to NTN image. Somehow device is seeing that TN PSIM is available and is showing the user to enable it. So we need to handle it by not showing this dialog during satellite mode enabled.

Bug: 330585109
Test: atest, manual
Change-Id: I9781b7e1cef8f7f10e7ecdbb23ca729da4d06eba
2024-04-11 05:20:53 +00:00
Rafael Higuera Silva
268fa16d5b Add logic to log interaction of RAC warning dialog.
Bug: 326618987
Test: make, atest EuiccRacConnectivityDialogFragmentTest
Change-Id: Iccec9245da27d525cfb3d74504ab86859e152a6e
Merged-In: Iccec9245da27d525cfb3d74504ab86859e152a6e
(cherry picked from commit ea0453e5f6)
2024-04-10 16:26:06 +00:00
Song Chun Fan
844d2f4c67 [Settings/Archive] remove all checks for the archiving system property
No longer needed

BUG: 331165939
Test: builds
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:6ae958abd26ed77ecd4d3fb1720bb912553da2ea)
Merged-In: I24bc9a3d7503da1606d29eb3dfa963b0e6bf9d3e
Change-Id: I24bc9a3d7503da1606d29eb3dfa963b0e6bf9d3e
2024-04-09 18:08:41 +00:00
Rafael Higuera Silva
5405aa17a1 Add logic to log interaction of RAC warning dialog.
Bug: 326618987
Test: make, atest EuiccRacConnectivityDialogActivityTest
Change-Id: If4e3285b3715e9630d4932d4bf1bcb71e4167cff
Merged-In: If4e3285b3715e9630d4932d4bf1bcb71e4167cff
2024-04-09 17:14:35 +00:00
Rafael Higuera Silva
363535192d Add new warning dialogue when user is Resetting mobile network settings.
If the user is reseting mobile network settings and have all these
conditions:
- No Wi-fi
- Has check to delete all eSIMs
- Has a least one RAC sim carrier
Then show the warning dialogue.

Test: make, manually test, atest SubSettingLauncherTest, atest ResetNetworkTest,  atest SubscriptionUtilTest
Bug: 328649510
Merged-In: I47d9b868b649b259d5e4008ec742317d2cb7cf51
Change-Id: I47d9b868b649b259d5e4008ec742317d2cb7cf51
(cherry picked from commit 147cc19b53)
2024-04-05 21:39:13 +00:00
Treehugger Robot
214646a032 Merge "Add new dialogue when user is going to delete multiple sims where aleast on of them use RAC." into 24D1-dev 2024-04-01 21:56:24 +00:00
Rafael Higuera Silva
496075f1be Add new dialogue when user is going to delete multiple sims where aleast on of them use RAC.
Test: make, manually test, atest com.android.settings.network, atest SubscriptionUtilTest
Bug: 328649505
Change-Id: I0c6fb7b5407179ec6850ece47f486b64759e2d1c
(cherry picked from commit 9ac44b3aae)
2024-03-24 23:46:53 +00:00
Andy Wickham
9aa1c402ae Allows for system navigation settings to be added dynamically.
This allows for controller-backed preferences to be added or
overridden via xml.

Similarly, if the controllers cause all of the preferences for
2 or 3 button nav to be unavailable, we hide the settings button.

Bug: 324036308
Test: Manual and unit tests
Flag: NA
Change-Id: I2371f3173076172489966728ac69c8767570cd56
Merged-In: I2371f3173076172489966728ac69c8767570cd56
2024-03-21 20:31:06 +00:00
George Chang
1df6f6a976 Merge "Revert "settings(dev): Remove NFC stack logging control"" into 24D1-dev 2024-03-19 05:06:34 +00:00
Chaohui Wang
67579d564b New countryIfOriginLabel
And display this label as fallback when Regulatory Image is missing.

Bug: 329378943
Test: manual - on SIMs
Test: unit test
Change-Id: I0b8851da20face9ca444b3e6456a4a662b944b65
Merged-In: I0b8851da20face9ca444b3e6456a4a662b944b65
2024-03-15 09:23:31 +00:00
George Chang
b5d57eaa58 Revert "settings(dev): Remove NFC stack logging control"
This reverts commit a5bd1cf34f.

Bug: 329776725
Test: manual turn on/off debug logging.
Merged-In: I3c6026e230c7d35f04d9771442fadbf040a84b94
Change-Id: Ica004bb5f22636777287acfe1226b0f6a650d4f7
2024-03-15 05:55:41 +00:00
Wilson Wu
7fe0754011 Fix keyboard vibration settings delay
The default settings observer delay is 10s for
background service. It cause the apps get the
settings update delay and lead a unsync behavior.

Update the settings change without delay.

Bug: 327094397
Test: Manual test with bug steps
Test: atest KeyboardVibrationTogglePreferenceControllerTest
Change-Id: Ib1c23ec9e1442e8397c7a36ffa157594ac64a9b3
(cherry picked from commit f2174611b8)
Merged-In: Ib1c23ec9e1442e8397c7a36ffa157594ac64a9b3
2024-03-14 02:40:12 +00:00
Jacky Wang
081dbac72e Reset app preferences does not trigger backup for App battery usages
Bug: 328712606
Fix: 328712606
Test: UT && Verify logcat when change/reset App battery usages
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:ef8a51fac85eedee8f9509b9f7c002281c1ae093)
Merged-In: Ia3917c8dc2654185f5f048c048362fd47379b7d1
Change-Id: Ia3917c8dc2654185f5f048c048362fd47379b7d1
2024-03-13 03:23:50 +00:00
Wilson Wu
81f2587fd4 Add fixed amplitude check for keyboard vibration
Make sure the keybaord vibration settings only show
up when fixed amplitude provided to avoid any unsync
behavior with platform.

Bug: 326027376
Test: atest KeyboardVibrationTogglePreferenceControllerTest
Change-Id: I3b4e06660e3eaa6ce537b72831073f092cba37e2
2024-03-08 11:22:34 +00:00
Graciela Wissen Putri
a0f573a35e Follow config overlay's order of aspect ratio options
Fix flaky UserAspectRatioAppsPageProviderTest by using advanceUntilIdle
to make sure all coroutines are finished before asserting.

Bug: 325911424
Test: atest UserAspectRatioDetailsTest
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:32815ad699448c5c5b1f38df6d2d2a881d4251c1)
Merged-In: I83e9a7f31536c1a006789722b0310f3364d14337
Change-Id: I83e9a7f31536c1a006789722b0310f3364d14337
2024-03-05 17:11:59 +00:00
SongFerng Wang
71c6c3e557 Merge changes I96574a79,I74681222 into main
* changes:
  Fix the testcase failed
  Add the log for SidecarFragment
2024-03-04 12:27:37 +00:00
songferngwang
c9a3eeb792 Fix the testcase failed
Add mock for SubscriptionManager.createForAllUserProfiles

Bug: 323652989
Test: atest MobileNetworkPreferenceControllerTest
Change-Id: I96574a79eba581db95d387f0d9c9fde2e004c41c
2024-03-04 10:58:22 +00:00
SongFerng Wang
d94a556939 Merge "Fix SimDialogActivityTest" into main 2024-03-04 08:48:11 +00:00
Angela Wang
6089d3edd6 Merge "Replaces HearingDevicePairingDetail with HearingDevicePairingFragment" into main 2024-03-04 06:53:19 +00:00
Jacky Wang
16a99aecae Merge "[DataStore] Migrate BatteryBackupHelper to BackupRestoreStorage" into main 2024-03-04 03:58:29 +00:00
Weng Su
1a2d60a867 Merge "Ignore failed Wi-Fi unit tests" into main 2024-03-04 03:47:47 +00:00
Weng Su
777157b5b4 Ignore failed Wi-Fi unit tests
Bug: 323645528
Flag: None
Test: unit test
atest -c SettingsUnitTests:RequestToggleWiFiActivityTest \
         SettingsUnitTests:WifiDialog2Test \
         SettingsUnitTests:WifiUtilsTest

Change-Id: I8d3ddb1eb775b8758cb359cac4dac39bb9c8dfed
2024-03-04 06:07:40 +08:00
Jacky Wang
006bf17c4f [DataStore] Migrate BatteryBackupHelper to BackupRestoreStorage
Bug: 325144964
Test: Manual tests
Change-Id: I19f7c78969d70648d1e45f1627827d98b1fdd1e0
2024-03-03 22:42:00 +08:00
songferngwang
3f6d1dc3e5 Fix SimDialogActivityTest
Can't create handler inside thread

Bug: 323649089
Test: atest SimDialogActivityTest
Change-Id: I678a1a1841ab1e1cd87c358fbb3d52cbfb55dbe4
2024-03-02 14:45:47 +00:00
Chaohui Wang
bec4c9573e Create isSubscriptionEnabledFlow
To better display the isEnable checked state.

Bug: 318310357
Test: manual - on Mobile Settings
Test: unit test
Change-Id: Ia595e7445650ad67883f1e7c1a0662cb826565ea
2024-03-02 05:01:28 +00:00
Treehugger Robot
29e984b13a Merge "settings(dev): Remove NFC stack logging control" into main 2024-03-02 02:16:24 +00:00
Treehugger Robot
14f9f67df6 Merge "Make SmartBatterySettings unsearchable when it's not available." into main 2024-03-01 17:56:59 +00:00
Yiling Chuang
93c0dbf98d Make SmartBatterySettings unsearchable when it's not available.
Bug: 323915905
Test: robotest
Change-Id: I5adc9d19b482b8e07237f5c7d62d315556095c38
2024-03-01 16:28:12 +00:00
Shaowei Shen
624e1beca8 Merge "[A11y Setting] Add keyboard keys preferences under A11y page" into main 2024-03-01 13:37:03 +00:00
shaoweishen
a5f5ff4add [A11y Setting] Add keyboard keys preferences under A11y page
Bug: 325851068
Test: make RunSettingsRoboTests
Change-Id: Ic7eb1ec9e260a95d040bee784cbff479a4f087d0
2024-03-01 12:05:30 +00:00
Treehugger Robot
64f740e599 Merge "Revert "Re-enable failed tests under settings/widget/"" into main 2024-03-01 05:02:25 +00:00
Fan Wu
4826dd8c10 Revert "Re-enable failed tests under settings/widget/"
This reverts commit cfb73e2dd3.

Reason for revert:
Still failing when running the entire test suite.

Change-Id: I1783265ca8362a2e1d4b89a1d577e1c0a35bd535
2024-03-01 02:28:07 +00:00
Marcus Ge
12108acc07 Merge "[Accessibility] Add basic metrics logging for color contrast" into main 2024-02-29 21:04:23 +00:00
Kangping Dong
830d4c0b1e Merge "[Thread] add Thread toggle in settings" into main am: 522e193947 am: abd5f23fe9
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/2909326

Change-Id: If086f510fe5d3b3f67b4f168f2e0d3f5e0ef98bd
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-02-29 18:25:13 +00:00
Roshan Pius
a5bd1cf34f settings(dev): Remove NFC stack logging control
We are now turning on verbose logging by default.

Bug: 327517842
Test: Compiles
Change-Id: I3c6026e230c7d35f04d9771442fadbf040a84b94
2024-02-29 09:44:37 -08:00
Kangping Dong
abd5f23fe9 Merge "[Thread] add Thread toggle in settings" into main am: 522e193947
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/2909326

Change-Id: I8640f2cf4a90203972a5db703ebb3e027224c746
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-02-29 17:43:51 +00:00
Kangping Dong
5fc01ddd6e [Thread] add Thread toggle in settings
Allows a user to disable or enable Thread network / radio from
settings.

In this commit, a toggle is added to Settings > Connected devices >
Connection preferences to control Thread state. See the screenshots
below:
1. Thread is on: https://screenshot.googleplex.com/7FqqbzRX6rGwvSb
2. Thread is off: https://screenshot.googleplex.com/AmfRAhzuukULAAG
3. Thread is disabled by airplane mode: https://screenshot.googleplex.com/7zcesyomrveCqFE
4. Thread is searchable: https://screenshot.googleplex.com/9yFL2jeSuEhJwrS

Requirements:
1. the in-take bug: b/327098435
2. See the screenshot above
3. Test with `atest SettingsUnitTests` and manual tests
4. +2 from Yuwen
5. Flagged by "com.android.net.thread.platform.flags.Flags.thread_enabled_platform"
6. It doesn't need B&R, no preferences are added (the state is in
   Android framework (mainline module))
7. Confirmed searchable
8. Code written in Kotlin

Bug: 296990038
Bug: 319077562
Test: atest SettingsUnitTests
Change-Id: Ifa2264b8e59a5112290fd0224cb75ad228732077
2024-02-29 18:05:49 +08:00
Yiyi Shen
e5302bc1f1 Merge "[Audiosharing] Gates legacy le audio sharing UI in sound Settings." into main 2024-02-29 09:50:42 +00:00
Fan Wu
c59c3a3d4f Merge "Re-enable failed tests under settings/widget/" into main 2024-02-29 08:53:15 +00:00
Fan Wu
cfb73e2dd3 Re-enable failed tests under settings/widget/
The failing tests should be fixed by the underlying test framework updates

Bug: 315133235

Test: atest
Change-Id: I7f5d8f6af9193409253418b02b674a721489eb28
2024-02-29 02:55:06 +00:00