Merge "Create a new string to alert unsupported vpn start." into main am: 3c569b5379 am: 42ad676a4e am: b7ba4be4b3

Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/2831551

Change-Id: Ib74982008d3e123b00cf235f39f1b2d8f182c585
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
Hansen Kurli
2023-11-21 10:02:27 +00:00
committed by Automerger Merge Worker
2 changed files with 7 additions and 2 deletions

View File

@@ -6537,6 +6537,11 @@
<!-- Dialog subtitle warning for a VPN app that has an insecure type. [CHAR LIMIT=100] -->
<string name="vpn_insecure_dialog_subtitle">Not secure. Update to an IKEv2 VPN</string>
<!-- Dialog message when user attempted to start a VPN type that is no longer supported. It is
very unlikely, but not impossible, that a user has a very old VPN configuration that the
newer device no longer supports. This message is displayed when the user tries to start
this unsupported VPN. [CHAR LIMIT=NONE] -->
<string name="vpn_start_unsupported">Failed to start unsupported VPN.</string>
<!-- Summary describing the always-on VPN feature. [CHAR LIMIT=NONE] -->
<string name="vpn_lockdown_summary">Select a VPN profile to always remain connected to. Network traffic will only be allowed when connected to this VPN.</string>

View File

@@ -209,8 +209,8 @@ public class ConfigDialogFragment extends InstrumentedDialogFragment implements
Toast.makeText(mContext, R.string.vpn_no_network, Toast.LENGTH_LONG).show();
} catch (UnsupportedOperationException e) {
Log.e(TAG, "Attempted to start an unsupported VPN type.");
final AlertDialog dialog = new AlertDialog.Builder(mContext)
.setMessage(R.string.vpn_insecure_dialog_subtitle)
final AlertDialog unusedDialog = new AlertDialog.Builder(mContext)
.setMessage(R.string.vpn_start_unsupported)
.setPositiveButton(android.R.string.ok, null)
.show();
}