android: Try to load existing user cert when importing VPN profile
This commit is contained in:
+9
-1
@@ -387,7 +387,15 @@ public class VpnProfileImportActivity extends AppCompatActivity
|
|||||||
mRemoteCertificate.setVisibility(mProfile.Certificate != null ? View.VISIBLE : View.GONE);
|
mRemoteCertificate.setVisibility(mProfile.Certificate != null ? View.VISIBLE : View.GONE);
|
||||||
mImportUserCert.setVisibility(mProfile.PKCS12 != null ? View.VISIBLE : View.GONE);
|
mImportUserCert.setVisibility(mProfile.PKCS12 != null ? View.VISIBLE : View.GONE);
|
||||||
|
|
||||||
updateUserCertView();
|
if (mProfile.getVpnType().has(VpnTypeFeature.CERTIFICATE))
|
||||||
|
{ /* try to load an existing certificate with the default name */
|
||||||
|
if (mUserCertLoading == null)
|
||||||
|
{
|
||||||
|
mUserCertLoading = getString(R.string.profile_cert_alias, mProfile.getName());
|
||||||
|
getLoaderManager().initLoader(USER_CERT_LOADER, null, mUserCertificateLoaderCallbacks);
|
||||||
|
}
|
||||||
|
updateUserCertView();
|
||||||
|
}
|
||||||
|
|
||||||
if (mProfile.Certificate != null)
|
if (mProfile.Certificate != null)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user