diff --git a/androidApp/src/main/java/bou/amine/apps/readerforselfossv2/android/LoginActivity.kt b/androidApp/src/main/java/bou/amine/apps/readerforselfossv2/android/LoginActivity.kt
index 9edfc96..cb8c9da 100644
--- a/androidApp/src/main/java/bou/amine/apps/readerforselfossv2/android/LoginActivity.kt
+++ b/androidApp/src/main/java/bou/amine/apps/readerforselfossv2/android/LoginActivity.kt
@@ -28,9 +28,7 @@ import org.kodein.di.instance
class LoginActivity : AppCompatActivity(), DIAware {
private var inValidCount: Int = 0
- private var isWithSelfSignedCert = false
private var isWithLogin = false
- private var isWithHTTPLogin = false
private lateinit var appColors: AppColors
private lateinit var binding: ActivityLoginBinding
@@ -61,13 +59,6 @@ class LoginActivity : AppCompatActivity(), DIAware {
private fun handleActions() {
- binding.withSelfhostedCert.setOnCheckedChangeListener { _, b ->
- isWithSelfSignedCert = !isWithSelfSignedCert
- val visi: Int = if (b) View.VISIBLE else View.GONE
-
- binding.warningText.visibility = visi
- }
-
binding.passwordView.setOnEditorActionListener(
TextView.OnEditorActionListener { _, id, _ ->
if (id == R.id.loginView || id == EditorInfo.IME_NULL) {
@@ -87,14 +78,6 @@ class LoginActivity : AppCompatActivity(), DIAware {
binding.loginView.visibility = visi
binding.passwordView.visibility = visi
}
-
- binding.withHttpLogin.setOnCheckedChangeListener { _, b ->
- isWithHTTPLogin = !isWithHTTPLogin
- val visi: Int = if (b) View.VISIBLE else View.GONE
-
- binding.httpLoginView.visibility = visi
- binding.httpPasswordView.visibility = visi
- }
}
private fun handleBaseUrlFail() {
@@ -122,8 +105,6 @@ class LoginActivity : AppCompatActivity(), DIAware {
binding.urlView.error = getString(R.string.wrong_infos)
binding.loginView.error = getString(R.string.wrong_infos)
binding.passwordView.error = getString(R.string.wrong_infos)
- binding.httpLoginView.error = getString(R.string.wrong_infos)
- binding.httpPasswordView.error = getString(R.string.wrong_infos)
}
private fun attemptLogin() {
@@ -131,16 +112,12 @@ class LoginActivity : AppCompatActivity(), DIAware {
// Reset errors.
binding.urlView.error = null
binding.loginView.error = null
- binding.httpLoginView.error = null
binding.passwordView.error = null
- binding.httpPasswordView.error = null
// Store values at the time of the login attempt.
val url = binding.urlView.text.toString()
val login = binding.loginView.text.toString()
- val httpLogin = binding.httpLoginView.text.toString()
val password = binding.passwordView.text.toString()
- val httpPassword = binding.httpPasswordView.text.toString()
var cancel = false
var focusView: View? = null
@@ -177,26 +154,12 @@ class LoginActivity : AppCompatActivity(), DIAware {
}
}
- if (isWithHTTPLogin) {
- if (TextUtils.isEmpty(httpPassword)) {
- binding.httpPasswordView.error = getString(R.string.error_invalid_password)
- focusView = binding.httpPasswordView
- cancel = true
- }
-
- if (TextUtils.isEmpty(httpLogin)) {
- binding.httpLoginView.error = getString(R.string.error_field_required)
- focusView = binding.httpLoginView
- cancel = true
- }
- }
-
if (cancel) {
focusView?.requestFocus()
} else {
showProgress(true)
- repository.refreshLoginInformation(url, login, password, isWithSelfSignedCert)
+ repository.refreshLoginInformation(url, login, password)
CoroutineScope(Dispatchers.IO).launch {
val result = repository.login()
diff --git a/androidApp/src/main/res/drawable/ic_bug_report_white_24dp.xml b/androidApp/src/main/res/drawable/ic_bug_report_white_24dp.xml
deleted file mode 100644
index 5c8f5bc..0000000
--- a/androidApp/src/main/res/drawable/ic_bug_report_white_24dp.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-
-
-
diff --git a/androidApp/src/main/res/drawable/ic_color_lens_white_24dp.xml b/androidApp/src/main/res/drawable/ic_color_lens_white_24dp.xml
deleted file mode 100644
index 4abeea5..0000000
--- a/androidApp/src/main/res/drawable/ic_color_lens_white_24dp.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-
-
-
diff --git a/androidApp/src/main/res/layout/activity_login.xml b/androidApp/src/main/res/layout/activity_login.xml
index 7887f3d..4c37ea3 100644
--- a/androidApp/src/main/res/layout/activity_login.xml
+++ b/androidApp/src/main/res/layout/activity_login.xml
@@ -82,45 +82,6 @@
android:maxLines="1"
android:visibility="gone" />
-
-
-
-
-
-
-
-
-
-