Commit Graph

19135 Commits

Author SHA1 Message Date
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
TreeHugger Robot
c59fbb1d28 Merge "Fix FaceUpdater.enroll unit test fail in aosp" into udc-dev am: 92e760861d
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/23155080

Change-Id: Ie1f2632f9e3a6825b856555e3aadd8cd81bbcd90
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-05-16 00:40:48 +00:00
TreeHugger Robot
92e760861d Merge "Fix FaceUpdater.enroll unit test fail in aosp" into udc-dev 2023-05-15 23:56:06 +00:00
Behnam Heydarshahi
f07e023302 Remove volume_separate_notification flag
Fully enable the feature

Bug: b/255363741, b/38477228

Test: make DEBUG_ROBOLECTRIC=1 ROBOTEST_FILTER="NotificationVolumePreferenceControllerTest|SeparateRingVolumePreferenceControllerTest|RingerModeAffectedPreferenceControllerTest|SoundSettingsTest" RunSettingsRoboTests -j40
Change-Id: Iec490fc254f71b6461dbf9f9beb4a11645a4a497
2023-05-15 21:19:26 +00:00
ykhung
7a343c34d9 Remove useless optimization mode backup for FULL_POWER_LIST am: 2c125d29a3
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/23240822

Change-Id: I5e0eefdb421970cc0c405666db0e8b629e2423e1
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-05-15 17:36:41 +00:00
ykhung
2c125d29a3 Remove useless optimization mode backup for FULL_POWER_LIST
Remove the useless backup for the FULL_POWER_LIST, since we will not use
it to restore data, only backup the optimization_mode_list is enough

Test: presubmit
Bug: 192523697
Change-Id: I95f1f41732b8aff090e8b722896d153f6181a6ac
2023-05-15 23:45:16 +08:00
ykhung
d056edc15c Disable the optimization mode preference if the app is not settable am: 5cd3a7298e
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/23235859

Change-Id: I9d81ec00c5f5df7771f28f6bdc4775b7fdba987e
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-05-15 12:43:08 +00:00
ykhung
5cd3a7298e Disable the optimization mode preference if the app is not settable
https://screenshot.googleplex.com/BbQyEv6YCjPVwUF (allowlist)
https://screenshot.googleplex.com/3hTb8TQwGMQqcwS
https://screenshot.googleplex.com/6hdTAT2yNFucD9N (system app)
https://screenshot.googleplex.com/77T5JyAD5nZJpDT (normal app)

Fix: 281566984
Test: make test RunSettingsRoboTests ROBOTEST_FILTER=com.android.settings.fuelgauge.*
Change-Id: If7aa4b61bc806daa570187da24b7f454cd069dec
2023-05-15 09:32:09 +00:00
Treehugger Robot
2150660ddc Merge "Add allowlist mechanism for battery optimization mode" into udc-dev am: 2b91f1a4cb
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/23216878

Change-Id: Id149ac65a51676e1622a023ab3159ea2c0ecc731
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-05-15 08:31:04 +00:00
Treehugger Robot
2b91f1a4cb Merge "Add allowlist mechanism for battery optimization mode" into udc-dev 2023-05-15 07:43:05 +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
ykhung
0cd24adec5 Add allowlist mechanism for battery optimization mode
Add a mechanism to add package name into the allowlist to avoid users
change the battery optimization modes for specific apps in the list

https://screenshot.googleplex.com/8hrHCcTh5bNYXqp

Bug: 281566984
Test: make test RunSettingsRoboTests ROBOTEST_FILTER=com.android.settings.fuelgauge.*
Change-Id: I8efa6a55646d761f5bee3667a59b38ab68c74bc1
2023-05-15 14:28:49 +08:00
YK Hung
a8830ef203 Merge "Update battery health state intent (2/3)" into udc-dev am: 83de631175
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/22741222

Change-Id: Idc66a34c67b4ae570a6167c0704a25303a2629dd
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-05-15 03:42:48 +00:00
YK Hung
83de631175 Merge "Update battery health state intent (2/3)" into udc-dev 2023-05-15 03:27:44 +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
Peter Zhang
60069d3039 Merge "Add logging when a group tile with PreferenceCategory widget is added to the screen" into udc-d1-dev 2023-05-12 16:22:38 +00:00
Peter Zhang
04545138c7 Merge "Add the support of preference group / category to the Settings Tile API" into udc-d1-dev 2023-05-12 16:09:34 +00:00
Jason Hsu
782ad66ab1 Merge "Move 'Audio Output' to Accessibility hearing device page" into udc-dev am: 181cfa3aa5
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/23157344

