On 2 nov, 17:07, Geoffrey De Smet <[email protected]> wrote:
> I 'd like to add a button to reload the CellTable when it's pushed,
> but I can only find:
> - cellTable.redraw(); // Doesn't reload the data from the backend
> - simplePager.firstPage(); // I don't want it to change the page
>
> Is there an easy way to do something like cellTable.reload() or
> cellTable.refresh() ?

Maybe:
cellTable.setVisibleRangeAndClearData(cellTable.getVisibleRange(),
true);

http://google-web-toolkit.googlecode.com/svn/javadoc/2.1/com/google/gwt/user/cellview/client/AbstractHasData.html#setVisibleRangeAndClearData(com.google.gwt.view.client.Range,
boolean)

But I think the expected use is to do it in your "model" rather than
the "view" (CellTable), where the "model" (or presenter, or whatever)
will fetch the data from the backend (maybe using getVisibleRange() to
filter it) and call setRowData() on the CellTable to update it.

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.

Reply via email to