View Full Version : [CLOSED-188] Adding formpanel to panel ofter the panel has been created and rendered.

19 Jun 2010, 3:31 PM
First of all.. this stuff is so cool!

First off all i'm setting up my basic stuff for the webapp with this code (like in the example of kitchensink)

Ext.ns('wsApp', 'Ext.ws');

Ext.ws.UniversalUI = Ext.extend(Ext.Panel, {
fullscreen: true,
layout: 'card',
initComponent: function(){

wsApp.app = {
fnInit: function(){
this.ui = new Ext.ws.UniversalUI();

onReady: function(){

But... I'm running into a little problem. I have created a Panel called panelLogin which I render to the screen with wsApp.app.ui.setCard. After rendering I want to add a FormPanel called formpanelLogin:


The log returns true for the formpanelLogin being rendered.. but it isnt vissible.

I attached the code as an attachement. Any help would be cool!

23 Jul 2010, 3:06 AM
Fit layout panels need to have dimension in order to 'fit' an item inside them, so you would need to give panelLogin a height in order for anything to be displayed in it (fit panels should have only 1 item, although they can have multiple dockedItems).

Having said that, I do think you found a bug. In the below example, the auto layout panel has it's button replaced correctly, while the fit layout panel has it's button removed, but the new one is not rendered.

Ext.setup({ onReady: function () {
var button =
xtype: 'button',
text: 'Click me',
handler: function () {
var panel = this.ownerCt;
panel.add({ xtype: 'button', text: 'Button2' });
new Ext.Panel({ fullscreen: true,
items: [{ items: [button] },
items: [button],
layout: 'fit',
height: 50

Jamie Avins
30 Jul 2010, 10:26 AM
I've opened the issue in trac, thank you for the report.

14 Aug 2010, 5:22 AM
I'm not able to reproduce this, using the latest build, so I think we can close this off.