PDA

View Full Version : [CLOSED][3.0Rev4569] Complex panel imbrication and menu does not render on FF3



raphael.franchet
26 Jun 2009, 12:27 AM
Ext version tested:

Ext 3.0Rev4569 not working
Ext 3.0RC2 was working
Browser versions tested against:


FF3 not working on rev4569 but working on RC2
IE7 working on both
Operating System:

WinXP Pro
Description:

I think a regression has been made between the RC2 and the recent rev 4569 on FF3 but not on IE7.
I'm creating a menu item that displays a panel (it is a very simple code) with subpanels.
The subpanel displays their headers but not their body on FF3 rev 4569.

Test Case:






<?xmlversion="1.0"encoding="UTF-8"?>

<!DOCTYPEhtmlPUBLIC"-//W3C//DTD XHTML 1.0 Strict//EN""http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<htmlxmlns="http://www.w3.org/1999/xhtml">


<head>

<title>Test d'ergonomie avec Ext v3</title>


<!-- EXTJS -->

<!-- CSS -->

<linkrel="stylesheet"type="text/css"href="resources/extjs trunk/css/ext-all.css"/>


<!-- JS -->

<scripttype="text/javascript"src="resources/extjs trunk/js/adapter/ext/ext-base.js"></script>

<scripttype="text/javascript"src="resources/extjs trunk/js/ext-all.js"></script>


<script>

GalleryItem = function(config)
{
GalleryItem.superclass.constructor.call(this, config);
}

Ext.extend (GalleryItem, Ext.menu.BaseItem, {
ctype: 'org.ametys.fluent.menu.GalleryItem',
onRender : function()
{
GalleryItem.superclass.onRender.apply(this, arguments);

this.panelConfig.renderTo = this.container;

new Ext.Panel(this.panelConfig);
}
});
</script>


<scripttype="text/javascript">

function onreadyfunction()
{
new Ext.Button({
text: 'test',
renderTo: 'here',
menu: {
items: [
new GalleryItem
({
panelConfig:
{
items: [
new Ext.Button({
text: 'A classic extjs button'

}),
{
title: 'my gallery item with items',
items: [
new Ext.Button({
text: 'A classic extjs button'

})
]
}
]
}
})
]
}
})
}
Ext.onReady(onreadyfunction);
</script>

</head>


<bodyid="here">

</body>
</html>




Steps to reproduce the problem:


Use the rev 4569 with FF3 and open the menu : there is only one button insteadof two

The result that was expected:


Use the rev 4569 with IE7 and open the menu : two buttons
Use the RC2 with IE7 or FF3 and open the menu : two buttons

The result that occurs instead:


The panels in the panel use in my GalleryItem have their header rendered but not their body.
Replace the items with html works fine.



Debugging already done:


none


Possible fix:


none

evant
26 Jun 2009, 1:08 AM
??? This a code is rather strange and not typical of component/container stuff, I wouldn't classify this as a bug. Regardless, you'll need an explicit doLayout call to get this to work correctly.



GalleryItem = function(config){
GalleryItem.superclass.constructor.call(this, config);
}

Ext.extend(GalleryItem, Ext.menu.BaseItem, {
ctype: 'org.ametys.fluent.menu.GalleryItem',
onRender: function(){
GalleryItem.superclass.onRender.apply(this, arguments);

this.panelConfig.renderTo = this.container;

this.panel = new Ext.Panel(this.panelConfig);
}
});

function onreadyfunction(){
new Ext.Button({
text: 'test',
renderTo: document.body,
menu: {
items: [new GalleryItem({
panelConfig: {
items: [new Ext.Button({
text: 'A classic extjs button'

}), {
title: 'my gallery item with items',
listeners: {
defer: 50,
afterrender: function(c){
//console.log(c.id);
c.doLayout(false, true);
}
},
items: [new Ext.Button({
text: 'A classic extjs button'

})]
}]
}
})]
}
})
}
Ext.onReady(onreadyfunction);


Marking as closed.