fix two times search

This commit is contained in:
Chumva 2018-04-16 13:14:17 +03:00
parent 8676032a00
commit 865b9eb700

View file

@ -531,11 +531,10 @@ public class QuickSearchDialogFragment extends DialogFragment implements OsmAndC
@Override
public boolean onEditorAction(TextView v, int actionId, KeyEvent event) {
if (actionId == EditorInfo.IME_ACTION_SEARCH) {
searchQuery += " ";
searchEditText.setText(searchQuery);
searchEditText.setSelection(searchQuery.length());
String newQueryText = searchQuery + " ";
searchEditText.setText(newQueryText);
searchEditText.setSelection(newQueryText.length());
AndroidUtils.hideSoftKeyboard(getActivity(), searchEditText);
runSearch();
return true;
}
return false;