Browse Source

Merge pull request #269 from greboid/dev3

Add a removeAll method to GenericTableModel.
pull/270/head
Chris Smith 9 years ago
parent
commit
4089b8b612

+ 8
- 0
ui_swing/src/com/dmdirc/addons/ui_swing/components/GenericTableModel.java View File

@@ -222,6 +222,14 @@ public class GenericTableModel<T> extends AbstractTableModel {
222 222
         fireTableRowsDeleted(index, index);
223 223
     }
224 224
 
225
+    /**
226
+     * Removes all the values from the model.
227
+     */
228
+    public void removeAll() {
229
+        values.clear();
230
+        fireTableDataChanged();
231
+    }
232
+
225 233
     /**
226 234
      * Adds the specified value at the end of the model.
227 235
      *

Loading…
Cancel
Save