📜  clsoe 键盘 android studio - Java 代码示例

📅  最后修改于: 2022-03-11 14:52:05.763000             🧑  作者: Mango

代码示例1
View view = this.getCurrentFocus();
if (view != null) {  
    InputMethodManager imm = (InputMethodManager)getSystemService(Context.INPUT_METHOD_SERVICE);
    imm.hideSoftInputFromWindow(view.getWindowToken(), 0);
}