소스 검색

Avoid crash in the login page when the connections is tested, then changed to other wrong URL and connect is clicked before the new test finishes

David A. Velasco 13 년 전
부모
커밋
ff0803c3ee
2개의 변경된 파일2개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      AndroidManifest.xml
  2. 1 0
      src/eu/alefzero/owncloud/ui/activity/AuthenticatorActivity.java

+ 1 - 1
AndroidManifest.xml

@@ -18,7 +18,7 @@
  -->
 <manifest package="eu.alefzero.owncloud"
     android:versionCode="1"
-    android:versionName="0.1.168B" xmlns:android="http://schemas.android.com/apk/res/android">
+    android:versionName="0.1.169B" xmlns:android="http://schemas.android.com/apk/res/android">
 
     <uses-permission android:name="android.permission.GET_ACCOUNTS" />
     <uses-permission android:name="android.permission.USE_CREDENTIALS" />

+ 1 - 0
src/eu/alefzero/owncloud/ui/activity/AuthenticatorActivity.java

@@ -343,6 +343,7 @@ public class AuthenticatorActivity extends AccountAuthenticatorActivity
                 if (uri.length() != 0) {
                     setResultIconAndText(R.drawable.progress_small,
                             R.string.auth_testing_connection);
+                    findViewById(R.id.buttonOK).setEnabled(false);  // avoid connect can be clicked if the test was previously passed
                     mConnChkRunnable = new ConnectionCheckerRunnable(uri, this);
                     mConnChkRunnable.setListener(this, mHandler);
                     mAuthThread = new Thread(mConnChkRunnable);