开发者

Set Extjs Panel's Height (Layout) After It's Child items taken their height

How can we recalculate the Extjs-4 Panel's Height After it's Child items like Grid (Which have auto height) takes 开发者_C百科their height.


Use autoHeight with Panel and GridPanel. Then catch the resize event of GridPanel to force Panel to layout :

    var grid = new Ext.grid.GridPanel({

    listeners: {
        'resize': function () {
            var panel = Ext.getCmp('panel');
            panel.doLayout();
        }
    }
}),
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