Changeset 35673 in osm for applications/editors/josm/plugins
- Timestamp:
- 2020-12-22T14:09:03+01:00 (4 years ago)
- Location:
- applications/editors/josm/plugins/utilsplugin2/src/org/openstreetmap/josm/plugins/utilsplugin2/selection
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/utilsplugin2/src/org/openstreetmap/josm/plugins/utilsplugin2/selection/AdjacentNodesAction.java
r35579 r35673 97 97 @Override 98 98 protected void updateEnabledState(Collection<? extends OsmPrimitive> selection) { 99 if (selection == null) {100 setEnabled(false);101 return;99 boolean hasSel = selection != null && !selection.isEmpty(); 100 if (!hasSel) { 101 activeWays.clear(); 102 102 } 103 setEnabled( !selection.isEmpty());103 setEnabled(hasSel); 104 104 } 105 105 } -
applications/editors/josm/plugins/utilsplugin2/src/org/openstreetmap/josm/plugins/utilsplugin2/selection/SelectBoundaryAction.java
r35579 r35673 102 102 @Override 103 103 protected void updateEnabledState(Collection<? extends OsmPrimitive> selection) { 104 setEnabled(selection != null && !selection.isEmpty()); 104 boolean hasSel = selection != null && !selection.isEmpty(); 105 if (!hasSel) { 106 lastUsedStartingWay = null; 107 } 108 setEnabled(hasSel); 105 109 } 106 110 } -
applications/editors/josm/plugins/utilsplugin2/src/org/openstreetmap/josm/plugins/utilsplugin2/selection/SelectModNodesAction.java
r35579 r35673 81 81 @Override 82 82 protected void updateEnabledState() { 83 setEnabled(getLayerManager().getEditDataSet() != null); 83 boolean hasEditLayer = getLayerManager().getEditDataSet() != null; 84 if (!hasEditLayer) { 85 lastCmd = null; 86 } 87 setEnabled(hasEditLayer); 84 88 } 85 89 } -
applications/editors/josm/plugins/utilsplugin2/src/org/openstreetmap/josm/plugins/utilsplugin2/selection/SelectModWaysAction.java
r35579 r35673 81 81 @Override 82 82 protected void updateEnabledState() { 83 setEnabled(getLayerManager().getEditDataSet() != null); 83 boolean hasEditLayer = getLayerManager().getEditDataSet() != null; 84 if (!hasEditLayer) { 85 lastCmd = null; 86 } 87 setEnabled(hasEditLayer); 84 88 } 85 89 }
Note:
See TracChangeset
for help on using the changeset viewer.