PDA

View Full Version : Ext.ux.grid.BufferView Slow in IE6



qhas
29 Sep 2009, 12:50 PM
I've searched the form and found this (http://www.extjs.com/forum/showthread.php?t=77382) thread, but not much else.

I have 2600+ rows, and when scrolling in the grid these are my resutls...
Chrome: fast
FireFox3: fast
IE8: fast
IE6: Painfully slow

The doClean is slow in IE6. More specifically (i think), the


//The "rows[i].innerHTML" in
if ((i < vr.first || i > vr.last) && rows[i].innerHTML) {piece of code.

The doClean function currently looks like this:


doClean: function(){
if (this.getVisibleRowCount() > 0) {
var vr = this.getVisibleRows();
vr.first -= this.cacheSize;
vr.last += this.cacheSize;

var i = 0, rows = this.getRows();
// if first is less than 0, all rows have been rendered
// so lets clean the end...
if(vr.first <= 0){
i = vr.last + 1;
}
for(var len = this.ds.getCount(); i < len; i++){
// if current row is outside of first and last and
// has content, update the innerHTML to nothing
if ((i < vr.first || i > vr.last) && rows[i].innerHTML) {
rows[i].innerHTML = '';
}
}
}
},
I've tried many things to get this code to run faster. My last attempt is this.


doClean: function(){
if (this.getVisibleRowCount() > 0) {
var vr = this.getVisibleRows();
vr.first -= this.cacheSize;
vr.last += this.cacheSize;
var i = 0, rows = this.getRows();
if(vr.first <= 0){
i = vr.last + 1;
}

for(var len = this.ds.getCount(); i < len; i++){
if ((i < vr.first || i > vr.last) ) {
var child = Ext.fly(rows[i]).child('table');

if(child){
child.remove();
}

}//eo if
}//eo for
}//eo if
},

I thinkit's faster, but not fast enough.
Any Ideas?
Thanks.

1 Oct 2009, 8:53 AM
The DOM manipulation is extremely slow in IE6.