Difference between revisions of "CG Grid's height"

From Catglobe Wiki
Jump to: navigation, search
 
(One intermediate revision by one other user not shown)
Line 1: Line 1:
 +
<accesscontrol>Main:MyGroup</accesscontrol>
 
Hi,  
 
Hi,  
  

Latest revision as of 05:39, 18 October 2013

<accesscontrol>Main:MyGroup</accesscontrol> Hi,

To simplify this, I have attached new funtion to grid object. Therefore, from now on, you can reset grid height as

grid.resizeHeight( value );


These days i have fixed some bugs related to LnF in FF. Most of them came from the CGGrid which overlapped other below content. For example, in Data Import wizard or Access Dialog. When i looked at the code, it had code to set the grid's height as we normally does in catglobe.

But why did not it work? In reality, sometime it did, sometime not. What did we do was, i mentioned here was a JQuery structure:

$("#" + grid.Id + "_mr").height(h);
$("#" + grid.Id + "_mc").height(h);

What it did was to set height for the row and cell containing the main content of grid. HOWEVER, the outer parts of them are tbody and table, they were still 100% height.  That is the point.

How to fix it? Simple, make sure you also set height for tbody and table as well.

Code snippest:

$("#" + grid.Id + "_mtb").height(h);
$("#" + grid.Id + "_main").height(h);