如何通过android自定义键盘操作按钮执行搜索操作? [英] How to perform a search action by android custom keyboard action button?
本文介绍了如何通过android自定义键盘操作按钮执行搜索操作?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在开发一个android自定义键盘.我需要执行搜索操作,根据用户选择的文本字段将光标移动到下一个文本字段操作.如何执行这些动作?
I'm developing an android custom keyboard. I need to perform search action, move cursor to next text field action according to the text fields that user selected. How to perform those actions?
推荐答案
我得到了答案.
getCurrentInputConnection().performEditorAction(EditorInfo.IME_ACTION_GO);
getCurrentInputConnection().performEditorAction(EditorInfo.IME_ACTION_SEARCH);
getCurrentInputConnection().performEditorAction(EditorInfo.IME_ACTION_NEXT);
这篇关于如何通过android自定义键盘操作按钮执行搜索操作?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文