icon for category with one filter
This commit is contained in:
parent
0300b0b612
commit
821700b59b
1 changed files with 8 additions and 12 deletions
|
@ -338,18 +338,14 @@ public class QuickSearchListItem {
|
||||||
if (categories.size() == 1) {
|
if (categories.size() == 1) {
|
||||||
String res = "";
|
String res = "";
|
||||||
PoiCategory category = categories.get(0);
|
PoiCategory category = categories.get(0);
|
||||||
LinkedHashSet<String> f = acceptedTypes.get(category);
|
LinkedHashSet<String> filters = acceptedTypes.get(category);
|
||||||
List<String> filters;
|
if (filters == null || filters.size() > 1) {
|
||||||
if (f != null) {
|
res = category.getIconKeyName();
|
||||||
filters = new ArrayList<>(f);
|
} else {
|
||||||
if (filters.size() == 1) {
|
res = getPoiTypeIconName(category.getPoiTypeByKeyName(filters.iterator().next()));
|
||||||
res = getPoiTypeIconName(category.getPoiTypeByKeyName(filters.get(0)));
|
}
|
||||||
} else {
|
if (res != null && RenderingIcons.containsBigIcon(res)) {
|
||||||
res = category.getIconKeyName();
|
iconId = RenderingIcons.getBigIconResourceId(res);
|
||||||
}
|
|
||||||
if (res != null && RenderingIcons.containsBigIcon(res)) {
|
|
||||||
iconId = RenderingIcons.getBigIconResourceId(res);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue