PDA

View Full Version : Lines of a dependent grid may not show completely



Pachat
21 Apr 2010, 9:09 AM
First tab has a master GridPanel orders
Second tab has a detail GridPanel details
Both using

view: new Ext.ux.grid.BufferView({
scrollDelay: false
}),
On the master Grid, we have the following selection model :

table_orders.getSelectionModel().on('rowselect', function(sm, rowIndex, record){
table_details.setTitle('#'+record.data.id);
store_details.load({params: {'value': record.data.id }});
});
First tab active, I click on a row.
Then I go to the second tab, and I see this
20058
dispite the fact that Firebug reports that all the lines have been loaded.

Then, doing nothing but slightly changing the size of the browser (FF 3.5.9), it shows all the lines it should :
20059

It is also possible to get the last image directly when clicking a row of the master grid, and then clicking right away the tab of the detailed grid. But if I wait, let say half a second, I only get the first image.

It looks like this has to do with some asynchronous timer.

Is there a way to enforce programatically a proper rendering so that all lines will be seen at once as in the last image ?

bocockli
21 Apr 2010, 4:33 PM
Hi

Look I don't have experience with Grid recently, but have seen a similar problem with ViewPanel in TabPanel; maybe the following will help.

Default the Grid will render in the background. You could try to defer the render using deferRowRender() on the Grid or deferRender() on the TabPanel and then using a show event to call a render of either the grid or the underlying panel. This will show the Gird more quickly but slow the population of data.

Generally I find with these problems fiddling around with render control methods like render or doLayout will fix the problem.

Len