Given: JTable with multiple selection enabled.
Problem: we made it possible to drag rows to other positions. When dragging a row to another row, all rows in between will be selected, we do not want this.
Question: Is there an easy way to turn this off, without losing the possibility for multiple selection using shift and control?
Details:
Long time ago my colleague implemented the possibility to drag single rows of a JTable to a different location by setting
setDragEnabled(false)
and using the mousePressed and mouseReleased methods of a MouseListener on the table.
This works fine for us.
Multiple selection is turned on in the table, which we use by pressing shift and control.