Open Bug 674696 Opened 13 years ago Updated 2 years ago

Please remove proprietary extensions to Event or standardize them

Categories

(Core :: DOM: Events, task, P3)

task

Tracking

()

People

(Reporter: annevk, Unassigned)

References

(Depends on 1 open bug, Blocks 1 open bug)

Details

(Keywords: site-compat)

Everything at https://searchfox.org/mozilla-central/source/dom/webidl/Event.webidl#64-88 really ought not to exist at all.
Component: DOM: Core & HTML → DOM: Events
QA Contact: general → events
https://bugs.webkit.org/show_bug.cgi?id=65283 is the WebKit bug.
originalTarget and explicitOriginalTarget are necessary for XBL 1 - they expose shadow content event targets.
We can maybe remove getPreventDefault once we implement defaultPrevented, unless sites are sniffing and relying on it, in which case it probably needs to be standardized as an alize for defaultPrevented.

The prevent* stuff has been deprecated for a while and I suspect can go.

The original target stuff is indeed needed for XBL1, but I wonder whether we can expose it to system-principal code only like we do baseURIObject and nodePrincipal.  That ought to be good enough for our uses.

The various constants might need standandizing.  Not sure.
(In reply to comment #4)
> We can maybe remove getPreventDefault once we implement defaultPrevented,

We already do, bug 656954.
OS: Mac OS X → All
Hardware: x86 → All
Version: unspecified → Trunk
The four *_MASK constants we should try to figure out whether anyone uses in the wild; I'm not quite sure how to do that.  We can scrub them from our code pretty straightforwardly.  It's not clear to me what exactly in-the-wild uses would look like, since you can't do anything with these constants directly.

That leaves originalTarget and explicitOriginalTarget.  We could pretty easily restrict these to chrome-or-xbl, I expect.  The question is whether anyone uses them on the web.  I guess we could try adding telemetry for non-chrome-or-xbl uses...
Priority: -- → P3
Keywords: site-compat
Type: defect → task
Depends on: 662335
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.