Changeset 1654 in josm for trunk/src/org/openstreetmap/josm/command
- Timestamp:
- 2009-06-07T23:22:54+02:00 (16 years ago)
- Location:
- trunk/src/org/openstreetmap/josm/command
- Files:
-
- 2 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/command/TagConflictResolveCommand.java
r1642 r1654 16 16 import org.openstreetmap.josm.data.osm.Relation; 17 17 import org.openstreetmap.josm.data.osm.Way; 18 import org.openstreetmap.josm.gui.conflict. tags.MergeDecisionType;18 import org.openstreetmap.josm.gui.conflict.MergeDecisionType; 19 19 import org.openstreetmap.josm.gui.conflict.tags.TagMergeItem; 20 20 import org.openstreetmap.josm.tools.ImageProvider; … … 121 121 // 122 122 if (!Main.map.conflictDialog.conflicts.containsKey(my)) { 123 Main.map.conflictDialog. conflicts.put(my,their);123 Main.map.conflictDialog.addConflict(my, their); 124 124 } 125 125 } 126 127 128 126 } -
trunk/src/org/openstreetmap/josm/command/VersionConflictResolveCommand.java
r1642 r1654 86 86 } 87 87 } 88 89 90 88 } -
trunk/src/org/openstreetmap/josm/command/WayNodesConflictResolverCommand.java
r1622 r1654 25 25 26 26 /** my way */ 27 private Way my; 28 /** their way */ 29 private Way their; 27 private final Way my; 28 /** their way */ 29 private final Way their; 30 30 /** the list of merged nodes. This becomes the list of news of my way after the 31 31 * command is executed 32 32 */ 33 private List<Node> mergedNodeList; 34 33 private final List<Node> mergedNodeList; 34 35 35 /** 36 36 * 37 37 * @param my my may 38 38 * @param their their way 39 * @param mergedNodeList the list of merged nodes 39 * @param mergedNodeList the list of merged nodes 40 40 */ 41 41 public WayNodesConflictResolverCommand(Way my, Way their, List<Node> mergedNodeList) { … … 44 44 this.mergedNodeList = mergedNodeList; 45 45 } 46 47 46 47 48 48 @Override 49 49 public MutableTreeNode description() { 50 50 return new DefaultMutableTreeNode( 51 51 new JLabel( 52 tr("Resolve conflicts in node list of of way {0}", my.id), 53 ImageProvider.get("data", "object"), 54 JLabel.HORIZONTAL 52 tr("Resolve conflicts in node list of of way {0}", my.id), 53 ImageProvider.get("data", "object"), 54 JLabel.HORIZONTAL 55 55 ) 56 56 ); 57 57 } 58 58 … … 62 62 // 63 63 super.executeCommand(); 64 64 65 65 // replace the list of nodes of 'my' way by the list of merged 66 // nodes 66 // nodes 67 67 // 68 68 my.nodes.clear(); … … 74 74 } 75 75 } 76 return true; 76 return true; 77 77 } 78 78 … … 80 80 public void fillModifiedData(Collection<OsmPrimitive> modified, Collection<OsmPrimitive> deleted, 81 81 Collection<OsmPrimitive> added) { 82 modified.add(my); 82 modified.add(my); 83 83 } 84 84 … … 88 88 // 89 89 super.undoCommand(); 90 90 91 91 // restore a conflict if necessary 92 92 // 93 93 if (!Main.map.conflictDialog.conflicts.containsKey(my)) { 94 Main.map.conflictDialog. conflicts.put(my,their);94 Main.map.conflictDialog.addConflict(my, their); 95 95 } 96 96 }
Note:
See TracChangeset
for help on using the changeset viewer.