jquery event: closes #3843. Some events' timeStamp are wrong on Firefox, we don't...
authorAriel Flesler <aflesler@gmail.com>
Mon, 19 Jan 2009 22:20:25 +0000 (22:20 +0000)
committerAriel Flesler <aflesler@gmail.com>
Mon, 19 Jan 2009 22:20:25 +0000 (22:20 +0000)
src/event.js

index e46e108..5ae4bad 100644 (file)
@@ -377,13 +377,13 @@ jQuery.Event = function( src ){
        if( src && src.type ){
                this.originalEvent = src;
                this.type = src.type;
-               this.timeStamp = src.timeStamp;
        // Event type
        }else
                this.type = src;
 
-       if( !this.timeStamp )
-               this.timeStamp = now();
+       // timeStamp is buggy for some events on Firefox(#3843)
+       // So we won't rely on the native value
+       this.timeStamp = now();
        
        // Mark it as fixed
        this[expando] = true;