Przeglądaj źródła

Fix build warnings.

Change-Id: Id481ca2eb5b5982c74c3186b889e976dc8ed3f0e
Reviewed-on: http://gerrit.dmdirc.com/2666
Reviewed-by: Greg Holmes <greg@dmdirc.com>
Automatic-Compile: DMDirc Build Manager
tags/0.8rc1
Chris Smith 10 lat temu
rodzic
commit
25e2909f96

+ 2
- 2
src/com/dmdirc/ui/FatalErrorDialog.java Wyświetl plik

@@ -217,11 +217,11 @@ public final class FatalErrorDialog extends JDialog implements ActionListener,
217 217
             sendButton.setText("Sending...");
218 218
             restartButton.setEnabled(false);
219 219
             sendButton.setEnabled(false);
220
-            new SwingWorker() {
220
+            new SwingWorker<Void, Void>() {
221 221
 
222 222
                 /** {@inheritDoc} */
223 223
                 @Override
224
-                protected Object doInBackground() {
224
+                protected Void doInBackground() {
225 225
                     ErrorManager.getErrorManager().sendError(error);
226 226
                     return null;
227 227
                 }

+ 5
- 5
src/com/dmdirc/ui/UIAttachDialog.java Wyświetl plik

@@ -55,7 +55,7 @@ public class UIAttachDialog extends JDialog implements ActionListener,
55 55
     /** Sensible component gap. */
56 56
     private static final int GAP = 5;
57 57
     /** Services list. */
58
-    private final JList list;
58
+    private final JList<Service> list;
59 59
     /** Main instance. */
60 60
     private final Main main;
61 61
 
@@ -70,9 +70,9 @@ public class UIAttachDialog extends JDialog implements ActionListener,
70 70
     }
71 71
 
72 72
     /** Initialises the model with a list of UIs. */
73
-    private JList initList() {
74
-        final DefaultListModel model = new DefaultListModel();
75
-        final JList newList = new JList(model);
73
+    private JList<Service> initList() {
74
+        final DefaultListModel<Service> model = new DefaultListModel<Service>();
75
+        final JList<Service> newList = new JList<Service>(model);
76 76
         newList.setCellRenderer(new ServiceRenderer());
77 77
         newList.addListSelectionListener(this);
78 78
         final List<Service> services = main.getPluginManager()
@@ -149,7 +149,7 @@ public class UIAttachDialog extends JDialog implements ActionListener,
149 149
 
150 150
         /** {@inheritDoc} */
151 151
         @Override
152
-        public Component getListCellRendererComponent(final JList list,
152
+        public Component getListCellRendererComponent(final JList<?> list,
153 153
                 final Object value, final int index, final boolean isSelected,
154 154
                 final boolean cellHasFocus) {
155 155
             final Component label = super.getListCellRendererComponent(list,

Ładowanie…
Anuluj
Zapisz