Search code examples
gwtcelltablegwt-celltable

How to have a unique selection across multiple CellTables


What is the simplest way to have multiple CellTables in a same page, so that selecting a row in one CellTable clears any selection in the other CellTables?


Solution

  • Nothing is easier. Just create a unique SelectionModel, and use the setSelectionModel function to assign it to each of the CellTables.

    Though this might seem obvious in retrospect, it took me a while to think of it.