ladybird/UI
Timothy Flynn bf75f52ce0 UI/AppKit: Store the original key-down event for WebContent processing
When a shortcut is an alternative key, macOS first fires a key event for
the primary key. Then if it is not handled, it fires an event for the
alternative key. For example, we see these two events in a row when we
press cmd and =/+:

    NSEvent: type=KeyDown flags=0x100108 chars="=" keyCode=25
    NSEvent: type=KeyDown flags=0x100108 chars="+" keyCode=24

For dead key processing, we don't handle these events right away. By the
time we get to doCommandBySelector, when we call [NSApp currentEvent],
we see the following events:

    NSEvent: type=KeyDown flags=0x100108 chars="=" keyCode=24
    NSEvent: type=AppDefined flags=0

The AppDefined event is internally posted by our event loop. So it seems
we cannot rely on currentEvent being the key-down event we are looking
for.

Instead, we can store the key-down event that we last saw.
2025-11-27 13:51:45 +00:00
..
Android LibCore: Remove unused NotifierActivationEvent fd() and type() methods 2025-11-22 09:47:25 +01:00
AppKit UI/AppKit: Store the original key-down event for WebContent processing 2025-11-27 13:51:45 +00:00
cmake LibWebView+UI: Remove some now-superfluous debug menu items 2025-11-12 09:06:21 -05:00
Icons Everywhere: Move the Ladybird folder to UI 2024-11-10 12:50:45 +01:00
Qt LibWebView+UI: Pass RequestServerOptions to Application implementations 2025-11-20 09:33:49 +01:00
.gitignore Everywhere: Move the Ladybird folder to UI 2024-11-10 12:50:45 +01:00
CMakeLists.txt CMake: Output helper process binaries to bin instead of libexec 2025-10-29 21:07:52 -06:00
Info.plist Everywhere: Move the Ladybird folder to UI 2024-11-10 12:50:45 +01:00