-
17 Apr 2011 3:41 AM #1
Ext.tab.TabPanel - performance when adding or hiding tabs Extjs3 vs. extjs4
Ext.tab.TabPanel - performance when adding or hiding tabs Extjs3 vs. extjs4
Hello,
this is probably not a real bug but more a performance isue.
I have GUI where tabs are loaded after i select a certain node in tree menu.
Tabs (configs) are loaded dinamically via ajax request.
I have a lot of tabs 20 - 30.
I noticed that hiding a tab in EXT JS 4 takes more than 5 time longer than hiding a tab in EXT JS 3.
In ExtJS 4 I hide tabs like this:
panel.getTabBar().items.each(function(t){
t.hide(); //i also tryed t.setVisible(false)
});
notice: it takes 0.6 SEC to hide 20 tabs
In ExtJS 3 I hide tabs like this:
panel.items.each(function(t){
panel.hideTabStripItem(t.id);
});
notice: it takes 0.04 SEC to hide 20 tabs
When i create tabs (with panel.add()) it takes:
- 0.6 SEC for 20 tabs with ExtJS 4
- 0.12 SEC for 20 tabs with ExtJS 3
notice: deferredRender is ON in both cases, config object is the same in both cases and is simple like this {title: 'tab name', xtype: 'container'}
0.06 SEC is not a long time, but i load tabs when i select certain node in TreePanel menu, and if i change selections fast, GUI feels very slow - non responsive. In ExtJS 3 it was really fast, you coudn't even tell it was loaded dinamically.
Is there a way to make this work faster? I tryed several things including suspendEvents + calling doLaout at the end, but i really didn't know what i was doing so it wasn't successfull :/
BTW i really like EXT JS and i love you guys!
-
17 Apr 2011 7:17 AM #2
Ok now i got it to work almost as faster.
Before hiding and adding logic i call:
panel.getTabBar().suspendLayout = true;
panel.suspendLayout = true;
and then ater adding part i call:
panel.getTabBar().suspendLayout = false;
panel.suspendLayout = false;
panel.getTabBar().doLayout();
Now it is "just" 100% slower than ExtJS 3.
Thank you for reporting this bug. We will make it our priority to review this report.
Similar Threads
-
Dynamic form from Extjs3 to Extjs4
By parsbin in forum Ext: DiscussionReplies: 3Last Post: 12 Apr 2011, 3:26 AM -
ExtJs3 and ExtJs4 in One App
By Darren Martz in forum Ext: DiscussionReplies: 3Last Post: 7 Apr 2011, 8:48 AM -
ExtJs3 to ExtJs4 Migration
By same66 in forum Ext: DiscussionReplies: 4Last Post: 1 Mar 2011, 5:18 PM -
[CLOSED]ExtJs3 and ExtJs4-Sandbox
By jjozeh in forum Ext:BugsReplies: 1Last Post: 25 Feb 2011, 4:12 PM -
Do we still get a license for ExtJS4 if we purchased ExtJS3 before January 1st?
By darren in forum Community DiscussionReplies: 2Last Post: 4 Feb 2011, 3:50 AM


Reply With Quote