Ignore:
Timestamp:
2017-06-09T00:03:23+02:00 (2 years ago)
Author:
michael2402
Message:

See #13036: Add data set tests to SelectCommand

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/command/SelectCommand.java

    r12349 r12350  
    5959    @Override
    6060    public void undoCommand() {
     61        ensurePrimitivesAreInDataset();
     62
    6163        getAffectedDataSet().setSelected(oldSelection);
    6264    }
     
    6466    @Override
    6567    public boolean executeCommand() {
     68        ensurePrimitivesAreInDataset();
     69
    6670        oldSelection = getAffectedDataSet().getSelected();
    6771        getAffectedDataSet().setSelected(newSelection);
    6872        return true;
     73    }
     74
     75    @Override
     76    public Collection<? extends OsmPrimitive> getParticipatingPrimitives() {
     77        return Collections.unmodifiableCollection(newSelection);
    6978    }
    7079
Note: See TracChangeset for help on using the changeset viewer.