Opened 9 years ago
Closed 9 years ago
#8055 closed bug (invalid)
event.originalEvent is undefined when an event triggered manually
Reported by: | NV | Owned by: | NV |
---|---|---|---|
Priority: | low | Milestone: | 1.next |
Component: | event | Version: | 1.4.4 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
Change History (3)
comment:1 Changed 9 years ago by
Owner: | set to NV |
---|---|
Status: | new → pending |
comment:2 Changed 9 years ago by
Status: | pending → new |
---|
The proper link is http://elv1s.ru/files/js/jQuery/originalEvent.html
comment:3 Changed 9 years ago by
Component: | unfiled → event |
---|---|
Priority: | undecided → low |
Resolution: | → invalid |
Status: | new → closed |
Test case ported to jsFiddle.
This isn't a bug.
The Event-object documentation says:
Certain native events may have special properties that can be accessed as properties of the event.originalEvent object.
The trigger() documentation (.focus()
is short for .trigger("focus")
) says:
Although .trigger() simulates an event activation, complete with a synthesized event object, it does not perfectly replicate a naturally-occurring event.
As triggering focus with .focus()
isn't a native event, the originalEvent
property can't available.
My test case also clearly shows that when the focus event is triggered natively you can access the originalEvent
property as documented.
Thanks for submitting a ticket to the jQuery bug tracker. We've checked the link you provided and this is currently not loading (from the looks of it, you may have accidentally posted a local link). If you could kindly repost your reduction on jsFiddle.net we'll be more than happy to evaluate the bug you're experiencing.