Changeset 14341 in josm for trunk/src/org
- Timestamp:
- 2018-10-17T02:57:45+02:00 (6 years ago)
- Location:
- trunk/src/org/openstreetmap/josm
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/actions/AbstractMergeAction.java
r14338 r14341 58 58 * Whether the checkbox is ticked 59 59 */ 60 public boolean checkboxTicked = false;60 public boolean checkboxTicked; 61 61 62 62 /** -
trunk/src/org/openstreetmap/josm/data/gpx/GpxData.java
r14338 r14341 260 260 static class GpxTrackSegmentSpan { 261 261 262 publicfinal Date firstTime;263 publicfinal Date lastTime;262 final Date firstTime; 263 final Date lastTime; 264 264 private final boolean inv; 265 265 private final WayPoint firstWp; … … 283 283 } 284 284 285 publicWayPoint getFirstWp() {285 WayPoint getFirstWp() { 286 286 return new WayPoint(firstWp); 287 287 } 288 288 289 publicWayPoint getLastWp() {289 WayPoint getLastWp() { 290 290 return new WayPoint(lastWp); 291 291 } … … 293 293 // no new instances needed, therefore own methods for that 294 294 295 publicboolean firstEquals(Object other) {295 boolean firstEquals(Object other) { 296 296 return firstWp.equals(other); 297 297 } 298 298 299 publicboolean lastEquals(Object other) {299 boolean lastEquals(Object other) { 300 300 return lastWp.equals(other); 301 301 } … … 305 305 } 306 306 307 publicboolean overlapsWith(GpxTrackSegmentSpan other) {307 boolean overlapsWith(GpxTrackSegmentSpan other) { 308 308 return (firstTime.before(other.lastTime) && other.firstTime.before(lastTime)) 309 309 || (other.firstTime.before(lastTime) && firstTime.before(other.lastTime)); 310 310 } 311 311 312 publicstatic GpxTrackSegmentSpan tryGetFromSegment(GpxTrackSegment seg) {312 static GpxTrackSegmentSpan tryGetFromSegment(GpxTrackSegment seg) { 313 313 WayPoint b = getNextWpWithTime(seg, true); 314 314 if (b != null) { … … 348 348 } 349 349 } 350 segSpans.sort((o1, o2) -> { 351 return o1.firstTime.compareTo(o2.firstTime); 352 }); 350 segSpans.sort((o1, o2) -> o1.firstTime.compareTo(o2.firstTime)); 353 351 } 354 352 return segSpans; -
trunk/src/org/openstreetmap/josm/gui/dialogs/layer/MergeGpxLayerDialog.java
r14338 r14341 43 43 private final JTable t; 44 44 private final JCheckBox c; 45 private final Component parent;46 45 private final JButton btnUp; 47 46 private final JButton btnDown; … … 55 54 super(parent, tr("Merge GPX layers"), tr("Merge"), tr("Cancel")); 56 55 setButtonIcons("dialogs/mergedown", "cancel"); 57 this.parent = parent;58 56 59 57 JPanel p = new JPanel(new GridBagLayout()); … … 137 135 && (!ConditionalOptionPaneUtil.showConfirmationDialog( 138 136 "gpx_target_change", 139 parent,137 getParent(), 140 138 new JLabel("<html>" + 141 139 tr("This will change the target layer to \"{0}\".<br>Would you like to continue?", … … 185 183 public int getRowCount() { 186 184 return layers.size(); 187 188 } 189 190 public void moveRow(int row, int newRow) { 185 } 186 187 void moveRow(int row, int newRow) { 191 188 Collections.swap(layers, row, newRow); 192 189 } 193 190 194 publicList<GpxLayer> getSortedLayers() {191 List<GpxLayer> getSortedLayers() { 195 192 return layers; 196 193 } … … 210 207 case 2: 211 208 return layers.get(row).data.getTrackSegsCount(); 209 default: 210 throw new IndexOutOfBoundsException(Integer.toString(col)); 212 211 } 213 throw new IndexOutOfBoundsException(Integer.toString(col));214 212 } 215 213 }
Note:
See TracChangeset
for help on using the changeset viewer.