Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
请帮帮我!如何使用edittexts设置更改gridview焦点的顺序?现在看起来像这样:
(1)(2)(3)
(4)(5)(6)
(7)(8)(9)
当我在键盘上按“下一步”时,焦点移动 1-4-7 完成 2-5-8 完成 3-6-9。我需要 1-2-3-4-5-6-7-8-9... 动态添加的项目。
在代码中获取 your 的实例EditText,然后调用edittext1.setNextFocusDownId(R.id.edittext2);并因此为 all youre 执行此操作EditText。
EditText
edittext1.setNextFocusDownId(R.id.edittext2);