lassedk1 / google-web-toolkit-incubator

Automatically exported from code.google.com/p/google-web-toolkit-incubator
1 stars 0 forks source link

dataTable size isn't updated when rowValues is empty #357

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem? 
1. call pagingScrollTable.setData(...) with a non-empty list of rows
2. call pagingScrollTable.setData(...) with an empty list of rows
3. the underlying FixedWidthGrid dataTable will not be resized on the 
second call, so client code which tries to iterate over the rows by calling 
pagingScrollTable.getRowValue(i) for i = 
0..pagingScrollTable.getDataTable().getRowCount() will end up with a bunch 
of nulls.

What is the expected output? What do you see instead?
The else-clause in pagingScrollTable.setData(...) should update the row 
count in the underlying dataTable.

Workaround if you have one:
Right now I'm forced to do a null check whenever I call 
pagingScrollTable.getRowValue(i) in my client code.

Original issue reported on code.google.com by bjaco...@google.com on 22 May 2010 at 12:03