Fix 2881
This commit is contained in:
parent
e61e5eb35d
commit
4082bdf11e
2 changed files with 18 additions and 20 deletions
|
@ -2472,5 +2472,5 @@ Falls Sie OsmAnd mögen und das Projekt OpenStreetMap unterstützen wollen, so i
|
|||
<string name="dist_away_from_my_location">Suche %1$s entfernt</string>
|
||||
<string name="advanced_coords_search">Koordinatensuche (erweitert)</string>
|
||||
<string name="coords_search">Koordinatensuche</string>
|
||||
<string name="route_stops_before">%1$ s Haltestellen vor</string>
|
||||
<string name="route_stops_before">%1$s Haltestellen vor</string>
|
||||
</resources>
|
||||
|
|
|
@ -590,27 +590,25 @@ public class ConfigureMapMenu {
|
|||
final ItemClickListener clickListener = new ContextMenuAdapter.ItemClickListener() {
|
||||
@Override
|
||||
public boolean onContextMenuClick(ArrayAdapter<ContextMenuItem> a, int itemId, int pos,
|
||||
boolean isChecked) {
|
||||
if (!isChecked) {
|
||||
for (int i = 0; i < prefs.size(); i++) {
|
||||
prefs.get(i).set(false);
|
||||
}
|
||||
a.notifyDataSetInvalidated();
|
||||
refreshMapComplete(activity);
|
||||
activity.getMapLayers().updateLayers(activity.getMapView());
|
||||
} else {
|
||||
showPreferencesDialog(adapter, a, pos, activity, activity.getString(strId), ps, prefs,
|
||||
useDescription);
|
||||
}
|
||||
return false;
|
||||
boolean isChecked) {
|
||||
if (!isChecked && !useDescription) {
|
||||
for (int i = 0; i < prefs.size(); i++) {
|
||||
prefs.get(i).set(false);
|
||||
}
|
||||
|
||||
a.notifyDataSetInvalidated();
|
||||
refreshMapComplete(activity);
|
||||
activity.getMapLayers().updateLayers(activity.getMapView());
|
||||
} else {
|
||||
showPreferencesDialog(adapter, a, pos, activity, activity.getString(strId), ps, prefs,
|
||||
useDescription);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
};
|
||||
ContextMenuItem.ItemBuilder builder = new ContextMenuItem.ItemBuilder()
|
||||
.setTitleId(strId, activity)
|
||||
.setIcon(icon)
|
||||
.setListener(clickListener);
|
||||
if(useDescription) {
|
||||
ContextMenuItem.ItemBuilder builder = new ContextMenuItem.ItemBuilder().setTitleId(strId, activity)
|
||||
.setIcon(icon).setListener(clickListener);
|
||||
if (useDescription) {
|
||||
final String descr = getDescription(prefs);
|
||||
builder.setDescription(descr);
|
||||
builder.setLayout(R.layout.list_item_single_line_descrition_narrow);
|
||||
|
|
Loading…
Reference in a new issue