InputMethodManager inputMethodManager =(InputMethodManager)activity.getApplicationContext().
getSystemService(Context.INPUT_METHOD_SERVICE);
EditText editText = (EditText)findViewById(R.id.xxxx);
inputMethodManager.hideSoftInputFromWindow(editText.getWindowToken(), 0); //隐藏
隐藏软键盘
本文介绍了一种在Android应用中隐藏软键盘的方法。通过获取InputMethodManager实例并调用hideSoftInputFromWindow方法,可以实现对软键盘的有效控制。
361

被折叠的 条评论
为什么被折叠?



