I'm working on a Java GUI project with SwingX where I inserted a JTable with a DefaultTableModel! The JTable has two columns (ID and path) and in principle two main features:
- With two JButtons "+" and "-" I can add rows to the DefaultTableModel and remove selected ones!
- With double-right click on the second column (path) a JFileChooser opens, where I can select a path, which will be set as value for the cell! For this action I implemented a CustomMouselistener and overwrote the "mousePressed" method!
My problem: After implementing this stuff, I can't edit the cell with a normal mouse-click on a cell! The cells are editable, because I can edit them with "F2" - press, but it seems that I overwrote the default functionality of the mouse!
Summarized I'm using following constructs:
- Table with DefaultTableModel (2 columns)
- MouseListener for JFileChooser
- ColumnModelListener to change width of columns!
Can someone help me with this issue?