Commit Graph

20835 Commits

Author SHA1 Message Date
Oli Thompson
ae10f49ab8 Guard against duplicate calls to setQuietModeEnabled
check if quiet mode is already in the desired state before calling
setQuietModeEnabled

Bug: 303722527
Bug: 293441361
Test: atest WorkModePreferenceControllerTest, atest
ManagedProfileQuietModeEnablerTest

Change-Id: I6a809b6f1b9a78382dccb1cc8b0ae4d8c88fa51a
2023-11-17 15:06:07 +00:00
YK Hung
e43645952f Merge "Update setDenylist() input structure" into main 2023-11-16 08:02:58 +00:00
Wesley Wang
24278e7a92 Update setDenylist() input structure
- Change the input type from list of String to Integer
 - Update test case

Bug: 306329984
Test: make SettingsRoboTests
Change-Id: I018ef49523810577b17375628e45c24270a3bdf4
2023-11-16 07:07:52 +00:00
Chaohui Wang
1a2bf18eae Merge "Fix restriction to configure Calls & SMS" into main 2023-11-16 03:32:37 +00:00
Chun-Ku Lin
e0852d25f7 Merge "Don't show quick settings tooltip if the user is in the Setup Wizard, since the user can't access the Quick Settings Panel." into main 2023-11-16 03:03:57 +00:00
Wa Gao
3185a36b90 Update the unit test and add key to fragment.
Bug: 298076922
Change-Id: I8ed880c4f81bd76adc27af9bc3ba66f0b4697f74
2023-11-15 23:44:11 +00:00
Manish Singh
aa91f1db3a Merge "Reset Private Space settings on new space creation" into main 2023-11-15 13:55:12 +00:00
Manish Singh
7a556b851c Reset Private Space settings on new space creation
Also added PrivateSpaceMaintainerTest

Bug: 310217645
Test: atest PrivateSpaceMaintainerTest
Test: atest HidePrivateSpaceControllerTest
Test: manual
Change-Id: Ic1096fd652d23ae6aa9da1421017c08f6bc480aa
2023-11-15 12:54:20 +00:00
Wesley Wang
2dec2b2785 Merge "Apply dynamic deny list into data usage state" into main 2023-11-15 12:53:25 +00:00
Wesley Wang
f0b67ef0f9 Apply dynamic deny list into data usage state
- Initiate and sync existing network policy when creating the instance
 - Imple a method to suggest list of packages to set as POLICY_REJECT
 - Reset/clear the policy settings once clear storage or reset
   preference

Bug: 306329984
Test: make SettingsRoboTests
Change-Id: I10ba28fee08c29bc2092820fbc8d8ac0e61d30e7
2023-11-15 18:25:19 +08:00
Peiyong Lin
714490851f Merge "Unconditionally enable ANGLE developer option UI." into main 2023-11-15 01:38:35 +00:00
Chun-Ku Lin
0f2cc34230 Don't show quick settings tooltip if the user is in the Setup Wizard,
since the user can't access the Quick Settings Panel.

Bug: 294560581
Test: manual
- Turn on feature flag: adb shell device_config put accessibility com.android.settings.accessibility.remove_qs_tooltip_in_suw true
- Modify the font scale in SUW, verify the QS tooltip doesn't show up
- Modify the font scale after SUW, verify the QS tooltip shows up
Test: atest SettingsRoboTests:com.android.settings.accessibility

Change-Id: I1d1a4f8f70ea3e1d929952d5c273de1b4cd80503
2023-11-14 23:30:49 +00:00
Wa Gao
bd073bc18c Merge "Hide the setting from the search when feature is disabled." into main 2023-11-14 22:16:32 +00:00
josephpv
30e841ce75 Add One Lock settings inside private space settings page
This includes below changes:
1. Add new sub settings page in Private Space settings with option to
   swithch between private profile lock and device screen lock
2. Call Private profile lock setup when swithcing to private lock from
   screen lock.
3. Preference to change private lock when a separate Private lock is set

Bug: 308862923
Test: atest UseOneLockPreferenceControllerTest,
PrivateSpaceLockControllerTest

Change-Id: I0a6d8c7dfbd0ffea19db03ffd6dfe7aa520c9684
2023-11-14 21:27:10 +00:00
Wa Gao
6ffb674ff4 Hide the setting from the search when feature is disabled.
Bug: 310243923
Change-Id: Idb3b903f19d81825e6f721a87ec8c5238c86118d
2023-11-14 20:27:52 +00:00
Chaohui Wang
9e0bd18686 Fix restriction to configure Calls & SMS
Restriction UserManager.DISALLOW_CONFIG_MOBILE_NETWORKS is added.

Fix: 278062379
Test: manual - apply restriction no_config_mobile_networks
Test: unit test
Change-Id: I87bf2269359bbceb989fa10524d55dd7ceb55de1
2023-11-14 09:48:52 +00:00
Angela Wang
c01677b676 Merge "Removes hearing aids settings page flag" into main 2023-11-14 06:47:36 +00:00
Roy Luo
ef2cd0640e Update incompatible charger checking rule
Use COMPLIANCE_WARNING_DEBUG_ACCESSORY to mock incompatible charging
event as COMPLIANCE_WARNING_OTHER is being deprecated.

