Vpn settings per vpn

This CL adds a setting for each VPN
- When no_config_vpn user restriction is applied, user can't change anything in the page
- Launch the subsetting activity in the corresponding user to unlock keystore and force work challenge
- Show dialog when user replace always-on-VPN package
- When forget VPN, unset always-on-vpn

TODO: show per-VPN status in VPN list

Change-Id: Ica360ea44117db6a4ecfaed1eec6c188189c246c
This commit is contained in:
Victor Chang
2016-03-11 19:44:56 +00:00
parent e580f94079
commit 16da2aa450
8 changed files with 397 additions and 20 deletions

View File

@@ -355,8 +355,7 @@ public class VpnSettings extends RestrictedSettingsFragment implements
} else if (tag instanceof AppPreference) {
AppPreference pref = (AppPreference) tag;
boolean connected = (pref.getState() == AppPreference.STATE_CONNECTED);
AppDialogFragment.show(VpnSettings.this, pref.getPackageInfo(), pref.getLabel(),
true /* editing */, connected);
AppManagementFragment.show(getPrefContext(), pref);
}
}
};