[Quick search] limit stable search to POI_TYPE

This commit is contained in:
Alexey Kulish 2016-08-08 11:51:22 +03:00
parent 4e4e2fcb07
commit 30ea0c5e6c

View file

@ -935,7 +935,8 @@ public class QuickSearchDialogFragment extends DialogFragment implements OsmAndC
private boolean needAppend(SearchPhrase phrase) {
return getResultCollection() != null && (getResultCollection().getPhrase() == phrase
|| (getResultCollection().getPhrase().isLastWord(ObjectType.POI_TYPE) && phrase.isLastWord(ObjectType.POI_TYPE)
&& getResultCollection().getPhrase().getLastSelectedWord().getWord().equals(phrase.getLastSelectedWord().getWord())));
&& getResultCollection().getPhrase().getLastSelectedWord().getWord().equals(phrase.getLastSelectedWord().getWord())
&& !getResultCollection().getPhrase().isUnknownSearchWordPresent() && !phrase.isUnknownSearchWordPresent()));
}
public void completeQueryWithObject(SearchResult sr) {