Changeset 33154 in osm for applications/editors/josm


Ignore:
Timestamp:
2017-02-25T00:59:57+01:00 (8 years ago)
Author:
donvip
Message:

fix some warnings

Location:
applications/editors/josm/plugins/merge-overlap/src/mergeoverlap
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/merge-overlap/src/mergeoverlap/MergeOverlapAction.java

    r33153 r33154  
    5252public class MergeOverlapAction extends JosmAction {
    5353
     54    Map<Way, List<Relation>> relations = new HashMap<>();
     55    Map<Way, Way> oldWays = new HashMap<>();
     56    Map<Relation, Relation> newRelations = new HashMap<>();
     57    Set<Way> deletes = new HashSet<>();
     58
    5459    /**
    5560     * Constructs a new {@code MergeOverlapAction}.
     
    6166                Shortcut.ALT_CTRL), true);
    6267    }
    63 
    64     Map<Way, List<Relation>> relations = new HashMap<>();
    65     Map<Way, Way> oldWays = new HashMap<>();
    66     Map<Relation, Relation> newRelations = new HashMap<>();
    67     Set<Way> deletes = new HashSet<>();
    6868
    6969    /**
  • applications/editors/josm/plugins/merge-overlap/src/mergeoverlap/hack/MyCombinePrimitiveResolverDialog.java

    r30782 r33154  
    5454
    5555    /**
     56     * Constructs a new {@code MyCombinePrimitiveResolverDialog}.
     57     * @param parent The parent component in which this dialog will be displayed.
     58     */
     59    public MyCombinePrimitiveResolverDialog(Component parent) {
     60        super(parent);
     61    }
     62
     63    /**
    5664     * Replies the unique instance of the dialog
    5765     *
     
    6068    public static MyCombinePrimitiveResolverDialog getInstance() {
    6169        if (instance == null) {
    62             GuiHelper.runInEDTAndWait(new Runnable() {
    63                 @Override public void run() {
    64                     instance = new MyCombinePrimitiveResolverDialog(Main.parent);
    65                 }
    66             });
     70            GuiHelper.runInEDTAndWait(() -> instance = new MyCombinePrimitiveResolverDialog(Main.parent));
    6771        }
    6872        return instance;
     
    8690            }
    8791        };
    88     }
    89 
    90     /**
    91      * Constructs a new {@code MyCombinePrimitiveResolverDialog}.
    92      * @param parent The parent component in which this dialog will be displayed.
    93      */
    94     public MyCombinePrimitiveResolverDialog(Component parent) {
    95         super(parent);
    9692    }
    9793
  • applications/editors/josm/plugins/merge-overlap/src/mergeoverlap/hack/MyRelationMemberConflictResolverModel.java

    r31967 r33154  
    6767    public void populate(Collection<Relation> relations, Collection<Way> memberWays, Map<Way, Way> oldWays) {
    6868        decisions.clear();
    69         relations = relations == null ? new LinkedList<Relation>() : relations;
    70         memberWays = memberWays == null ? new LinkedList<Way>() : memberWays;
     69        relations = relations == null ? new LinkedList<>() : relations;
     70        memberWays = memberWays == null ? new LinkedList<>() : memberWays;
    7171        for (Relation r : relations) {
    7272            for (Way w : memberWays) {
Note: See TracChangeset for help on using the changeset viewer.