Change-Id: I1abbb60af43135718426d349427738d95808ff50
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-05-12 14:23:10 +00:00
Jason Hsu
181cfa3aa5 Merge "Move 'Audio Output' to Accessibility hearing device page" into udc-dev 2023-05-12 14:20:23 +00:00
Treehugger Robot
a823380436 Merge "Update battery settings remaining time format" into udc-dev am: e99f757f60
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/23199829

Change-Id: I78e897de5a2198f21de61422b88adbc4cf7aa34b
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-05-12 12:43:30 +00:00
Peter Zhang
f6a267bd36 Add logging when a group tile with PreferenceCategory widget is added to
the screen

Test: robotest, manual
Bug: 281517110
Change-Id: I4de1938bdeea003c70e5c554e988a97b762f7f81
2023-05-12 14:41:32 +02:00
Peter Zhang
baeca6fb53 Add the support of preference group / category to the Settings Tile API
Test: robotest, manual
Bug: 281517110
Change-Id: Ie36b0b3eb8ed80766efa050f1f0aee1f784a5949
2023-05-12 14:40:41 +02:00
Treehugger Robot
e99f757f60 Merge "Update battery settings remaining time format" into udc-dev 2023-05-12 12:29:14 +00:00
Peter Zhang
5b81bbfd02 Merge "Render an additional icon to the tappable tiles with pending intents" into udc-d1-dev 2023-05-12 12:12:21 +00:00
Peter Zhang
15a11c4123 Merge "Expand SettingsLib ProviderTile to support non-switch type of Preferences" into udc-d1-dev 2023-05-12 12:08:00 +00:00
Oli Thompson
787a054c93 Merge "Update Work profile settings" into udc-dev 2023-05-12 11:05:57 +00:00
Wesley Wang
77deb463a0 Update battery settings remaining time format
- Update the remaining time format to align with status bar
 - Remove unused test case since no more less than 7 or 15 remaining time
   case for battery settings
 screenshots:
   https://screenshot.googleplex.com/8jPYPj7yznGFU4b.png
   https://screenshot.googleplex.com/5GYXA2tusSUVmVQ.png
   https://screenshot.googleplex.com/3EnB3ejAxAzP28q.png
   https://screenshot.googleplex.com/5jeUxwBEyHotf9d.png

Bug: 281685505
Test: make SettingsLibRoboTests
Change-Id: If33e1828582845f78d8ef666c2b74ab5bba22357
2023-05-12 11:05:05 +00:00
jasonwshsu
212470d0a6 Move 'Audio Output' to Accessibility hearing device page
* Extract the common part into HearingAidHelper.
* Remove abstract getHearingDevice(). Change to get the hearing device when needed.
* Move several classes from Bluetooth into Accessibility

Bug: 281783079
Test: make RunSettingsRoboTests ROBOTEST_FILTER="(HearingDeviceAudioRoutingBasePreferenceControllerTest|AccessibilityHearingAidPreferenceControllerTest|HearingAidHelperTest|HearingAidAudioRoutingPreferenceControllerTest|HearingDeviceCallRoutingPreferenceControllerTest)"
Change-Id: I79049107409b7086c6dcc8d48a6323e171ed1535
2023-05-12 13:46:53 +08:00
Tom Hsu
0af8c60342 Merge "[Settings] Avoid to unregister wrong observer" into udc-dev 2023-05-12 05:16:28 +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
TreeHugger Robot
b7b444896e Merge "Fix failing test cases in MobileNetworkSummaryControllerTest" into udc-dev 2023-05-12 01:34:00 +00:00
Hao Dong
1eb3724e1f Merge "Hide description text view if there is overlap." into udc-dev 2023-05-11 22:10:55 +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
Hao Dong
cddf296c82 Hide description text view if there is overlap.
1. Includes udfps enroll view in xml files and cleans up FingerprintEnrollEnrolling adding udfps enroll view code.
2. Clean up SETTINGS_SHOW_UDFPS_ENROLL_IN_SETTINGS flag.
3. If description text view has overlap with udfps progress view, hide the description text view.

