Ignore:
Timestamp:
2014-07-14T04:18:06+02:00 (10 years ago)
Author:
donvip
Message:

[josm_plugins] fix compilation warnings

Location:
applications/editors/josm/plugins/turnrestrictions/test/src/org/openstreetmap/josm/plugins/turnrestrictions/editor
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/turnrestrictions/test/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/TurnRestrictionLegEditorTest.java

    r23192 r30532  
    1515import javax.swing.JPanel;
    1616import javax.swing.JScrollPane;
    17 import javax.swing.JTextArea;
    1817
    1918import org.openstreetmap.josm.data.coor.LatLon;
     
    3534public class TurnRestrictionLegEditorTest extends JFrame {
    3635   
    37     private JTextArea taTest;
    3836    private TurnRestrictionLegEditor editor;
    3937    private TurnRestrictionEditorModel model;
    40     private JList lstObjects;
    41     private DefaultListModel listModel;
     38    private JList<OsmPrimitive> lstObjects;
     39    private DefaultListModel<OsmPrimitive> listModel;
    4240    private DataSet dataSet;
    43    
    4441   
    4542    protected JPanel buildLegEditorPanel() {
     
    7673    protected JPanel buildObjectListPanel() {
    7774        JPanel pnl = new JPanel(new BorderLayout());
    78         listModel = new DefaultListModel();
    79         pnl.add(new JScrollPane(lstObjects = new JList(listModel)), BorderLayout.CENTER);
     75        listModel = new DefaultListModel<>();
     76        pnl.add(new JScrollPane(lstObjects = new JList<>(listModel)), BorderLayout.CENTER);
    8077        lstObjects.setCellRenderer(new OsmPrimitivRenderer());     
    8178       
  • applications/editors/josm/plugins/turnrestrictions/test/src/org/openstreetmap/josm/plugins/turnrestrictions/editor/ViaListTest.java

    r23192 r30532  
    2121 *
    2222 */
    23 public class ViaListTest  extends JFrame{
     23public class ViaListTest extends JFrame {
    2424   
    25     private ViaList lstVias;
    2625    private TurnRestrictionEditorModel model;
    27     private JList lstJOSMSelection;
    28    
    2926   
    3027    protected void build() {
    3128        DataSet ds = new DataSet();
    32         OsmDataLayer layer =new OsmDataLayer(ds, "test",null);
     29        OsmDataLayer layer =new OsmDataLayer(ds, "test", null);
    3330        // mock a controler
    3431        NavigationControler controler = new NavigationControler() {
     
    5451       
    5552        DefaultListSelectionModel selectionModel = new DefaultListSelectionModel();
    56         c.add(lstVias = new ViaList(new ViaListModel(model, selectionModel), selectionModel), gc);
     53        c.add(new ViaList(new ViaListModel(model, selectionModel), selectionModel), gc);
    5754       
    5855        gc.gridx = 1;
    59         c.add(lstJOSMSelection = new JList(), gc);
     56        c.add(new JList<>(), gc);
    6057       
    6158        setSize(600,600);       
Note: See TracChangeset for help on using the changeset viewer.