Update layer
This commit is contained in:
parent
f5f942e498
commit
2c01b6fe8f
1 changed files with 2 additions and 1 deletions
|
@ -162,7 +162,7 @@ public class OsmEditingPlugin extends OsmandPlugin {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void registerLayerContextMenuActions(OsmandMapTileView mapView, ContextMenuAdapter adapter, MapActivity mapActivity) {
|
public void registerLayerContextMenuActions(OsmandMapTileView mapView, ContextMenuAdapter adapter, final MapActivity mapActivity) {
|
||||||
adapter.item(R.string.layer_osm_bugs).selected(settings.SHOW_OSM_BUGS.get() ? 1 : 0)
|
adapter.item(R.string.layer_osm_bugs).selected(settings.SHOW_OSM_BUGS.get() ? 1 : 0)
|
||||||
.iconColor(R.drawable.ic_action_bug_dark).listen(new OnContextMenuClick() {
|
.iconColor(R.drawable.ic_action_bug_dark).listen(new OnContextMenuClick() {
|
||||||
|
|
||||||
|
@ -170,6 +170,7 @@ public class OsmEditingPlugin extends OsmandPlugin {
|
||||||
public boolean onContextMenuClick(ArrayAdapter<?> adapter, int itemId, int pos, boolean isChecked) {
|
public boolean onContextMenuClick(ArrayAdapter<?> adapter, int itemId, int pos, boolean isChecked) {
|
||||||
if (itemId == R.string.layer_osm_bugs) {
|
if (itemId == R.string.layer_osm_bugs) {
|
||||||
settings.SHOW_OSM_BUGS.set(isChecked);
|
settings.SHOW_OSM_BUGS.set(isChecked);
|
||||||
|
updateLayers(mapActivity.getMapView(), mapActivity);
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue