Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5e4dbe0a authored by Vincent Bourgmayer's avatar Vincent Bourgmayer Committed by Sumit Pundir
Browse files

Clean preload custom url from mail

parent 5a3b9832
Loading
Loading
Loading
Loading
+12 −0
Original line number Diff line number Diff line
@@ -55,6 +55,18 @@ class EeloAuthenticatorFragment : Fragment() {

	v.root.urlpwd_other_account_title_panel.setOnClickListener() { expandCollapse() }

	v.root.urlpwd_user_name.setOnFocusChangeListener() { v, hasFocus ->
            if (!hasFocus ) {
                if (v.urlpwd_user_name.text.toString().contains("@")) {
                    val dns = v.urlpwd_user_name.text.toString().substringAfter("@")
                    val pre_custom_url = "https://" + dns
                    view!!.urlpwd_server_uri.setText(pre_custom_url)
                } else {
                    view!!.urlpwd_server_uri.setText("")
                }
            }
        }

	v.login.setOnClickListener { login() }

	// code below is to draw toggle button in its correct state and show or hide server url input field