I've noticed in the Android Market Application
, when you click over the search button, it shows the keyboard, but when you click the back
button, the search EditText
becomes invisible and the keyboard
is hidden. The problem is that I can't hide the EditText
after the keyboard is hidden after pressing the back key because I can't find a listener for hiding the keyboard event.
I found this sample How to capture the "virtual keyboard show/hide" event in Android?
but it doesn't work on the soft keyboard.
You need to implement this to capture the BACK button before it is dispatched to the IME: