0

Initially what I want is only to add a camera button to the standard keyboard to navigate to a camera activity. After some research this was achieved by using keyboardView. I followed http://www.fampennings.nl/maarten/android/09keyboard/index.htm, and it works very well, except when working with SearchView.

Clicking the search icon when SearchView is iconified will result in popupping both the customized keyboardView and the system keyboard.

I tried to override SearchView.setOnSearchClickListener() and setOnFocusChangeListener(). They didn't work.

My question is how to hide the system keyboard?

savanto
  • 4,470
  • 23
  • 40
aaronhigh
  • 91
  • 3

1 Answers1

0

As mentioned here set onTouchListener with these code:

edittext.setInputType(InputType.TYPE_NULL);      
if (android.os.Build.VERSION.SDK_INT >= 11)   
{  
    edittext.setRawInputType(InputType.TYPE_CLASS_TEXT);  
    edittext.setTextIsSelectable(true);  
}
Community
  • 1
  • 1
Denis Nek
  • 1,874
  • 3
  • 19
  • 21