To get around this, I use my own event normalization that seems to work across all browsers and only normalizes what I need in any given project, for example:
var e = e || window.event;
var fixed_e = {};
fixed_e.pageX = document.all ? e.clientX + truebody.scrollLeft : e.pageX;
fixed_e.pageY = document.all ? e.clientY + truebody.scrollTop : e.pageY;
fixed_e.X = (e.offsetX ? e.offsetX : e.layerX) || 0;
fixed_e.Y = (e.offsetY ? e.offsetY : e.layerY) || 0;
fixed_e.source = e.target ? e.target : e.srcElement;
Another problem with jQuery events is unbinding is tricky.. I don't like how I have to have a reference to the bound function laying around somewhere so that I can unbind it. In my event system, adding an event returns a handle, which allows you to simple call ".detach()" or ".attach()" or ".trigger()" .. it's worked out very well for me.As per the remove, I added a simple extension that's worked perfectly:
$.fn.rm = function(){
return this.each(
function(){
if (!this.parentNode) return; //already removed.
this.parentNode.removeChild(this);
}
);
}