强制关闭键盘

 

InputMethodManager imm = (InputMethodManager) getActivity().getSystemService(getActivity().INPUT_METHOD_SERVICE);

if (imm.isActive()) {

imm.toggleSoftInput(InputMethodManager.SHOW_IMPLICIT,InputMethodManager.HIDE_NOT_ALWAYS);

}

posted @ 2014-12-05 13:45  仰望 星空  阅读(222)  评论(0编辑  收藏  举报