Hi Guys
We currently use a widget from GWT mosaic which is called LiveTable
but is basically a rework of the Paging ScrollTable. We are also tied
to GWT 1.7.
The problem I face with this table is that the user has the ability to
completely rework the table and then re-render it, but the only
feasible way to do this I have found is to create an entirely new
tablemodel and tabledefinitions, and then create a new table, clear
the layoutpanel add the new table and refresh. But this is a nasty
process and gives FF issues with the jscript rendering and causes
script timeouts.
I asked the guy who wrote the Table if he knew of a better way, but he
said he had to do similar to me in another project, so my question to
you guys... is it possible? Or is there a way to get the layouting
done without upsetting Firefox?
final TableModel<AbstractBaseCell[]> tableModel = new
IterableTableModel<AbstractBaseCell[]>(
data) {
@Override
public int getRowCount() {
return data.size();
}
@SuppressWarnings("unchecked")
@Override
public void requestRows(final Request request,
final Callback<AbstractBaseCell[]> callback) {
final int numRows = Math.min(request.getNumRows(),
data.size()
- request.getStartRow());
final List<AbstractBaseCell[]> list = new
ArrayList<AbstractBaseCell[]>();
for (int i = 0, n = numRows; i < n; i++) {
list.add(data.get(request.getStartRow() + i));
}
final SerializableResponse response = new
SerializableResponse(
list);
callback.onRowsReady(request, response);
}
};
table = new LiveTable<AbstractBaseCell[]>(tableModel,
createTableDefinition());
layoutPanel.add(table);
//table.fillWidth();
layoutPanel.layout();
Thanks
Tom
--
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.