1
0
Fork 0
mirror of https://github.com/M66B/FairEmail.git synced 2024-12-30 19:56:10 +00:00

Add encrypt input/done

This commit is contained in:
M66B 2022-10-22 20:51:35 +02:00
parent 38902a5cd9
commit 95b3d39c4c
2 changed files with 14 additions and 1 deletions

View file

@ -4,7 +4,7 @@ apply plugin: 'kotlin-android'
apply plugin: 'de.undercouch.download'
def getVersionCode = { -> return 1989 }
def getRevision = { -> return "a" }
def getRevision = { -> return "b" }
def getReleaseName = { -> return "Mei long" }
// https://en.wikipedia.org/wiki/List_of_dinosaur_genera

View file

@ -55,11 +55,13 @@ import android.text.style.URLSpan;
import android.text.style.UnderlineSpan;
import android.util.Base64;
import android.util.Pair;
import android.view.KeyEvent;
import android.view.LayoutInflater;
import android.view.MenuItem;
import android.view.SubMenu;
import android.view.View;
import android.view.WindowManager;
import android.view.inputmethod.EditorInfo;
import android.widget.Button;
import android.widget.EditText;
import android.widget.TextView;
@ -678,6 +680,17 @@ public class StyleHelper {
tilPassword2.getEditText().addTextChangedListener(w);
w.afterTextChanged(null);
tilPassword2.getEditText().setOnEditorActionListener(new TextView.OnEditorActionListener() {
@Override
public boolean onEditorAction(TextView v, int actionId, KeyEvent event) {
if (actionId == EditorInfo.IME_ACTION_DONE) {
btnOk.performClick();
return true;
} else
return false;
}
});
return true;
}