- Timestamp:
- 2016-02-22T00:54:12+01:00 (9 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/conflict/tags/PasteTagsConflictResolverDialog.java
r9847 r9849 44 44 45 45 public class PasteTagsConflictResolverDialog extends JDialog implements PropertyChangeListener { 46 privatestatic final Map<OsmPrimitiveType, String> PANE_TITLES;46 static final Map<OsmPrimitiveType, String> PANE_TITLES; 47 47 static { 48 48 PANE_TITLES = new EnumMap<>(OsmPrimitiveType.class); … … 52 52 } 53 53 54 privateenum Mode {54 enum Mode { 55 55 RESOLVING_ONE_TAGCOLLECTION_ONLY, 56 56 RESOLVING_TYPED_TAGCOLLECTIONS … … 356 356 } 357 357 358 privatestatic final class StatisticsInfo {358 static final class StatisticsInfo { 359 359 public int numTags; 360 360 public final Map<OsmPrimitiveType, Integer> sourceInfo; 361 361 public final Map<OsmPrimitiveType, Integer> targetInfo; 362 362 363 privateStatisticsInfo() {363 StatisticsInfo() { 364 364 sourceInfo = new EnumMap<>(OsmPrimitiveType.class); 365 365 targetInfo = new EnumMap<>(OsmPrimitiveType.class); … … 367 367 } 368 368 369 privatestatic final class StatisticsTableModel extends DefaultTableModel {369 static final class StatisticsTableModel extends DefaultTableModel { 370 370 private static final String[] HEADERS = new String[] {tr("Paste ..."), tr("From ..."), tr("To ...") }; 371 private final transient List<StatisticsInfo> data; 372 373 private StatisticsTableModel() { 374 data = new ArrayList<>(); 375 } 371 private final transient List<StatisticsInfo> data = new ArrayList<>(); 376 372 377 373 @Override … … 392 388 @Override 393 389 public int getRowCount() { 394 if (data == null) return 1; 395 return data.size() + 1; 390 return data == null ? 1 : data.size() + 1; 396 391 } 397 392 … … 406 401 } 407 402 408 private staticclass StatisticsInfoRenderer extends JLabel implements TableCellRenderer {403 static final class StatisticsInfoRenderer extends JLabel implements TableCellRenderer { 409 404 protected void reset() { 410 405 setIcon(null); … … 478 473 } 479 474 480 privatestatic final class StatisticsInfoTable extends JPanel {481 482 privateStatisticsInfoTable(StatisticsTableModel model) {475 static final class StatisticsInfoTable extends JPanel { 476 477 StatisticsInfoTable(StatisticsTableModel model) { 483 478 JTable infoTable = new JTable(model, 484 479 new TagTableColumnModelBuilder(new StatisticsInfoRenderer(), tr("Paste ..."), tr("From ..."), tr("To ...")).build());
Note:
See TracChangeset
for help on using the changeset viewer.