delettion of rows in sfv table improved
This commit is contained in:
parent
8360ed0c69
commit
69f549c3b7
@ -180,6 +180,9 @@ public class ChecksumComputationExecutor {
|
|||||||
|
|
||||||
adjustPoolSize();
|
adjustPoolSize();
|
||||||
|
|
||||||
|
fireRemainingTaskCountChange();
|
||||||
|
fireActiveSessionTaskCountChange();
|
||||||
|
|
||||||
if (executor.getActiveCount() == 0) {
|
if (executor.getActiveCount() == 0) {
|
||||||
setActive(false);
|
setActive(false);
|
||||||
}
|
}
|
||||||
@ -187,6 +190,12 @@ public class ChecksumComputationExecutor {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public void purge() {
|
||||||
|
executor.purge();
|
||||||
|
fireActiveSessionTaskCountChange();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
public void addPropertyChangeListener(PropertyChangeListener listener) {
|
public void addPropertyChangeListener(PropertyChangeListener listener) {
|
||||||
propertyChangeSupport.addPropertyChangeListener(listener);
|
propertyChangeSupport.addPropertyChangeListener(listener);
|
||||||
}
|
}
|
||||||
|
@ -136,13 +136,15 @@ public class SfvTableModel extends AbstractTableModel {
|
|||||||
ChecksumRow row = rows.get(i);
|
ChecksumRow row = rows.get(i);
|
||||||
rowsToRemove.add(rows.get(i));
|
rowsToRemove.add(rows.get(i));
|
||||||
|
|
||||||
for (File columnRoot : checksumColumnRoots) {
|
for (Checksum checksum : row.getChecksums()) {
|
||||||
row.getChecksum(columnRoot).cancelComputationTask();
|
checksum.cancelComputationTask();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
rows.removeAll(rowsToRemove);
|
rows.removeAll(rowsToRemove);
|
||||||
fireTableRowsDeleted(rowIndices[0], rowIndices[rowIndices.length - 1]);
|
fireTableRowsDeleted(rowIndices[0], rowIndices[rowIndices.length - 1]);
|
||||||
|
|
||||||
|
ChecksumComputationExecutor.getInstance().purge();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user