- Timestamp:
- 2011-12-20T22:34:49+01:00 (13 years ago)
- Location:
- trunk/src/org/openstreetmap/josm
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/data/validation/TestError.java
r4131 r4672 9 9 import java.util.List; 10 10 import java.util.TreeSet; 11 import java.util.ArrayList; 11 12 12 13 import org.openstreetmap.josm.command.Command; … … 122 123 123 124 /** 125 * Gets the list of primitives affected by this error and are selectable 126 * @return the list of selectable primitives affected by this error 127 */ 128 public Collection<? extends OsmPrimitive> getSelectablePrimitives() { 129 List<OsmPrimitive> selectablePrimitives = new ArrayList<OsmPrimitive>(primitives.size()); 130 for (OsmPrimitive o : primitives) { 131 if (o.isSelectable()) { 132 selectablePrimitives.add(o); 133 } 134 } 135 return selectablePrimitives; 136 } 137 138 139 /** 124 140 * Sets the list of primitives affected by this error 125 141 * @param primitives the list of primitives affected by this error -
trunk/src/org/openstreetmap/josm/gui/dialogs/ValidatorDialog.java
r4462 r4672 329 329 if (nodeInfo instanceof TestError) { 330 330 TestError error = (TestError) nodeInfo; 331 sel.addAll(error.get Primitives());331 sel.addAll(error.getSelectablePrimitives()); 332 332 } 333 333 }
Note:
See TracChangeset
for help on using the changeset viewer.