I am adding rows live to NatTable and I would like to be able to have a mode where the table automatically scrolls to the last row when rows are added.
To do this I am implementing the ListEventListener interface for glazed lists EventList and doing viewPortLayer.moveRowPositionIntoViewport(rowIndex, true) on the listChanged event. Is there a better way to accomplish this?
I am using the snapshot build of 1.0.0 if it makes any difference.
You could also create a ILayerListener or ILayerEventHandler (which is typed) for handling RowInsertEvents. For this you would need to use the DetailGlazedListsEventHandler that is added with 1.0.0. Nevertheless you would still need to call viewPortLayer.moveRowPositionIntoViewport(rowIndex, true) to scroll to the last row.