让一个view 获得焦点

view.setFocusable(true);
view.setFocusableInTouchMode(true);
view.requestFocus();

原文地址:https://www.cnblogs.com/Ringer/p/4191922.html