Test: atest FingerprintEnrollEnrollingTest
Test: manually test by setting both display and text largest size and
start enrolling fingerprint; the description is hidden if it's too long.
Bug: 260970216
Change-Id: I085dc62993ffa22d018dd57517c96d69e9d9cbcb
2023-05-11 17:34:07 +00:00
Hao Dong
c753221adf Merge "Set EXTRA_KEY_FOR_FINGERPRINT for choose lock screen." into udc-dev 2023-05-11 17:17:06 +00:00
tom hsu
5e2862f2e3 [Settings] Avoid to unregister wrong observer
Bug: 262345047
Test: atest passed.
Change-Id: If324e8f35c15053b48320f86ff22759a6a68a62f
2023-05-12 01:10:19 +08:00
Weng Su
e485615662 Fix failing test cases in MobileNetworkSummaryControllerTest
- Remove obsolete test items

- Update the new callback interface

Bug: 280044539
Bug: 280044731
Test: Manual test
atest -c MobileNetworkSummaryControllerTest

Change-Id: I8460c620c62981dd5ee3b280c1a7467c43dbceb1
2023-05-11 14:15:07 +00:00
Oli Thompson
08b4973f8e Update Work profile settings
Change work apps toggle to a primary toggle
make Xprofile contact search toggle disable/enable when work profile is turned off
Add footer and change strings
Add tests

Test: atest ContactSearchPreferenceControllerTest, atest WorkModePreferenceControllerTest

Bug: 253009702 275538029
Change-Id: I3b2044a5fe3f2aff0748d66e701a3f0d7667ab7a
2023-05-11 14:02:27 +00:00
TreeHugger Robot
c271732a85 Merge "Fix failing test case in AllInOneTetherSettingsTest" into udc-dev 2023-05-11 14:01:25 +00:00
Weng Su
571d9b1f37 Fix failing test case in AllInOneTetherSettingsTest
- Add the necessary mock classes

Bug: 280067520
Test: Manual test
atest -c AllInOneTetherSettingsTest

Change-Id: I6576c6997b43103ea810008b7a1a245e3e42015c
2023-05-11 20:43:34 +08:00
Treehugger Robot
1b91f61633 Merge "Record app optimization mode backup into BatteryHistoricalLog" into udc-dev 2023-05-11 10:54:55 +00:00
Tom Hsu
5576947555 Merge "[Settings] Avoid NPE if BT device is changed by framework." into udc-dev 2023-05-11 04:30:19 +00:00
Wesley Wang
cf1190c7cb Update battery health state intent (2/3)
- Update the extra from overheated to longlife

Bug: 278192441
Test: make SettingsRoboTests

Change-Id: I5a906e64effbd9aaf84446c0670249afefdf7da8
2023-05-11 11:27:16 +08:00
ykhung
8f56114489 Record app optimization mode backup into BatteryHistoricalLog
App optimization mode format:
https://screenshot.googleplex.com/di9DDzBfYf7ihfV

App optimization mode backup format:
https://screenshot.googleplex.com/GkVW5HrgGvmv5yh

Bug: 192523697
Test: make SettingsRoboTests
Change-Id: I60a9a76a8ffc89d625ee3f77c138a19181c81c38
2023-05-11 10:48:47 +08:00
Angela Wang
22d3116188 Merge "Disabled state UI of Flash Notifications preview button" into udc-dev 2023-05-11 01:41:47 +00:00
Hao Dong
755a67a931 Set EXTRA_KEY_FOR_FINGERPRINT for choose lock screen.
Bug: 279823572
Test: atest FingerprintSettingsFragmentTest
Test: atest ChooseLockGenericTest
Change-Id: Ie4bc18bf245eb7a755862401c710d85381063ff9
Merged-In: Ie4bc18bf245eb7a755862401c710d85381063ff9
2023-05-10 23:26:02 +00:00
tom hsu
0617631408 [Settings] Avoid NPE if BT device is changed by framework.
- Do not register only one BT device for primary to avoid primary
   BT devcie change to another.
 - Register and unregister all BT devices

Bug: 280236099
Test: atest passed
Change-Id: I610144c7f8f649e40d99cf1dc7f50d1f3b80f109
2023-05-11 02:53:19 +08:00
Treehugger Robot
6a06cdd1bf Merge "Fix mistake in test" into udc-dev 2023-05-10 15:59:23 +00:00