Answers for "android action key"

1

android action key

TextView.OnEditorActionListener editListener = 
	(TextView view, int actionId, KeyEvent event) -> {
        if (actionId == EditorInfo.IME_ACTION_NEXT) {
          Toast.makeText(this, "next", Toast.LENGTH_SHORT).show();
        }
        if (actionId == EditorInfo.IME_ACTION_DONE) {
          Toast.makeText(this, "done", Toast.LENGTH_SHORT).show();
        }
        return false;
	};

editView.setOnEditorActionListener(editListener);
Posted by: Guest on February-11-2021

Code answers related to "android action key"

Code answers related to "Java"

Java Answers by Framework

Browse Popular Code Answers by Language