Changeset 301 in josm for src/org/openstreetmap/josm/command
- Timestamp:
- 2007-08-08T14:56:38+02:00 (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/org/openstreetmap/josm/command/AddCommand.java
r298 r301 11 11 12 12 import org.openstreetmap.josm.Main; 13 import org.openstreetmap.josm.data.osm.DataSet; 13 14 import org.openstreetmap.josm.data.osm.OsmPrimitive; 14 15 import org.openstreetmap.josm.data.osm.visitor.AddVisitor; … … 28 29 */ 29 30 private final OsmPrimitive osm; 31 32 private DataSet ds; 30 33 31 34 /** … … 34 37 public AddCommand(OsmPrimitive osm) { 35 38 this.osm = osm; 39 this.ds = Main.ds; 36 40 } 37 41 38 42 @Override public void executeCommand() { 39 osm.visit(new AddVisitor( Main.ds));43 osm.visit(new AddVisitor(ds)); 40 44 } 41 45 42 46 @Override public void undoCommand() { 43 osm.visit(new DeleteVisitor( Main.ds));47 osm.visit(new DeleteVisitor(ds)); 44 48 } 45 49
Note:
See TracChangeset
for help on using the changeset viewer.