#7534 closed bug (wontfix)
event.originalTarget no longer is passed to an event handler listening element on firefox 3.5+
Reported by: | Owned by: | ||
---|---|---|---|
Priority: | blocker | Milestone: | 1.5 |
Component: | event | Version: | 1.5 |
Keywords: | regression | Cc: | |
Blocked by: | Blocking: |
Description
When listening to events, the originalTarget property is no longer passed.
Expected; 1) Using jQuery attach an onchange event to an input element and log e.originalTarget(example below) 2) Enter content into input element to fire the change event 3) The originalTarget is reported as the originalTarget
Actual; 1) Using jQuery attach an onchange event to an input element and log e.originalTarget(example below) 2) Enter content into input element to fire the change event 3) The originalTarget is reported as undefined
$('input').change(function(e) { console.log('element', e.originalTarget); });
This worked in jQuery 1.4.2. It also affects other event handlers attached to any.
- The version(s) of jQuery affected; 1.4.4
- The browser (or browsers) that you are able to reproduce the bug in, including version numbers. FF 3.6.12 + 4.0b7
- The operating system (or operating systems) you experienced the bug on. Mac OS 10.6, Snow Leopard
Change History (7)
comment:1 Changed 13 years ago by
comment:2 Changed 13 years ago by
Component: | unfiled → event |
---|---|
Keywords: | regression needsreview added |
Priority: | undecided → blocker |
Status: | new → open |
Confirmed;
comment:3 Changed 13 years ago by
Milestone: | 1.5 → 1.4.5 |
---|
comment:4 Changed 13 years ago by
Resolution: | → wontfix |
---|---|
Status: | open → closed |
It was this commit for #2814:
https://github.com/jquery/jquery/commit/69994211b078b8711220eaef33cc1bd6a63c5772
That jQuery.event.fix method is a bottleneck for event delivery so we should keep it as short as possible and not include browser-specific properties.
You can still get to this Mozilla-specific property via event.originalEvent.originalTarget.
comment:5 Changed 13 years ago by
Keywords: | needsreview removed |
---|
comment:6 Changed 13 years ago by
Version: | 1.4.4 → 1.5 |
---|
There wasn't a 1.4.5 release, was actually 1.5.
comment:7 Changed 13 years ago by
Milestone: | 1.4.5 → 1.5 |
---|
There was no 1.4.5 release, was actually 1.5.
JSfiddle test case; http://jsfiddle.net/X8a9b/1/