What is the best way to manage to handle the typing-timeout?
I tried the code like this (inspired by the code here):
public void onTextChanged(CharSequence arg0, int arg1, int arg2, int arg3) {
//...
Message msg = Message.obtain(messageHandler, MESSAGE_TEXT_CHANGED, arg0.toString());
messageHandler.sendMessageDelayed(msg, 1000 );
//...
}
but in the logs I can see that the geocoder gets invoked upon each key-press, no matter how fast I type. I'd like to have the same behaviour like Javascript's setTimeout(...) function has.
Any help appreciated