fix show issue in IE 6. "olddisplay" is sometimes undefined and IE 6 does not like setting style.display to undefined. also second for loop was mistakenly nested within the first for loop.
This commit is contained in:
parent
f93df73a76
commit
72cf42bcbd
1 changed files with 5 additions and 5 deletions
10
src/fx.js
10
src/fx.js
|
@ -46,12 +46,12 @@ jQuery.fn.extend({
|
|||
|
||||
jQuery.data(this[i], "olddisplay", display);
|
||||
}
|
||||
}
|
||||
|
||||
// Set the display of the elements in a second loop
|
||||
// to avoid the constant reflow
|
||||
for ( var i = 0, l = this.length; i < l; i++ ){
|
||||
this[i].style.display = jQuery.data(this[i], "olddisplay");
|
||||
}
|
||||
// Set the display of the elements in a second loop
|
||||
// to avoid the constant reflow
|
||||
for ( var i = 0, l = this.length; i < l; i++ ){
|
||||
this[i].style.display = jQuery.data(this[i], "olddisplay") || "";
|
||||
}
|
||||
|
||||
return this;
|
||||
|
|
Loading…
Reference in a new issue