Skip to content

Hotkeys not working after triggering print dialog #509

@trygve-aaberge-adsk

Description

@trygve-aaberge-adsk

If you trigger the print dialog from a shortcut, the keyup listener for that shortcut will never be triggered. That causes all other shortcuts to stop working because it thinks the key pressed for the print dialog is still being held down.

This happens at least in Chrome 133.0.6943.35. In Firefox 134.0.2 it sends the window focus event when the print dialog is dismissed, which makes it reset the key state, so it doesn't happen there.

Here's some code to reproduce it: https://codepen.io/trygveaa/pen/gbOPwrv

Press a and see that the press and release handlers are working. Then press ctrl+p and you will get the print dialog. Close it and press a again and see that no handlers are called.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions