Merge "[Settings] Move display of VPN version into summary text" into sc-dev

This commit is contained in:
Bonian Chen
2022-04-07 00:08:28 +00:00
committed by Android (Google) Code Review
4 changed files with 71 additions and 6 deletions

View File

@@ -7419,7 +7419,7 @@
<!-- Button label to disconnect from a VPN profile. [CHAR LIMIT=40] -->
<string name="vpn_disconnect">Disconnect</string>
<!-- Field label to show the version number for a VPN app. [CHAR LIMIT=40] -->
<string name="vpn_version">Version <xliff:g id="version" example="3.3.0">%s</xliff:g></string>
<string name="vpn_version">Version</string>
<!-- Button label to forget a VPN profile [CHAR LIMIT=40] -->
<string name="vpn_forget_long">Forget VPN</string>
<!-- Dialog message title to set another VPN app to be always-on [CHAR LIMIT=40] -->

View File

@@ -237,6 +237,16 @@
<item name="android:textAppearance">@android:style/TextAppearance.DeviceDefault.Small</item>
</style>
<style name="vpn_app_management_version_title">
<item name="android:textAppearance">?android:attr/textAppearanceListItem</item>
<item name="android:textColor">?android:attr/textColorPrimary</item>
</style>
<style name="vpn_app_management_version_summary">
<item name="android:textAppearance">?android:attr/textAppearanceListItemSecondary</item>
<item name="android:textColor">?android:attr/textColorSecondary</item>
</style>
<style name="TextAppearance" parent="android:TextAppearance.DeviceDefault"/>
<style name="TextAppearance.info_label">

View File

@@ -15,14 +15,24 @@
-->
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:settings="http://schemas.android.com/apk/res-auto">
xmlns:settings="http://schemas.android.com/apk/res-auto"
orderingFromXml="false"
>
<!-- To limit the size (in height) of version Preference displayed here,
maximum height of TextView need to be set programmingly.
Therefore, this Preference got removed from here and will be added
dynamically through source code.
<Preference
android:order="0"
android:key="version"
android:textColor="?android:attr/textColorSecondary"
android:selectable="false"/>
-->
<com.android.settingslib.RestrictedSwitchPreference
android:order="10"
android:key="always_on_vpn"
android:title="@string/vpn_menu_lockdown"
android:defaultValue="false"
@@ -32,6 +42,7 @@
settings:restrictedSwitchSummary="@string/disabled_by_admin_summary_text" />
<com.android.settingslib.RestrictedSwitchPreference
android:order="20"
android:key="lockdown_vpn"
android:title="@string/vpn_require_connection"
android:defaultValue="false"
@@ -41,6 +52,7 @@
settings:restrictedSwitchSummary="@string/disabled_by_admin_summary_text" />
<com.android.settingslib.RestrictedPreference
android:order="30"
android:key="forget_vpn"
android:title="@string/vpn_forget_long"
android:icon="@drawable/ic_delete"