From fcb556eb2d1e9789acc80112b197436b5fa30b84 Mon Sep 17 00:00:00 2001 From: jabarros Date: Mon, 4 Aug 2014 10:21:48 +0200 Subject: [PATCH] Show appropiate message and update library reference --- owncloud-android-library | 2 +- res/values/strings.xml | 2 ++ .../authentication/AuthenticatorActivity.java | 17 ++++++++--------- 3 files changed, 11 insertions(+), 10 deletions(-) diff --git a/owncloud-android-library b/owncloud-android-library index 6b155fb802..fe6f99ea6a 160000 --- a/owncloud-android-library +++ b/owncloud-android-library @@ -1 +1 @@ -Subproject commit 6b155fb8029973af08751cf42a77b4a4afd0536d +Subproject commit fe6f99ea6a7334f565caa4d6ee5a29d1436b4c4f diff --git a/res/values/strings.xml b/res/values/strings.xml index 6e41e3a164..44f6063bf5 100644 --- a/res/values/strings.xml +++ b/res/values/strings.xml @@ -282,4 +282,6 @@ to upload in this folder The file is no longer available on the server + Secure connection has been redirect to a non secure one. + diff --git a/src/com/owncloud/android/authentication/AuthenticatorActivity.java b/src/com/owncloud/android/authentication/AuthenticatorActivity.java index bc0ab54e62..07c4d79249 100644 --- a/src/com/owncloud/android/authentication/AuthenticatorActivity.java +++ b/src/com/owncloud/android/authentication/AuthenticatorActivity.java @@ -62,23 +62,19 @@ import com.actionbarsherlock.app.SherlockDialogFragment; import com.owncloud.android.MainApp; import com.owncloud.android.R; import com.owncloud.android.authentication.SsoWebViewClient.SsoWebViewClientListener; -import com.owncloud.android.lib.common.OwnCloudAccount; -import com.owncloud.android.lib.common.OwnCloudClientManagerFactory; -import com.owncloud.android.lib.common.OwnCloudCredentialsFactory; import com.owncloud.android.lib.common.accounts.AccountTypeUtils; import com.owncloud.android.lib.common.accounts.AccountUtils.Constants; -import com.owncloud.android.operations.DetectAuthenticationMethodOperation.AuthenticationMethod; -import com.owncloud.android.operations.GetServerInfoOperation; -import com.owncloud.android.operations.OAuth2GetAccessToken; - import com.owncloud.android.lib.common.network.CertificateCombinedException; import com.owncloud.android.lib.common.operations.OnRemoteOperationListener; import com.owncloud.android.lib.common.operations.RemoteOperation; import com.owncloud.android.lib.common.operations.RemoteOperationResult; import com.owncloud.android.lib.common.operations.RemoteOperationResult.ResultCode; import com.owncloud.android.lib.resources.files.ExistenceCheckRemoteOperation; +import com.owncloud.android.lib.resources.status.OwnCloudVersion; import com.owncloud.android.lib.resources.users.GetRemoteUserNameOperation; - +import com.owncloud.android.operations.DetectAuthenticationMethodOperation.AuthenticationMethod; +import com.owncloud.android.operations.GetServerInfoOperation; +import com.owncloud.android.operations.OAuth2GetAccessToken; import com.owncloud.android.services.OperationsService; import com.owncloud.android.services.OperationsService.OperationsServiceBinder; import com.owncloud.android.ui.dialog.IndeterminateProgressDialog; @@ -86,7 +82,6 @@ import com.owncloud.android.ui.dialog.SamlWebViewDialog; import com.owncloud.android.ui.dialog.SslUntrustedCertDialog; import com.owncloud.android.ui.dialog.SslUntrustedCertDialog.OnSslUntrustedCertListener; import com.owncloud.android.utils.Log_OC; -import com.owncloud.android.lib.resources.status.OwnCloudVersion; /** * This Activity is used to add an ownCloud account to the App @@ -1167,6 +1162,10 @@ SsoWebViewClientListener, OnSslUntrustedCertListener { case UNKNOWN_ERROR: mServerStatusText = R.string.auth_unknown_error_title; break; + case OK_REDIRECT_TO_NON_SECURE_CONNECTION: + mServerStatusIcon = android.R.drawable.ic_partial_secure; + mServerStatusText = R.string.auth_redirect_non_secure_connection_title; + break; default: mServerStatusText = 0; mServerStatusIcon = 0;