Add toggle for Wi-Fi hotspot

- Add Wi-Fi hotspot toggle with vertical divider

- Disable preference and toggle when Data Saver is enabled

Bug: 245569117
Test: manual test
make RunSettingsRoboTests ROBOTEST_FILTER=TetherSettingsTest
make RunSettingsRoboTests ROBOTEST_FILTER=WifiTetherPreferenceControllerTest
atest -c TetheringManagerModelTest

Change-Id: Ic2baf7d3d0a7bf9527da38d24ecc511b7c91265a
This commit is contained in:
Weng Su
2023-01-13 07:52:23 +08:00
parent a65999cc60
commit f779e6c9d3
7 changed files with 276 additions and 71 deletions

View File

@@ -23,10 +23,10 @@
android:key="tether_prefs_top_intro"
settings:searchable="false"/>
<com.android.settings.widget.FixedLineSummaryPreference
<com.android.settingslib.PrimarySwitchPreference
android:key="wifi_tether"
android:title="@string/wifi_hotspot_checkbox_text"
android:summary="@string/summary_placeholder"
android:summary="@string/wifi_hotspot_off_subtext"
android:fragment="com.android.settings.wifi.tether.WifiTetherSettings"
settings:allowDividerAbove="true"
settings:maxLines="2"/>