[Webkit-unassigned] [Bug 278652] New: [GTK] keydown/up gives outdated modifier state

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Aug 26 08:17:11 PDT 2024


https://bugs.webkit.org/show_bug.cgi?id=278652

            Bug ID: 278652
           Summary: [GTK] keydown/up gives outdated modifier state
           Product: WebKit
           Version: WebKit Local Build
          Hardware: Unspecified
                OS: Unspecified
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: WebKitGTK
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: rpsalmi at gmail.com
                CC: bugs-noreply at webkitgtk.org

Created attachment 472297

  --> https://bugs.webkit.org/attachment.cgi?id=472297&action=review

Example HTML demonstrating the issue

Ubuntu 22.04.4
WebKitGTK 2.44.2-0ubuntu0.22.04.1 or local build @ https://commits.webkit.org/281240@main

Example HTML (attached):

<script>
    window.addEventListener("keydown", (e) => {
        document.body.innerHTML = `keydown ${e.ctrlKey} ${e.altKey} ${e.shiftKey}`;
    });
    window.addEventListener("keyup", (e) => {
        document.body.innerHTML = `keyup ${e.ctrlKey} ${e.altKey} ${e.shiftKey}`;
    });
</script>


Press one of the modifier keys down and up, and observe the text.

Actual behavior on GTK4:

1. Press Ctrl down
2. Text is "keydown false false false"
3. Release Ctrl
4. Text is "keyup true false false"

Actual behavior on GTK3:

1. Press Ctrl down
2. Text is "keydown true false false"
3. Release Ctrl
4. Text is "keyup true false false"

Expected behavior:

1. Press Ctrl down
2. Text is "keydown true false false"
3. Release Ctrl
4. Text is "keyup false false false"

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20240826/18d4c198/attachment.htm>


More information about the webkit-unassigned mailing list