Skip to content

Instantly share code, notes, and snippets.

@FiNGAHOLiC
Created December 17, 2012 05:14
Show Gist options
  • Save FiNGAHOLiC/4315912 to your computer and use it in GitHub Desktop.
Save FiNGAHOLiC/4315912 to your computer and use it in GitHub Desktop.
Override jQuery fadeIn & fadeOut function for FUCK'IN MSIE.
// override jquery fadeIn
$.fn._fadeIn = $.fn.fadeIn;
$.fn.fadeIn = function(){
if(!$.browser.ie){
return $.fn._fadeIn.apply(this, arguments);
}else{
$.fn.show.apply(this);
for(var i = 0, l = arguments.length; i < l; i++){
$.isFunction(arguments[i]) && arguments[i]();
};
};
};
// override jquery fadeOut
$.fn._fadeOut = $.fn.fadeOut;
$.fn.fadeOut = function(){
if(!$.browser.ie){
return $.fn._fadeOut.apply(this, arguments);
}else{
$.fn.hide.apply(this);
for(var i = 0, l = arguments.length; i < l; i++){
$.isFunction(arguments[i]) && arguments[i]();
};
};
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment