PDA

View Full Version : TabPanel not rendering when using regApplication



StuartAshworth
19 Mar 2011, 1:01 PM
Hi

Was wondering if anyone can shed any light on this problem that I'm having? It may be that I have missed something when setting up my MVC application but maybe not...

I've replicated the problem in the Tabs example that can be found in the product download which I'll try to explain.

The original example looks like this...

Original Example Demo (http://www.stuartashworth.com/SenchaTouch/Plugins%20&%20Extensions/tabs-setup/)



Ext.setup({
name: 'MyApp',

onReady: function() {

new Ext.TabPanel({
fullscreen: true,
type: 'dark',
sortable: true,
items: [{
title: 'Tab 1',
html: '1',
cls: 'card1'
}, {
title: 'Tab 2',
html: '2',
cls: 'card2'
}, {
title: 'Tab 3',
html: '3',
cls: 'card3'
}]
});
}
});


If I alter this example to use the regApplication syntax which, i think, doesn't do much more than register some namespaces and other 'admin' tasks, the tab panel's items aren't rendered - only the tab headers are.

RegApplication Example Demo (http://www.stuartashworth.com/SenchaTouch/Plugins%20&%20Extensions/tabs-reg/)




Ext.regApplication({
name: 'MyApp',

launch: function() {

new Ext.TabPanel({
fullscreen: true,
type: 'dark',
sortable: true,
items: [{
title: 'Tab 1',
html: '1',
cls: 'card1'
}, {
title: 'Tab 2',
html: '2',
cls: 'card2'
}, {
title: 'Tab 3',
html: '3',
cls: 'card3'
}]
});
}
});



A similar effect can be seen with a simple Panel with a card layout that I have within my application so I don't think it's exclusive to TabPanels.

Does anyone know if I'm missing something when moving to the regApplication (and MVC) approach or if this in fact a more serious issue with the framework.

Cheers
Stuart

StuartAshworth
19 Mar 2011, 1:13 PM
OK, so been investigating more and have come across this thread (http://www.sencha.com/forum/showthread.php?114688-FIXED-508-0.99-Fullscreen-does-not-work-with-Ext.regApplication%28%29/page2)which seems to describe what I'm seeing so I think it has been addressed by Jacky.

Sorry for the time waste!