Bug: 308700954
Bug: 310660470
Test: make -j64 RunSettingsRoboTests ROBOTEST_FILTER="com.android.settings.fuelgauge.batterytip"
Flag: ACONFIG enable_input_power_limited_warning ENABLED
Change-Id: Ib6f7cf253344db99a8cc1d06c59a5c35d40f736f
2023-11-14 01:44:06 +00:00
Treehugger Robot
2933f4d4b8 Merge "Fix the robo test case failed" into main 2023-11-13 08:30:22 +00:00
Sunny Shao
94bf9d9bc3 Fix the robo test case failed
- Fix the test case failed in the
  ControlsTrivialPrivacyPreferenceControllerTest.
- Use the correct paramter in the PackageManager.resolveActivity API.

Fixes: 300378707
Test: atest ControlsTrivialPrivacyPreferenceControllerTest
Change-Id: Id80dfb95ceffb048461b79d2d5ceb67100f83cd5
2023-11-13 14:00:25 +08:00
Xinyi Mao
129919def7 Merge "Update Power Anomaly UI." into main 2023-11-13 05:19:48 +00:00
mxyyiyi
1817f066ec Update Power Anomaly UI.
For Settings tip & app anomaly banner:

- update app anomaly hint color in dark/light theme
[Banner card]
- update icons to GM3 style
- update text font and button text color
- update button style from outlined to filled.
[Chart view]
- update warning icon size
- update percentage label alignment

Screenshots:
- [Settings]
[light]	https://screenshot.googleplex.com/ERWkD7TmDsLaxdG
[dark]	https://screenshot.googleplex.com/6JKvL5vEQTZtJfd
- [App]
[light]
https://screenshot.googleplex.com/3YoncDhGTzUcAZA
https://screenshot.googleplex.com/3hbGmqoYWSy9H9U
[dark]
https://screenshot.googleplex.com/9XKs8tXmRKL2jJP
https://screenshot.googleplex.com/SU4LTJYWXvpd42r
- [RTL+L10N][Arabic]
[Settings] https://screenshot.googleplex.com/V9HJkPcsoBJmsW8
[Apps]
https://screenshot.googleplex.com/B49VKy2jaZYisWK
https://screenshot.googleplex.com/6VZQ2gESRes8RMH
- [Force RTL][EN]
[Settings] https://screenshot.googleplex.com/4V7coyLf5ueUcGv
[Apps]
https://screenshot.googleplex.com/9UaERwDmrpitqdq
https://screenshot.googleplex.com/3JDfcXi8pmz5Mew

Bug: 309569299
Test: manual
Change-Id: I8bee7f86d602112e0cbbd936b439330aaff7275c
2023-11-13 11:52:44 +08:00
Wa Gao
dcf678c835 Merge "Add the dialog when clicking on the diabled switch." into main 2023-11-10 19:13:13 +00:00
Wa Gao
6b9e20d32d Add the dialog when clicking on the diabled switch.
Bug: 302189945
Change-Id: I0bf7774b80a59c70a2ea1725e0adba522854adde
2023-11-10 17:55:25 +00:00
Angela Wang
01f17822c3 Removes hearing aids settings page flag
The hearing aids settings page has successfully rolled out. Cleans up the codes that are related to flag controls.

Bug: 310203155
Test: atest AccessibilityHearingAidPreferenceControllerTest
Test: atest AccessibilityDetailsSettingsFragmentTest
Test: atest BluetoothDetailsHearingDeviceControlsControllerTest
Change-Id: Ib03952f734302cca8519cb1c70ba82601cb75527
2023-11-10 17:06:32 +00:00
Chaohui Wang
4e2fa570bd Merge "Use MobileDataEnabledFlow in BillingCyclePreference" into main 2023-11-10 10:15:30 +00:00
Chaohui Wang
097739eca6 Merge "Extract ClientInitiatedActionRepository" into main 2023-11-10 07:57:38 +00:00
Chaohui Wang
de8876e9b5 Extract ClientInitiatedActionRepository
Also add unit test.

Bug: 300851543
Test: manual - on system page
Test: unit test
Change-Id: I362afb4aa0683ebcc6695ff0b5bc35ef8afb5697
2023-11-10 14:31:07 +08:00
Jacky Wang
e4761149f3 Add cancel button to Erase all data (factory reset)
Bug: 300634367
Test: unit test & manual test
Change-Id: I860955291b27ea1f7c748ac746b91153224eacb7
2023-11-10 13:32:00 +08:00
Chaohui Wang
0739b5edd1 Use MobileDataEnabledFlow in BillingCyclePreference
To easily collect the mobile data enabled setting changes.

Bug: 308903704
Test: manual - on Mobile Settings
Test: unit test
Change-Id: Ic449ce14fad38513b1e13facc6a192d30318c7b0
2023-11-10 10:33:46 +08:00
Chaohui Wang
c292adaf6b Merge "Avoid unnecessary Html.fromHtml()" into main 2023-11-10 01:10:15 +00:00
Joshua Mccloskey
4c43b094d9 Merge "Adding back screenshot test to Settings." into main 2023-11-09 23:27:56 +00:00
Hao Dong
9cade2cbc0 Merge "Add fingerprint name to delete button content description." into main 2023-11-09 19:45:10 +00:00
Roy Luo
983268a242 Merge "Update incompatible charger checking rule" into main 2023-11-09 19:09:38 +00:00
Hao Dong
f2d2de494d Add fingerprint name to delete button content description.
Test: atest FingerprintPreferenceTest
Bug: 308671557

Change-Id: I5a7d402835124a50fd1268745eca1e28c865dc18
2023-11-09 17:14:42 +00:00
Chaohui Wang
d8b21d7846 Avoid unnecessary Html.fromHtml()
Check if string contains html tag, before call Html.fromHtml()

Fix: 308681068
Test: atest SubscriptionsPreferenceControllerTest
Test: atest ProviderModelSliceHelperTest NetworkProviderWorkerTest
Test: manual - on Internet page
Change-Id: Id914689f2861a8c997d18afd03ecfdf47b91c631
2023-11-09 11:10:43 +00:00
Chaohui Wang
62e64c592e Merge "Let SpaBridgeActivity support ActivityEmbedding" into main 2023-11-09 09:39:36 +00:00
Manish Singh
cb33938d90 Merge "Deep copy the existing Arguments" into main 2023-11-09 09:20:03 +00:00
Manish Singh
6ce9c37701 Deep copy the existing Arguments
Otherwise we end up using the same bundle for all the fragments.

Bug: 304697867
Test: manual
Test: atest ProfileSelectFragmentTest
Change-Id: Ia31f2440516783c22849593922467756c8c54cb9
2023-11-08 20:53:58 +00:00
Ajinkya Chalke
e9c09d9c83 Merge "Conditionally add tail button pref" into main 2023-11-08 11:09:28 +00:00
Chaohui Wang
0e1edc6c74 Merge "Fix ContentProtectionTogglePreferenceController" into main 2023-11-08 09:05:22 +00:00
Chaohui Wang
32d9280e97 Merge "Revert^2 "Migrate to CompoundButton.OnCheckedChangeListener"" into main 2023-11-08 09:05:22 +00:00
Yiyi Shen
0a5bbd34b9 Merge "[Audiosharing] Add audio sharing section to Connected devices page." into main 2023-11-08 07:33:09 +00:00
Yiyi Shen
2f2afa22fd [Audiosharing] Add audio sharing section to Connected devices page.
The section will show up during a sharing session.

Flagged with enable_le_audio_sharing

Bug: 305620450
Test: Manual
Change-Id: I59cf81b35dcbf328b253d72d7fdc86af450251ee
2023-11-08 13:41:05 +08:00
Chaohui Wang
478ab50c01 Prevent Erase SIM during call
By collecting call state and only enable preference when idle.

Fix: 298893271
Test: manual - on Mobile Settings during call
Test: unit tests
Change-Id: Ifd567a6b68a3efbb0b42bfa0233f7c54eca07ae1
2023-11-08 03:08:56 +00:00
Ajinkya Chalke
15c617625a Conditionally add tail button pref
- The connected device settings shouldn't show the tail button pref
  setting if the input device doesn't support it.

Bug: 293472525
Test: atest StylusDevicesControllerTest
Flag: NONE
Change-Id: I50ab43e971b0dd8530a5bdab8544a46e889366ee
2023-11-07 17:39:29 +00:00
Chaohui Wang
bf70edddd0 Fix ContentProtectionTogglePreferenceController
The OnMainSwitchChangeListener is replaced with OnCheckedChangeListener

Bug: 306658427
Test: m Settings
Change-Id: I24021cb9acb308c3f85e51e9f79ad2bf564c789a
2023-11-07 14:18:13 +00:00
Chaohui Wang
08a1c9876e Revert^2 "Migrate to CompoundButton.OnCheckedChangeListener"
8979681a8d

Change-Id: I60edd3aabf49afbe4aa016af780baa68d928bddf
2023-11-07 14:17:15 +00:00
Sebastian Pickl
8979681a8d Revert "Migrate to CompoundButton.OnCheckedChangeListener"
Revert submission 25147565-onSwitchChanged-CompoundButton

Reason for revert: breaking builds 

Bug:309601476

Reverted changes: /q/submissionid:25147565-onSwitchChanged-CompoundButton

Change-Id: Ie746db87d9c642599593aa3d5e5baf6b7ba89c0e
2023-11-07 13:26:36 +00:00
Chaohui Wang
71d1f021af Migrate to CompoundButton.OnCheckedChangeListener
Switch and SwitchCompat are both CompoundButton.

Using CompoundButton in Java will helps migration in the future.

Bug: 306658427
Test: manual - check Settings pages
Change-Id: If2e08a9a9557ec66a3b31ef18cd2e15943098a59
2023-11-07 20:22:27 +08:00