Changeset 30532 in osm for applications/editors/josm/plugins/public_transport/src
- Timestamp:
- 2014-07-14T04:18:06+02:00 (11 years ago)
- Location:
- applications/editors/josm/plugins/public_transport/src/public_transport
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/public_transport/src/public_transport/GTFSImporterDialog.java
r29854 r30532 28 28 private JDialog jDialog = null; 29 29 private JTabbedPane tabbedPane = null; 30 private JComboBox cbStoptype = null; 30 private JComboBox<TransText> cbStoptype = null; 31 31 private JList tracksList = null; 32 32 private JTextField tfGPSTimeStart = null; … … 68 68 contentPane.add(label); 69 69 70 cbStoptype = new JComboBox(); 70 cbStoptype = new JComboBox<>(); 71 71 cbStoptype.setEditable(false); 72 72 for(String type : stoptypes) … … 481 481 public static double parseTime(String s) 482 482 { 483 double result = 0;484 483 if ((s.charAt(2) != ':') || (s.charAt(2) != ':') 485 484 || (s.length() < 8)) -
applications/editors/josm/plugins/public_transport/src/public_transport/RoutePatternAction.java
r29859 r30532 398 398 private static JDialog jDialog = null; 399 399 private static JTabbedPane tabbedPane = null; 400 private static DefaultListModel relsListModel = null; 400 private static DefaultListModel<RouteReference> relsListModel = null; 401 401 private static TagTableModel requiredTagsData = null; 402 402 private static CustomCellEditorTable requiredTagsTable = null; … … 410 410 private static StoplistTableModel stoplistData = null; 411 411 private static JTable stoplistTable = null; 412 private static JList relsList = null; 412 private static JList<RouteReference> relsList = null; 413 413 private static JCheckBox cbRight = null; 414 414 private static JCheckBox cbLeft = null; … … 418 418 private static Vector< RelationMember > markedWays = new Vector< RelationMember >(); 419 419 private static Vector< RelationMember > markedNodes = new Vector< RelationMember >(); 420 421 private static Relation copy = null;422 420 423 421 public RoutePatternAction() { … … 470 468 contentPane.add(headline); 471 469 472 relsListModel = new DefaultListModel(); 473 relsList = new JList(relsListModel); 470 relsListModel = new DefaultListModel<>(); 471 relsList = new JList<>(relsListModel); 474 472 JScrollPane rpListSP = new JScrollPane(relsList); 475 473 String[] data = {"1", "2", "3", "4", "5", "6"}; … … 584 582 rowContent.add("route"); 585 583 requiredTagsData.addRow(rowContent); 586 JComboBox comboBox = new JComboBox(); 584 JComboBox<String> comboBox = new JComboBox<>(); 587 585 comboBox.addItem("route"); 588 586 requiredTagsTable.setCellEditor(0, 1, new DefaultCellEditor(comboBox)); … … 592 590 rowContent.add(1, "bus"); 593 591 requiredTagsData.addRow(rowContent); 594 /*JComboBox*/ comboBox = new JComboBox(); 592 /*JComboBox*/ comboBox = new JComboBox<>(); 595 593 comboBox.addItem("bus"); 596 594 comboBox.addItem("trolleybus"); … … 743 741 itineraryTable.setModel(itineraryData); 744 742 /*JScrollPane*/ tableSP = new JScrollPane(itineraryTable); 745 /*JComboBox*/ comboBox = new JComboBox(); 743 /*JComboBox*/ comboBox = new JComboBox<>(); 746 744 comboBox.addItem(""); 747 745 comboBox.addItem("forward"); … … 867 865 stoplistTable.setModel(stoplistData); 868 866 /*JScrollPane*/ tableSP = new JScrollPane(stoplistTable); 869 /*JComboBox*/ comboBox = new JComboBox(); 867 /*JComboBox*/ comboBox = new JComboBox<>(); 870 868 comboBox.addItem(""); 871 869 comboBox.addItem("forward_stop"); … … 1109 1107 Vector< RelationMember > itemsToReflect = new Vector< RelationMember >(); 1110 1108 Vector< RelationMember > otherItems = new Vector< RelationMember >(); 1111 int insPos = itineraryTable.getSelectedRow();1112 1109 1113 1110 // Temp 1114 1111 Node firstNode = null; 1115 Node lastNode = null; 1112 //Node lastNode = null; 1116 1113 1117 1114 for (int i = 0; i < currentRoute.getMembersCount(); ++i) … … 1136 1133 firstNode = item.getWay().getNode(0); 1137 1134 } 1138 lastNode = item.getWay().getNode(item.getWay().getNodesCount() - 1); 1135 //lastNode = item.getWay().getNode(item.getWay().getNodesCount() - 1); 1139 1136 } 1140 1137 else if (item.isNode()) -
applications/editors/josm/plugins/public_transport/src/public_transport/StopImporterAction.java
r30358 r30532 38 38 { 39 39 private static StopImporterDialog dialog = null; 40 private static DefaultListModel tracksListModel = null; 40 private static DefaultListModel<TrackReference> tracksListModel = null; 41 41 private static GpxData data = null; 42 42 private static TrackReference currentTrack = null; … … 62 62 } 63 63 64 public DefaultListModel getTracksListModel() 64 public DefaultListModel<TrackReference> getTracksListModel() 65 65 { 66 66 if (tracksListModel == null) 67 tracksListModel = new DefaultListModel(); 67 tracksListModel = new DefaultListModel<>(); 68 68 return tracksListModel; 69 69 } -
applications/editors/josm/plugins/public_transport/src/public_transport/StopImporterDialog.java
r29859 r30532 33 33 private JDialog jDialog = null; 34 34 private JTabbedPane tabbedPane = null; 35 private JComboBox cbStoptype = null; 36 private JList tracksList = null; 35 private JComboBox<TransText> cbStoptype = null; 36 private JList<TrackReference> tracksList = null; 37 37 private JTextField tfGPSTimeStart = null; 38 38 private JTextField tfStopwatchStart = null; … … 80 80 contentPane.add(label); 81 81 82 DefaultListModel tracksListModel = controller.getTracksListModel(); 83 tracksList = new JList(tracksListModel); 82 DefaultListModel<TrackReference> tracksListModel = controller.getTracksListModel(); 83 tracksList = new JList<>(tracksListModel); 84 84 JScrollPane rpListSP = new JScrollPane(tracksList); 85 85 String[] data = {"1", "2", "3", "4", "5", "6"}; … … 114 114 contentPane.add(label); 115 115 116 cbStoptype = new JComboBox(); 116 cbStoptype = new JComboBox<>(); 117 117 cbStoptype.setEditable(false); 118 118 for(String type : stoptypes) … … 640 640 { 641 641 stoplistTable.setModel(model); 642 JComboBox comboBox = new JComboBox(); 642 JComboBox<TransText> comboBox = new JComboBox<>(); 643 643 comboBox.addItem(new TransText(null)); 644 644 comboBox.addItem(new TransText(marktr("yes"))); … … 661 661 { 662 662 waypointTable.setModel(model); 663 JComboBox comboBox = new JComboBox(); 663 JComboBox<TransText> comboBox = new JComboBox<>(); 664 664 comboBox.addItem(new TransText(null)); 665 665 comboBox.addItem(new TransText(marktr("yes")));
Note:
See TracChangeset
for help on using the changeset viewer.