Disable native Android virtual keyboard in my [duplicate] app

1

I have an app that only contains a webview (and NOT an EditText). In the web that I use for the webview, I have my own keyboard designed by me, so I do not want the native keyboard of the cell / tablet to appear when I click a textarea or input. Is there any way to undo the virtual keyboard FULLY in my app?

    
asked by Criss 16.07.2016 в 06:58
source

1 answer

1

One method to disable the virtual keyboard that is opened through the WebView is to first add the following properties in the WebView:

android:focusable="false" 
android:focusableInTouchMode="true"

And in the parent layout that will contain the WebView

android:descendantFocusability="blocksDescendants"

This method actually turns off the focus in the WebView to avoid starting the virtual keyboard.

    
answered by 16.07.2016 в 15:03