}
}
});
dataTable.addCellHighlightHandler(new CellHighlightHandler() {
public void onCellHighlight(CellHighlightEvent event) {
Cell cell = event.getValue();
highlightedCellLabel.setText("Highlighted cell: (" + cell.getRowIndex()
+ "," + cell.getCellIndex() + ")");
}
});
dataTable.addCellUnhighlightHandler(new CellUnhighlightHandler() {
public void onCellUnhighlight(CellUnhighlightEvent event) {
Cell cell = event.getValue();
unhighlightedCellLabel.setText("Last unhighlighted cell: ("
+ cell.getRowIndex() + "," + cell.getCellIndex() + ")");
}
});
dataTable.addRowHighlightHandler(new RowHighlightHandler() {
public void onRowHighlight(RowHighlightEvent event) {
Row cell = event.getValue();
highlightedRowLabel.setText("Highlighted row: (" + cell.getRowIndex()
+ ")");
}
});
dataTable.addRowUnhighlightHandler(new RowUnhighlightHandler() {
public void onRowUnhighlight(RowUnhighlightEvent event) {
Row cell = event.getValue();
unhighlightedRowLabel.setText("Last unhighlighted row: ("
+ cell.getRowIndex() + ")");
}
});
dataTable.addRowSelectionHandler(new RowSelectionHandler() {
public void onRowSelection(RowSelectionEvent event) {
// Show the previously selected rows