Skip to content

Instantly share code, notes, and snippets.

@yccheok
Created February 12, 2018 19:06
Show Gist options
  • Select an option

  • Save yccheok/eadfcff14b2eb789528570560224805e to your computer and use it in GitHub Desktop.

Select an option

Save yccheok/eadfcff14b2eb789528570560224805e to your computer and use it in GitHub Desktop.
@Override
public void onTextChanged(CharSequence s, int start, int before, int count) {
// this happens in android as well
if (JStockAutoCompleteTextView.this.isPerformingCompletion()) {
// We need to differentiate, whether "string" is from user
// typing, or drop down list selection. This is because when
// user perform selection, document change event will be triggered
// too. When string is from drop down list selection, user
// are not expecting any auto complete suggestion. Return early.
return;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment