Reputation: 20313
We are using getInnerHeight
and getInnerWidth
methods in our application.Now we are migrating to ExtJS4
. As per my Observation, these two methods are not there for panel
.
Is there any thing replaces these two methods?
Upvotes: 1
Views: 1292
Reputation: 46
if you need the body width/height(without header, dockeditems etc...)try this:
var height = Ext.getCmp('panelId').body.getHeight(true);
Upvotes: 1
Reputation: 51
Pass boolean true as parameter for the getHeight() function. So you get:
var height = Ext.getCmp('panelId').getEl().getHeight(true);
Upvotes: 0
Reputation: 13475
Why are you using innerHeight and innerWidth? You can get the height/width of the element that the Ext.Panel
is rendered to as follows...
var height = Ext.getCmp('panelId').getEl().getHeight();
This should suffice unless you've got massive amounts of padding on your panel.
Upvotes: 0