Open
Bug 662335
Opened 13 years ago
Updated 2 years ago
Remove support for event.originalTarget and event.explicitOriginalTarget on DOM events
Categories
(Core :: DOM: Events, task, P3)
Core
DOM: Events
Tracking
()
NEW
People
(Reporter: bruant.d, Unassigned)
References
(Blocks 2 open bugs)
Details
(Keywords: dev-doc-needed, site-compat)
These two properties are documented here: https://developer.mozilla.org/en/DOM/event/Comparison_of_Event_Targets However, I have never seen them being used, there is no support in other browser I'd be aware of and current standard event properties (target & currentTarget) seems to enough to cover people use cases.
Comment 1•13 years ago
|
||
> However, I have never seen them being used http://mxr.mozilla.org/mozilla-central/search?string=originalTarget&find=.js&findi=&filter=^[^\0]*%24&hitlimit=&tree=mozilla-central These are needed to deal with XBL-bound anonymous content. Browsers that don't implement XBL don't need these properties, of course. We could moz-prefix these, I guess, but that would be a pretty significant change.
Comment 2•13 years ago
|
||
.originalEventTarget is coming from http://www.w3.org/TR/2001/NOTE-xbl-20010223/#anonymous-events-scopes (Not that Gecko's XBL1 implementation is exactly what that W3C note defines)
Reporter | ||
Comment 3•13 years ago
|
||
Ok, changing bug title accordingly. Since these properties aren't part of the DOM Event Spec, then, specifically on DOM events, they should be removed.
Summary: remove support for event.originalTarget and event.explicitOriginalTarget → Remove support for event.originalTarget and event.explicitOriginalTarget on DOM events
Reporter | ||
Comment 5•13 years ago
|
||
(In reply to comment #4) > You seem to have completely misunderstood comment 1 and comment 2.... Maybe? :-s Ok, Hmm... My understanding is that XBL needs these properties, so they shouldn't be removed entirely (and your link to mxr was a proof that they are used in Mozilla codebase) However, the DOM event spec doesn't define these properties (that's why I filed this bug under the "DOM:Event" component). But maybe I misunderstand what XBL is. From what I've read on the spec, this isn't part of any DOM&friends spec. I guess I should restart by asking the question: is XBL something that web developers use? want to use? Is it relevant to provide XBL features to web developers? And if not, should it be hidden to them? I don't know if bug 343032 and bug 517007 are still up-to-date, but if they are, it would be some indication that this feature isn't really safe to expose to web developers. Worst case, it could turn into an obscure security issue.
Comment 6•13 years ago
|
||
> is XBL something that web developers use? Not anymore, but they used to. > want to use? Yes. > Is it relevant to provide XBL features to web developers? The question is how to tell apart "web developers" and "extension developers"; they're both programming to the same DOM event model.
Updated•7 years ago
|
Reporter | ||
Updated•6 years ago
|
Depends on: war-on-xbl
Updated•6 years ago
|
Priority: -- → P3
Updated•5 years ago
|
Blocks: remove-xbl-implementation
Updated•5 years ago
|
Type: defect → task
Updated•5 years ago
|
No longer depends on: war-on-xbl
Comment 10•3 years ago
|
||
I have a usecase for explicitOriginalTarget:
I like to prevent links from navigating if i press inside a contenteditable-element that is inside that link.
The same also if the contenteditable-element has focus and i press enter (also a click event is fired)
But in Firefox, to find out that I pressed enter inside a contenteditable element, i need explicitOriginalTarget
Probably, like in chrome, the contenteditable-element should not fire click in that case.
Updated•2 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•