commit
4b697c14ce
3 changed files with 8 additions and 3 deletions
|
@ -308,7 +308,7 @@ public class MapActivityLayers {
|
||||||
PoiUIFilter filter = list.get(i);
|
PoiUIFilter filter = list.get(i);
|
||||||
if (item.getSelected()) {
|
if (item.getSelected()) {
|
||||||
if (filter.isStandardFilter()) {
|
if (filter.isStandardFilter()) {
|
||||||
filter.setFilterByName(null);
|
filter.removeUnsavedFilterByName();
|
||||||
}
|
}
|
||||||
getApplication().getPoiFilters().addSelectedPoiFilter(filter);
|
getApplication().getPoiFilters().addSelectedPoiFilter(filter);
|
||||||
} else {
|
} else {
|
||||||
|
@ -376,7 +376,7 @@ public class MapActivityLayers {
|
||||||
activity.showQuickSearch(ShowQuickSearchMode.NEW, true);
|
activity.showQuickSearch(ShowQuickSearchMode.NEW, true);
|
||||||
} else {
|
} else {
|
||||||
if (pf.isStandardFilter()) {
|
if (pf.isStandardFilter()) {
|
||||||
pf.setFilterByName(null);
|
pf.removeUnsavedFilterByName();
|
||||||
}
|
}
|
||||||
getApplication().getPoiFilters().clearSelectedPoiFilters();
|
getApplication().getPoiFilters().clearSelectedPoiFilters();
|
||||||
getApplication().getPoiFilters().addSelectedPoiFilter(pf);
|
getApplication().getPoiFilters().addSelectedPoiFilter(pf);
|
||||||
|
|
|
@ -139,6 +139,11 @@ public class PoiUIFilter implements SearchPoiTypeFilter, Comparable<PoiUIFilter>
|
||||||
updateFilterResults();
|
updateFilterResults();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void removeUnsavedFilterByName() {
|
||||||
|
filterByName = savedFilterByName;
|
||||||
|
updateFilterResults();
|
||||||
|
}
|
||||||
|
|
||||||
public void updateFilterResults() {
|
public void updateFilterResults() {
|
||||||
List<Amenity> prev = currentSearchResult;
|
List<Amenity> prev = currentSearchResult;
|
||||||
if (prev != null) {
|
if (prev != null) {
|
||||||
|
|
|
@ -108,7 +108,7 @@ public class ShowHidePoiAction extends QuickAction {
|
||||||
|
|
||||||
for (PoiUIFilter filter : poiFilters) {
|
for (PoiUIFilter filter : poiFilters) {
|
||||||
if (filter.isStandardFilter()) {
|
if (filter.isStandardFilter()) {
|
||||||
filter.setFilterByName(null);
|
filter.removeUnsavedFilterByName();
|
||||||
}
|
}
|
||||||
pf.addSelectedPoiFilter(filter);
|
pf.addSelectedPoiFilter(filter);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue