Android: Disable soft keyboard at all EditTexts

前端 未结 13 2342
失恋的感觉
失恋的感觉 2020-11-27 06:23

I am working on a dialog at Android with a few EditTexts. I\'ve put this line at the onCreate() in order to disable the soft keyboard:



        
13条回答
  •  Happy的楠姐
    2020-11-27 06:39

    Its been some time since this post, but here is a simple method which worked for me: in the xml, in the EditText properties, do: android:focusable="false". Now the keyboard will not popup even if the user clicks on it. This is useful if you are providing your own keypad.

提交回复
热议问题