PDA

View Full Version : [INFOREQ-1082] Regression in accordion layout from 3.0 to 3.2



seizmo
28 Jun 2010, 12:24 PM
Ext version tested:

Ext 3.2.1 release


Adapter used:

ext


css used:

only default ext-all.css


Browser versions tested against:

Chrome 6.0.44
FF 3.6.4 (firebug 1.5.4 installed)


Operating System:

Win 7


Description:

Upgrading from 3.0 to 3.2 the accordion layout in a sidebar which lays out three treepanels does not work anymore. Instead of collapsing the inactive panel(s), the height does not change, only the content disappears. My suspicion is that the height calculation is somehow messed up. The problem is, that the sidebar is part of a relatively involved layout, I can only post parts of it. It is the "west" panel of a border layout.

Firebug does not report any errors.


Test Case:



XX.panel.MainPanel = Ext.extend(Ext.Panel, {
initComponent: function() {
Ext.apply(this, {
layout: 'border',
items: [
new Ext.Panel({
title: 'Sidebar',
layout:'accordion',
region: 'west',
split: true,
width: 280,
collapsible: true,
animCollapse: false,
items: [{
xtype: 'XX.panel.PortfolioTreePanel'
},{
xtype: 'XX.panel.SubscribedTreePanel'
},{
xtype: 'XX.panel.TaskTreePanel'
}]
}),{
xtype: 'XX.panel.ObjektTabPanel',
region: 'center',
split: true
}
]
});
XX.panel.MainPanel.superclass.initComponent.call(this);
}
});
Ext.reg('XX.panel.MainPanel', XX.panel.MainPanel);

XX.panel.PortfolioTreePanel = Ext.extend(Ext.tree.TreePanel, {
initComponent: function() {
var ctx = this.getAppContext();
Ext.applyIf(this, {
title: 'Objekte',
id: 's-portfolio-tree',
root: new Ext.tree.AsyncTreeNode({
text: 'Kunden',
id: 'r',
expanded: true
}),
loader: new XX.util.PortfolioTreeLoader({
url: ctx.getUrl('portfolioTreeItems')
}),
tbar: this.createSearchBar()
});

Ext.apply(this, {
animate: false,
rootVisible:false,
autoScroll: true
});

XX.panel.PortfolioTreePanel.superclass.initComponent.call(this);


this.on('dblclick', this.onDblClick, this);
this.on('contextmenu', this.onContextMenu, this);
this.createContextMenus();
}
// [...]
});
Ext.reg('XX.panel.PortfolioTreePanel', XX.panel.PortfolioTreePanel);



The result that was expected:
21159

The result that occurs instead:
2115721158

evant
15 Sep 2010, 9:24 PM
I'm not able to reproduce this using your sample code in 3.2, 3.2.1 or 3.3.

Can you please post a drop in test case that demonstrates the issue?



Ext.ns('XX.panel');
XX.panel.MainPanel = Ext.extend(Ext.Panel, {
initComponent: function() {
Ext.apply(this, {
layout: 'border',
items: [
new Ext.Panel({
title: 'Sidebar',
layout:'accordion',
region: 'west',
split: true,
width: 280,
collapsible: true,
animCollapse: false,
items: [{
xtype: 'XX.panel.PortfolioTreePanel'
},{
xtype: 'panel'
},{
xtype: 'panel'
}]
}),{
xtype: 'panel',
region: 'center',
split: true
}
]
});
XX.panel.MainPanel.superclass.initComponent.call(this);
}
});
Ext.reg('XX.panel.MainPanel', XX.panel.MainPanel);

XX.panel.PortfolioTreePanel = Ext.extend(Ext.tree.TreePanel, {
initComponent: function() {
Ext.applyIf(this, {
title: 'Objekte',
id: 's-portfolio-tree',
root: new Ext.tree.AsyncTreeNode({
text: 'Kunden',
id: 'r',
expanded: true
})
});

Ext.apply(this, {
animate: false,
rootVisible:false,
autoScroll: true
});

XX.panel.PortfolioTreePanel.superclass.initComponent.call(this);
}
});
Ext.reg('XX.panel.PortfolioTreePanel', XX.panel.PortfolioTreePanel);

Ext.onReady(function(){
new Ext.Viewport({
layout: 'fit',
items: new XX.panel.MainPanel()
});
});