reset for now

This commit is contained in:
sonora 2015-01-17 15:04:26 +01:00
parent 108f2befb3
commit d97f756e95
6 changed files with 13 additions and 10 deletions

View file

@ -2038,7 +2038,7 @@ Afghanistan, Albania, Algeria, Andorra, Angola, Anguilla, Antigua and Barbuda, A
<string name="poi_dialog_comment_default">POI changing</string> <string name="poi_dialog_comment_default">POI changing</string>
<string name="poi_dialog_other_tags_message">All other tags are preserved</string> <string name="poi_dialog_other_tags_message">All other tags are preserved</string>
<string name="default_buttons_commit">Commit</string> <string name="default_buttons_commit">Commit</string>
<string name="default_buttons_reset">Reset</string> <string name="default_buttons_reset">Clear</string>
<string name="filter_current_poiButton">Filter</string> <string name="filter_current_poiButton">Filter</string>
<string name="edit_filter_delete_menu_item">Delete</string> <string name="edit_filter_delete_menu_item">Delete</string>
<string name="edit_filter_save_as_menu_item">Save As</string> <string name="edit_filter_save_as_menu_item">Save As</string>

View file

@ -38,6 +38,7 @@ public class SearchBuildingByNameActivity extends SearchByNameAbstractActivity<B
@Override @Override
protected void reset() { protected void reset() {
//This is really only a "clear input text field", hence do not reset settings here
//osmandSettings.setLastSearchedBuilding("", null); //osmandSettings.setLastSearchedBuilding("", null);
super.reset(); super.reset();
} }

View file

@ -4,7 +4,7 @@ import java.util.Collection;
import java.util.Comparator; import java.util.Comparator;
import java.util.List; import java.util.List;
import net.osmand.IProgress; //import net.osmand.IProgress;
import net.osmand.CollatorStringMatcher; import net.osmand.CollatorStringMatcher;
import net.osmand.CollatorStringMatcher.StringMatcherMode; import net.osmand.CollatorStringMatcher.StringMatcherMode;
import net.osmand.OsmAndCollator; import net.osmand.OsmAndCollator;
@ -35,19 +35,18 @@ public class SearchCityByNameActivity extends SearchByNameAbstractActivity<City>
@Override @Override
protected void reset() { protected void reset() {
//This is really only a "clear input text field", hence do not reset settings here
//searchVillagesMode = -1; //searchVillagesMode = -1;
//osmandSettings.setLastSearchedCity(-1L, "", null); //osmandSettings.setLastSearchedCity(-1L, "", null);
//Issue 2535: Try to reload indexes as workaround //Issue 2535: Try to reload indexes as workaround
// This creates the issue immediately after tapping "Reset", but then going back to the searchAdressFragment screen resets the issue and everything works(!?) // This creates the issue immediately after tapping "Reset", but then going back to the searchAdressFragment screen resets the issue and everything works(!?)
new AsyncTask<Void, Void, List<String>>() { //new AsyncTask<Void, Void, List<String>>() {
@Override // @Override
protected List<String> doInBackground(Void... params) { // protected List<String> doInBackground(Void... params) {
return getMyApplication().getResourceManager().reloadIndexes(IProgress.EMPTY_PROGRESS); // return getMyApplication().getResourceManager().reloadIndexes(IProgress.EMPTY_PROGRESS);
} // }
}.execute(); //}.execute();
createComparator();
getInitializeTask();
super.reset(); super.reset();
} }

View file

@ -32,6 +32,7 @@ public class SearchRegionByNameActivity extends SearchByNameAbstractActivity<Reg
@Override @Override
protected void reset() { protected void reset() {
//This is really only a "clear input text field", hence do not reset settings here
//osmandSettings.setLastSearchedRegion("", null); //osmandSettings.setLastSearchedRegion("", null);
super.reset(); super.reset();
} }

View file

@ -27,6 +27,7 @@ public class SearchStreet2ByNameActivity extends SearchByNameAbstractActivity<St
@Override @Override
protected void reset() { protected void reset() {
//This is really only a "clear input text field", hence do not reset settings here
//osmandSettings.setLastSearchedIntersectedStreet("", null); //osmandSettings.setLastSearchedIntersectedStreet("", null);
super.reset(); super.reset();
} }

View file

@ -53,6 +53,7 @@ public class SearchStreetByNameActivity extends SearchByNameAbstractActivity<Str
@Override @Override
protected void reset() { protected void reset() {
//This is really only a "clear input text field", hence do not reset settings here
//searchWithCity = -1; //searchWithCity = -1;
//osmandSettings.setLastSearchedStreet("", null); //osmandSettings.setLastSearchedStreet("", null);
super.reset(); super.reset();