OnEditorActionListener 에는 onEditorAction(TextView tv, int actionId, KeyEvent ke) 를 만들면 되고
actionId 와 KeyEvent 로 처리가 가능하지 않을까 합니다. (될지 확실히는 모르겠음 ㅋㅋ)
뭐 이런식으로요
editText.setOnEditorActionListener(new OnEditorActionListener() { public boolean onEditorAction(TextView arg0, int actionId, KeyEvent event) { if (actionId == EditorInfo.IME_ACTION_DONE) { // DONE 시 행동
} else if (actionId == EditorInfo.IME_ACTION_NEXT) { // NEXT 시 행동
} else if (actionId == EditorInfo.IME_ACTION_NEXT) { // GO 시 행동
} else if (event != null && event.getKeyCode() == KeyEvent.KEYCODE_ENTER) { // KEYCODE Enter 들어왔을시
} else if (event != null && event.getKeyCode() == KeyEvent.KEYCODE_BACK) { // KeyCODE Back 들어왔을시
EditText 에 setOnEditorActionListener 를 달수 있습니다.
OnEditorActionListener 에는 onEditorAction(TextView tv, int actionId, KeyEvent ke) 를 만들면 되고
actionId 와 KeyEvent 로 처리가 가능하지 않을까 합니다. (될지 확실히는 모르겠음 ㅋㅋ)
뭐 이런식으로요
editText.setOnEditorActionListener(new OnEditorActionListener() {
public boolean onEditorAction(TextView arg0, int actionId, KeyEvent event) {
if (actionId == EditorInfo.IME_ACTION_DONE) {
// DONE 시 행동
} else if (actionId == EditorInfo.IME_ACTION_NEXT) {
// NEXT 시 행동
} else if (actionId == EditorInfo.IME_ACTION_NEXT) {
// GO 시 행동
} else if (event != null && event.getKeyCode() == KeyEvent.KEYCODE_ENTER) {
// KEYCODE Enter 들어왔을시
} else if (event != null && event.getKeyCode() == KeyEvent.KEYCODE_BACK) {
// KeyCODE Back 들어왔을시
}
}
});
흐음... 안되면 어쩌지? ㅋ