New issue
Advanced search Search tips

Issue 692703 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner: ----
Closed: Oct 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug

Blocking:
issue 674593


Show other hotlists

Hotlists containing this issue:
Non-Standard-IDL


Sign in to add a comment

Standardize (or remove) KeyboardEvent#initKeyboardEvent (and its arguments)

Project Member Reported by lunalu@chromium.org, Feb 15 2017

Issue description

It has been deprecated in the spec, https://w3c.github.io/uievents/#idl-interface-KeyboardEvent-initializers

We should match the spec by removing this API.
 

Comment 1 by tkent@chromium.org, Feb 17 2017

Components: -Blink>DOM>Events Blink>Input
Cc: dtapu...@chromium.org foolip@chromium.org
Labels: Hotlist-Input-Dev Hotlist-Interop
Status: Available (was: Untriaged)
Usage is 0.0406% I wonder if we can start thinking about deprecating this since it was never implemented in FireFox.

Comment 3 by foolip@chromium.org, Feb 23 2017

That is fairly high usage from something seemingly obscure and not interoperable. Understanding the typical usage here would help, in particular are those 0.0406% broken in Firefox, or is there fallback code? In the worst case, there's some widely used code that uses UA sniffing to only try initKeyboardEvent in non-Gecko and something else in Gecko.

It looks like there are only 1898 hits in httparchive, which is a small number given the usage, so possibly usage is concentrated in some fairly large site behind a login that isn't captured in httparchive.

https://storage.googleapis.com/blink-httparchive-export/initKeyboardEvent.json is an export of those hits, and https://github.com/foolip/unhar/blob/master/unjson can be used to split it into individual files for detailed analysis. (I haven't tried it yet, so it may break with this input.)

Comment 4 by foolip@chromium.org, Feb 23 2017

Summary: Standardize (or remove) KeyboardEvent#initKeyboardEvent (and its arguments) (was: Deprecate KeyboardEvent#initKeyboardEvent)
AFAIK works in Firefox nightly:
> event = new KeyboardEvent("onkeydown", null);
onkeydown { target: null, key: "", charCode: 0, keyCode: 0 }
> event.initKeyboardEvent("onkeyup");
undefined
> event
onkeyup { target: null, key: "", charCode: 0, keyCode: 0 }

Comment 6 by phistuck@gmail.com, Sep 19 2017

It should be "keydown" and "keyup", not "onkeydown" and "onkeyup" (this is not Internet Explorer 8 and earlier ;)).
Status: Fixed (was: Available)

Sign in to add a comment