I want to be able to enter a string inside a table cell of a MFXTableView and invoke a callback if enter is pressed.
Previously, I was using JavaFX instead of MaterialFX and it was working.
myEditableTableColumn.setCellFactory(TextFieldTableCell.forTableColumn()); // makes the cell editable
myEditableTableColumn.setOnCommit(new EventHandler<TableColumn.CellEditEvent<MyObject, String>>(){
public void handle(TableColumn.CellEditEvent<MyObject, String> t){
MyObject myObj = t.getTableView().getItems().get(t.getTablePosition().getRow());
myObj.setMyValue(t.getNewValue());
logger.debug("do sth. with my changed object.");
}
});