sench23
3 Feb 2011, 8:39 AM
Hello,
I have a panel that holds some components, and a toolbar docked at the bottom. After hiding the toolbar, panel does not resize when i call doLayout() or doComponentLayout().
Any suggestions what I am doing wrong?
_mainDetailsToolbar = new Ext.Toolbar({ dock: 'bottom', ui: 'light', style: { background: '#ffffff' },
layout: { pack: 'center', align: 'center' },
items: [{ xtype: 'panel', html: dfx.fn.getDetailsAd('html'), width: 297, height: 47,
style: { background: '#ffffff'}}], border: 0
});
_mainDetailsCard = new Ext.Panel({
layout: 'fit',
fullscreen: true,
useToolbar: false,
style: { background: 'url("Images/dailyfx-bg.jpg") center 40px repeat' },
title: 'Details content',
updateHtml: function(content) {
this.updateComponent(
new Ext.Panel({
cls: 'container',
items: [
{ xtype: 'panel', html: content, cls: 'container', layout: 'fit', style: { fontSize: '0.7em'} }
]
}));
},
updateComponent: function(cmp) {
_mainDetailsCardContent.removeAll();
_mainDetailsCardContent.update('');
_mainDetailsCardContent.add(cmp);
_mainDetailsCardContent.doLayout();
},
items: [
// removed
],
dockedItems: [
_mainDetailsToolbar // after hiding it, _mainDetailsCard does not resize after calling doLayout() nor doComponentLayout()
]
});
Thanks,
Aleksandar
I have a panel that holds some components, and a toolbar docked at the bottom. After hiding the toolbar, panel does not resize when i call doLayout() or doComponentLayout().
Any suggestions what I am doing wrong?
_mainDetailsToolbar = new Ext.Toolbar({ dock: 'bottom', ui: 'light', style: { background: '#ffffff' },
layout: { pack: 'center', align: 'center' },
items: [{ xtype: 'panel', html: dfx.fn.getDetailsAd('html'), width: 297, height: 47,
style: { background: '#ffffff'}}], border: 0
});
_mainDetailsCard = new Ext.Panel({
layout: 'fit',
fullscreen: true,
useToolbar: false,
style: { background: 'url("Images/dailyfx-bg.jpg") center 40px repeat' },
title: 'Details content',
updateHtml: function(content) {
this.updateComponent(
new Ext.Panel({
cls: 'container',
items: [
{ xtype: 'panel', html: content, cls: 'container', layout: 'fit', style: { fontSize: '0.7em'} }
]
}));
},
updateComponent: function(cmp) {
_mainDetailsCardContent.removeAll();
_mainDetailsCardContent.update('');
_mainDetailsCardContent.add(cmp);
_mainDetailsCardContent.doLayout();
},
items: [
// removed
],
dockedItems: [
_mainDetailsToolbar // after hiding it, _mainDetailsCard does not resize after calling doLayout() nor doComponentLayout()
]
});
Thanks,
Aleksandar