Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

keydown event should have an attribute which is set to true when it's followed by a beforeinput or keypress event? #179

Open
masayuki-nakano opened this issue Feb 3, 2018 · 0 comments

Comments

@masayuki-nakano
Copy link

Although I suggested same or similar thing already. However, I meet this issue again because I'm working on preparing to stop dispatching keypress events for non-printable keys on Gecko.

When I need to handle both non-printable keys and printable keys and I shouldn't kill following keypress event for compatibility, I need to handle keydown event only when it won't be followed by keypress event but otherwise, keydown event is the last chance to handle it.

This is not necessary for web apps, probably. However, when implementing default action (including implemented by extensions), this is really important. In this purpose, I need to distinguish if the key or key combination is printable (i.e., followed by keypress events).

So, I want KeyboardEvent.isPrintable, KeyboardEvent.isInputtingText or something as boolean attribute. How do you thing, @garykac?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants