Commit Graph

117291 Commits

Author SHA1 Message Date
Weng Su
f9b5e046a8 Add config for Wi-Fi Hotspot Settings hidden
- Add config_show_wifi_hotspot_settings for Settings customization

- Hide Wi-Fi Hotspot preference in Hotspot & tethering Settings

- Don't launch Wi-Fi Hotspot Settings (e.g long press on Hotspot in QS-tile)

Bug: 213426762
Test: manual test
atest -c com.android.settings.wifi.WifiUtilsTest
make RunSettingsRoboTests ROBOTEST_FILTER=WifiTetherPreferenceControllerTest
make RunSettingsRoboTests ROBOTEST_FILTER=WifiTetherSettingsTest

Merged-In: I11f88d0d15d6d5c2766b64b5847ac31ed0f34c25
Change-Id: I11f88d0d15d6d5c2766b64b5847ac31ed0f34c25
(cherry picked from commit 160b5078ed)
2022-10-20 09:50:22 +00:00
Bonian Chen
5bcfa284a9 [Settings] configuration for hidding SIM settings UI
Hide SIM settings UI based on configuraion.

Bug: 240515161
Test: test cases and local testing
Change-Id: If1df99a79e51125d03f534cdfc9408b01c61024f
2022-10-20 09:46:44 +00:00
Chaohui Wang
6d39e5c911 Add AppOpenByDefaultPreference for Spa
The "Open by Default" in App Info page.

Bug: 236346018
Test: Manual with App Info page
Test: Settings Unit tests
Change-Id: I20f827241ff46bca28440b56fd32a0712ee439f9
2022-10-20 17:28:46 +08:00
Xuanang Zhao
72503d29bd Clean up an unused slice and classify the custom slice usage.
Test: maunal
Bug: 249101421
Change-Id: I362995c114f65f0105b5e2b8036ecb886bd6663a
2022-10-20 07:24:29 +00:00
TreeHugger Robot
c757a12a4e Merge "Add config for Wi-Fi Hotspot Settings hidden" 2022-10-20 06:08:55 +00:00
shaoweishen
66098febbc [Sound Panel] Fix bugs for sound panel slice
1. notify item change when slice live data has update
2. keep showing Output Switcher slice when media state is in "Pause"
   state

Bug: 247043239
Bug: 238715094
Bug: 204165377
Test: verified on device
Change-Id: Ic56a70f2f2835231519e2fccf0d2e649d41b106e
2022-10-20 02:46:41 +00:00
Gil Cukierman
a2ddff3865 Honor DISALLOW_CELLULAR_2G User Restriction in Enable2gPreferenceController
When 2g is disallowed by a device admin the 2g toggle in the preference
screen will implement the following behaviors as a result of being
changed to a RestrictedSwitchPreference:
1. become disabled (greyed out)
2. show a summary message explaining that the preference was disabled by
   an admin
3 show a pop up when a user tries to click on the preference informing
  them that the setting is unusable because it was disabled by an admin.

Additionally, the toggle will show as unchecked (off) when admins
disable 2g.

When 2g is re-enabled by a device admin, the preference screen will go back
to its previous state.

Test: atest Enable2gPreferenceControllerTest
Bug: b/248250240
Change-Id: I7af901f2d9f62ebfe884e01724d8eff845c2968e
2022-10-19 21:01:17 +00:00
Joy Babafemi
eb2532388b Fix UwbPreferenceControllerTest
Bug: 253386238
Test: atest UwbPreferenceControllerTest
Change-Id: I32c07f3bdbf0540ec372b72be945aa07e5d29d62
2022-10-19 19:33:47 +00:00
Milton Wu
5a47cf56ef Retry fingerprint or face unlock
When IllegalStateException happens during user enters `Fingerprint
Unlock` or `Face Unlock` page through `Face and Fingerprint Unlock`
page, show ConfirmLock for user to re-enter credential again.
If user fails to pass credential page, finish activity and back to
`Security` page.
If user success to pass credential page, enter `Fingerprint Unlock` or
`Face Unlock` page.

Test: Manully test timeout case on `Face and Fingerprint Unlock` page
Test: robotest for CombinedBiometricProfileSettingsTest
      FaceSettingsLockscreenBypassPreferenceControllerTest
Bug: 248165760
Change-Id: I3361c38d09d14461db8ecf2d89a34ba9604dc7e8
2022-10-19 23:55:39 +08:00
Jason Huang
2bb35ff3fc network: fix binder object leakage in settings
Summary:
When BT ON and enter into NetworkDashboardFragment, and turning BT OFF and exiting the fragment, the `BluetoothAdapter.closeProfileProxy(BluetoothProfile.PAN)` will not be called.
This causes binder leakage on next time the NetworkDashboardFragment is entered, until killing Settings process.

Reproduce Steps:
1. Turn BT ON
2. Open Settings process
3. Enter "Network & internet" (NetworkDashboardFragment)
4. Turn BT OFF
5. Back to previous page (do not kill Settings process)
* Repeat Step 3-5

Solution:
Do not set value of `mBluetoothPan` to null when `onServiceDisconnected` raised, to ensure the binder object (profile proxy) be closed in lifecycle `onDestroy()`.

Bug: 243128377
Test: enter "Network & internet" page, turn off BT and leave the page
Change-Id: Ieca3e5401c23d1b0ffece1bbb0db96988044262d
2022-10-19 22:07:55 +08:00
Weng Su
160b5078ed Add config for Wi-Fi Hotspot Settings hidden
- Add config_show_wifi_hotspot_settings for Settings customization

- Hide Wi-Fi Hotspot preference in Hotspot & tethering Settings

- Don't launch Wi-Fi Hotspot Settings (e.g long press on Hotspot in QS-tile)

Bug: 213426762
Test: manual test
atest -c com.android.settings.wifi.WifiUtilsTest
make RunSettingsRoboTests ROBOTEST_FILTER=WifiTetherPreferenceControllerTest
make RunSettingsRoboTests ROBOTEST_FILTER=WifiTetherSettingsTest

Change-Id: I11f88d0d15d6d5c2766b64b5847ac31ed0f34c25
2022-10-19 20:13:21 +08:00
Chaohui Wang
402744eb36 Add AppButtonRepositoryTest
Bug: 236346018
Test: Unit test
Change-Id: I174bad92ef5357ba0ea0e32cb0435d700a11dc51
2022-10-19 19:55:01 +08:00
Chaohui Wang
cb7fa280f3 Merge "Make the default getTimeSpentInApp() return empty" 2022-10-19 11:50:48 +00:00
Tetiana Meronyk
5c0bb75de8 Show other users in storage settings
Bug: 232969364
Test: croot && make RunSettingsRoboTests -j40 ROBOTEST_FILTER="com.android.settings.deviceinfo.storage.NonCurrentUserControllerTest"
Change-Id: I8d933bec8f12faa971684939b722cfae957f4953
2022-10-19 10:44:06 +00:00
Simon Wingrove
c359630286 Merge "Don't trampoline twice when opening security or privacy" into tm-qpr-dev am: 062b18c736 am: cf14410f5c
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/20209765

Change-Id: I457654172b46fff1b1059a8058894caad3021e80
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-19 09:50:59 +00:00
Bonian Chen
99698c344c Merge "[Settings] align the long press behavior on secondary sim" am: 90dcc7c5c1 am: 5f5bcf56ca am: 6b6287111f
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/2261204

Change-Id: I65b87ec068d0b5ce0948937604f71ccb4ba6e6ac
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-19 09:50:23 +00:00
Simon Wingrove
cf14410f5c Merge "Don't trampoline twice when opening security or privacy" into tm-qpr-dev am: 062b18c736
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/20209765

Change-Id: Ie86adb15224dc9052d6b017959b78114bbcb6a04
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-19 09:17:47 +00:00
Bonian Chen
6b6287111f Merge "[Settings] align the long press behavior on secondary sim" am: 90dcc7c5c1 am: 5f5bcf56ca
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/2261204

Change-Id: I9bcb0366eee69b9345b6dbd6209d627fe67c31f1
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-19 09:16:42 +00:00
Bonian Chen
5f5bcf56ca Merge "[Settings] align the long press behavior on secondary sim" am: 90dcc7c5c1
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/2261204

Change-Id: Icece91f8119388bbf7bca7129b9f077bc0c857a6
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-19 08:32:33 +00:00
Simon Wingrove
062b18c736 Merge "Don't trampoline twice when opening security or privacy" into tm-qpr-dev 2022-10-19 08:32:10 +00:00
Bonian Chen
90dcc7c5c1 Merge "[Settings] align the long press behavior on secondary sim" 2022-10-19 08:01:34 +00:00
Chaohui Wang
b752c3d058 Make the default getTimeSpentInApp() return empty
Current ApplicationFeatureProvider.getTimeSpentInApp() defaults returns
null, in extreme case there is ACTION_APP_USAGE_SETTINGS handler on
device but getTimeSpentInApp() still returns null, may lead
AppTimeSpentPreference to crash.

Make it returns empty string instead to eliminate this extreme case.

Bug: 236346018
Test: Unit test & Manual with SpaActivity
Change-Id: I33b413ceb9bdf48e3902e02c91fab617fe297862
2022-10-19 15:57:50 +08:00
Jason Chiu
8f01270b1c Merge "Shorten the search box hint for two-pane layout" 2022-10-19 07:54:08 +00:00
SongFerng Wang
4e151185a7 Merge "[LE unicast] Using the pairDeviceByCsip API" into tm-qpr-dev am: 3767112332 am: 29caa8e0f4
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/20176388

Change-Id: Ib1dcb8c150cb8123c5dc2475839d49f97e792c1e
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-19 07:07:16 +00:00
SongFerng Wang
29caa8e0f4 Merge "[LE unicast] Using the pairDeviceByCsip API" into tm-qpr-dev am: 3767112332
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/20176388

Change-Id: I9e77d96cd60eff8f7feb5f257bd05979f49e345a
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-19 07:04:20 +00:00
Jason Chiu
3aec52141d Shorten the search box hint for two-pane layout
Change from "Search settings" to "Search".

Fix: 248006011
Test: visual
Change-Id: I76a1fa0f8c38e5438f2b01a1b6d83cae3968502c
2022-10-19 13:34:48 +08:00
SongFerng Wang
3767112332 Merge "[LE unicast] Using the pairDeviceByCsip API" into tm-qpr-dev 2022-10-19 05:12:22 +00:00
Zoey Chen
ced43b33f2 Merge "[Settings] Change the way in NetworkProviderCallsSmsController for getting the subscription info from room db part2" 2022-10-19 04:29:21 +00:00
Kuan Wang
b036cfabd6 Merge "Copy DatabaseUtils from SettingsGoogle to Settings and use the new Settings database." 2022-10-19 02:20:16 +00:00
Kuan Wang
547df61667 Copy DatabaseUtils from SettingsGoogle to Settings and use the new
Settings database.

Bug: 253395332
Test: make RunSettingsRoboTests
Change-Id: Idbe6d71b69b28d344db146d139b4b60e2e7434da
2022-10-19 02:20:00 +00:00
Kuan Wang
fb136dd8d5 Copy BatteryUsageLoaderService and BatteryBroadcastReceiver from
SettingsGoogle to Settings and rename them to BatteryUsageDataLoader and
BatteryUsageBroadcastReceiver.

Bug: 253395332
Test: make RunSettingsRoboTests
Change-Id: Ide7c572a7df826ca576223c297b8ec78c45cc94e
2022-10-19 02:19:57 +00:00
Bonian Chen
7364b9bbe3 [Settings] align the long press behavior on secondary sim
Within Settings app, long press allows user to copy status/summary part
when it comes to first SIM.

This is a commit to enable the same feature on the second sim.

Test: local
Change-Id: I58d9cf9cbba213196536781d41b9ec81c0142960
2022-10-19 01:47:11 +00:00
Treehugger Robot
772c437de4 Merge "Fix crash when input illegal proxy port number" am: e8160af796 am: 6372ae5e93 am: ab0dc7b129
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/2255620

Change-Id: Ia9db49f176a65bb2d512cd7e0694284f03414a82
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-18 21:43:26 +00:00
Treehugger Robot
ab0dc7b129 Merge "Fix crash when input illegal proxy port number" am: e8160af796 am: 6372ae5e93
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/2255620

Change-Id: Ida3089a2375e04b653058b380c2fd9f1f56a9fcd
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-18 21:10:26 +00:00
Treehugger Robot
6372ae5e93 Merge "Fix crash when input illegal proxy port number" am: e8160af796
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/2255620

Change-Id: Idc35fa976db5cfde013ec9c32191869e84c7801f
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-18 20:42:36 +00:00
Treehugger Robot
e8160af796 Merge "Fix crash when input illegal proxy port number" 2022-10-18 20:17:08 +00:00
Julia Reynolds
b495103ca7 Merge "Add link to more app settings" 2022-10-18 19:32:27 +00:00
Lucas Silva
947bf37e31 Merge "Update dream summary when dream suppressed by bedtime mode" into tm-qpr-dev am: 6a8e193fad am: 5067d29ba4
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/20216381

Change-Id: Id7b947a04e655fe5d6e8b98c2fb8857be4cfb256
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-18 18:15:24 +00:00
Lucas Silva
5067d29ba4 Merge "Update dream summary when dream suppressed by bedtime mode" into tm-qpr-dev am: 6a8e193fad
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/20216381

Change-Id: I72ec38de9b99e704d909ddf9e21e7ac825b00abf
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-18 17:43:35 +00:00
Lucas Silva
6a8e193fad Merge "Update dream summary when dream suppressed by bedtime mode" into tm-qpr-dev 2022-10-18 17:17:25 +00:00
Lucas Silva
51f838ba4b Update dream summary when dream suppressed by bedtime mode
Bug: 246472225
Test: enabled bedtime mode, verified settings summary updated
Test: make -j64 RunSettingsRoboTests ROBOTEST_FILTER="com.android.settings.dream.WhenToDreamPreferenceControllerTest"
Change-Id: I4de12f636975b1bdf36898f7a530fde2f55644d4
2022-10-18 13:23:49 +00:00
TreeHugger Robot
4c96ab379b Merge "Add indexable setting items" 2022-10-18 10:10:08 +00:00
Han Xu
9cf026692b Add BROWSABLE for most Settings Activities
so they can be opened via webpage link.

Bug: 254213622
Test: manual
Change-Id: Ic52895ce0577246a2bbf9536fce1e10ab41f7605
Merged-In: Ic52895ce0577246a2bbf9536fce1e10ab41f7605
(cherry picked from commit b7d1077ada)
2022-10-18 09:31:08 +00:00
Xuanang Zhao
9da4302a78 Merge "Clean up ignored tests in Settings Slices provider." 2022-10-18 09:12:31 +00:00
Tsung-Mao Fang
bd2ee1e20a Add indexable setting items
When work profile is supported on the device,
we should support work profile releated setting items.

Fix: 238055360
Test: Manual
Change-Id: I5b952f958d0c5fc0f7b22838e1f7cfc36239a22e
2022-10-18 16:03:43 +08:00
SongFerng Wang
0693ac7282 Merge "[MEP] the user can't enable the psim when revmovable esim is enabled" into tm-qpr-dev am: 2cd07f51ef am: bd476febf0
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/20116277

Change-Id: I932293c24499b93666686f47907244f8a472243c
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-18 07:20:43 +00:00
Xuanang Zhao
50f229903e Clean up ignored tests in Settings Slices provider.
Change-Id: Iad9102a5d23333d64976e0697f9438bccc77af0a
Bug: 253386051
2022-10-18 07:07:00 +00:00
SongFerng Wang
bd476febf0 Merge "[MEP] the user can't enable the psim when revmovable esim is enabled" into tm-qpr-dev am: 2cd07f51ef
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/20116277

Change-Id: Ib62e9adf0e2bdac25821c9f70634c27b26515056
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-10-18 06:50:09 +00:00
SongFerng Wang
2cd07f51ef Merge "[MEP] the user can't enable the psim when revmovable esim is enabled" into tm-qpr-dev 2022-10-18 06:30:34 +00:00
Zoey Chen
605754eff3 [Settings] Change the way in NetworkProviderCallsSmsController for getting the subscription info from room db part2
Bug: 236919685
Test: atest NetworkProviderCallsSmsControllerTest
Change-Id: Ibbfa1fed15ea4fa38cff38d78855326e3d74fe0e
2022-10-18 06:14:54 +00:00