Side navigation
Ticket #3125: enterleave_patch.js
File enterleave_patch.js, 0.5 KB (added by mike.helgeson, July 03, 2008 05:16PM UTC)
jQuery.each({ mouseover: 'mouseenter', mouseout: 'mouseleave' }, function( orig, fix ){
var ev = jQuery.event.special[ fix ] = {
setup: function(){
return jQuery.browser.msie ? false : jQuery( this ).bind( orig, ev.handler );
},
teardown: function(){
return jQuery.browser.msie ? false : jQuery( this ).unbind( orig, ev.handler );
},
handler: function( event ){
event.type = fix;
return withinElement( event, this ) || jQuery.event.handle.apply( this, arguments );
}
};
});
Download in other formats:
Original Format
File enterleave_patch.js, 0.5 KB (added by mike.helgeson, July 03, 2008 05:16PM UTC)
jQuery.each({ mouseover: 'mouseenter', mouseout: 'mouseleave' }, function( orig, fix ){
var ev = jQuery.event.special[ fix ] = {
setup: function(){
return jQuery.browser.msie ? false : jQuery( this ).bind( orig, ev.handler );
},
teardown: function(){
return jQuery.browser.msie ? false : jQuery( this ).unbind( orig, ev.handler );
},
handler: function( event ){
event.type = fix;
return withinElement( event, this ) || jQuery.event.handle.apply( this, arguments );
}
};
});