In Groovy SwingBuilder, how can I close the JTable closure that fires when a cell is selected?
1 answer
I'm not an expert in groovy, but when inside a swingbuilder table item you can use the Groovy way interfaces . This works because the ListSelectionListener only has one method.
table(id: 'myTable') {
myTable.selectionModel.addListSelectionListener({evt->
println("selection changed")
} as ListSelectionListener)
}
+3
source to share