开发者

How to hide virtual keyboard in android

开发者 https://www.devze.com 2023-01-15 00:49 出处:网络
i used t开发者_如何学编程his code InputMethodManager imm = (InputMethodManager)getSystemService(Context.INPUT_METHOD_SERVICE);

i used t开发者_如何学编程his code

InputMethodManager imm = (InputMethodManager)getSystemService(Context.INPUT_METHOD_SERVICE);
 imm.hideSoftInputFromWindow(EditView.getWindowToken(), 0);

this code works fine in a class which extends Activity

but i need to hide virtual keyboard in a class which extends LinearLayout.

0

精彩评论

暂无评论...
验证码 换一张
取 消