Ignore:
Timestamp:
2017-09-04T23:45:49+02:00 (2 years ago)
Author:
Don-vip
Message:

see #13036 - deprecate Command() default constructor, fix unit tests and java warnings

Location:
trunk/src/org/openstreetmap/josm/data
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/data/osm/DataSet.java

    r12718 r12726  
    263263
    264264    /**
     265     * Constructs a new {@code DataSet} initially filled with the given primitives.
     266     * @param osmPrimitives primitives to add to this data set
     267     * @since 12726
     268     */
     269    public DataSet(OsmPrimitive... osmPrimitives) {
     270        this();
     271        beginUpdate();
     272        try {
     273            for (OsmPrimitive o : osmPrimitives) {
     274                addPrimitive(o);
     275            }
     276        } finally {
     277            endUpdate();
     278        }
     279    }
     280
     281    /**
    265282     * Adds a new data source.
    266283     * @param source data source to add
  • trunk/src/org/openstreetmap/josm/data/osm/Node.java

    r12725 r12726  
    106106     * @return the east north coordinates or {@code null} if #is
    107107     */
     108    @Override
    108109    public EastNorth getEastNorth() {
    109110        return getEastNorth(Main.getProjection());
  • trunk/src/org/openstreetmap/josm/data/validation/tests/UnconnectedWays.java

    r12691 r12726  
    168168        mindist = Main.pref.getDouble(PREFIX + ".node_way_distance", 10.0);
    169169        minmiddledist = Main.pref.getDouble(PREFIX + ".way_way_distance", 0.0);
    170         DataSet dataSet = Main.main.getEditDataSet();
     170        DataSet dataSet = Main.main != null ? Main.main.getEditDataSet() : null;
    171171        dsArea = dataSet == null ? null : dataSet.getDataSourceArea();
    172172    }
Note: See TracChangeset for help on using the changeset viewer.