NEW 30397
Meta + key should not fire keypress event
https://bugs.webkit.org/show_bug.cgi?id=30397
Summary Meta + key should not fire keypress event
Erik Arvidsson
Reported 2009-10-15 10:48:47 PDT
The general rule is that key(s) should only fire keypress events if they generate content. Also, we are trying to match IE which dos not fire keypress events for ctrl + key (we should still fire repeating keydown events)
Attachments
Tony Chang
Comment 1 2010-02-14 20:17:51 PST
(In reply to comment #0) > The general rule is that key(s) should only fire keypress events if they > generate content. Also, we are trying to match IE which dos not fire keypress > events for ctrl + key (we should still fire repeating keydown events) By meta, do you mean command on mac and the Windows key on win/linux? Or do you mean the alt/option key on mac? Using the test case on bug 28409 https://bug-28409-attachments.webkit.org/attachment.cgi?id=34993 , in Safari 4.0.4 on mac, I see a keypress fired in all cases (ctrl, alt, or command). On Chrome on mac, I see a keypress fired for only ctrl and alt (no keypress event for command). Is this bug Safari specific?
Karl Dubost
Comment 2 2024-01-18 02:48:22 PST
from https://www.w3.org/TR/uievents/#keypress: > If supported by a user agent, this event MUST be dispatched when a key is pressed down, if and only if that key normally produces a character value. The keypress event type is device dependent and relies on the capabilities of the input devices and how they are mapped in the operating system.
Radar WebKit Bug Importer
Comment 3 2024-01-18 02:48:30 PST
Arvin Sevilla
Comment 4 2024-01-18 07:20:08 PST
*** Bug 208088 has been marked as a duplicate of this bug. ***
Abrar Rahman Protyasha
Comment 5 2024-01-23 14:54:24 PST
(In reply to Karl Dubost from comment #2) > from https://www.w3.org/TR/uievents/#keypress: > > > If supported by a user agent, this event MUST be dispatched when a key is pressed down, if and only if that key normally produces a character value. The keypress event type is device dependent and relies on the capabilities of the input devices and how they are mapped in the operating system. "that key normally produces a character value" is a little vague because the `keypress` events are fired for, say, `V`, and not `⌘`, when a user types `⌘V` to paste something. At any rate, it seems OK for us to align our behavior with the other browser engines here and _not_ dispatch `keypress` if there is a modifier active.
Abrar Rahman Protyasha
Comment 6 2024-02-08 15:32:47 PST
*** Bug 185971 has been marked as a duplicate of this bug. ***
Note You need to log in before you can comment on or make changes to this bug.