General Category > Bug Report
Another bug for hidden grids (with fix)
(1/1)
jplevene:
If the grid is hidden when data is loaded, to fix I added the following:
--- Code: ---getHeightR: function(ri, rows) {
if(typeof(ri)==="undefined") return 0;
...
getHeightCell: function(ri, rows) {
if(typeof(ri)==="undefined" || ri<0) return 0;
--- End code ---
In the case above, I opened the grid, scrolled down a lot, closed the grid, new data was loaded and it went wrong trying to show it.
The pqGrid code has been written assuming that the grid is visible when data is loaded or a refresh is called. This is obviously not always the case as sometimes the grid is prepared in the background for a better user experience.
paramvir:
Data can be loaded in a hidden pqgrid and refresh can be safely called on it.
It would be great if you can share a jsfiddle or test case.
Navigation
[0] Message Index
Go to full version