[PR #15673] Replace IInputEvent with INPUT_RECORD #30699

Open
opened 2026-01-31 09:42:26 +00:00 by claunia · 0 comments
Owner

Original Pull Request: https://github.com/microsoft/terminal/pull/15673

State: closed
Merged: Yes


IInputEvent makes adding Unicode support to InputBuffer more
difficult than necessary as the abstract class makes downcasting
as well as copying quite verbose. I found that using INPUT_RECORDs
directly leads to a significantly simplified implementation.

In addition, this commit fixes at least one bug: The previous approach
to detect the null key via DoActiveModifierKeysMatch didn't work.
As it compared the modifier keys as a bitset with == it failed to
match whenever the numpad key was set, which it usually is.

Validation Steps Performed

  • Unit and feature tests are
**Original Pull Request:** https://github.com/microsoft/terminal/pull/15673 **State:** closed **Merged:** Yes --- `IInputEvent` makes adding Unicode support to `InputBuffer` more difficult than necessary as the abstract class makes downcasting as well as copying quite verbose. I found that using `INPUT_RECORD`s directly leads to a significantly simplified implementation. In addition, this commit fixes at least one bug: The previous approach to detect the null key via `DoActiveModifierKeysMatch` didn't work. As it compared the modifier keys as a bitset with `==` it failed to match whenever the numpad key was set, which it usually is. ## Validation Steps Performed * Unit and feature tests are ✅
claunia added the pull-request label 2026-01-31 09:42:26 +00:00
Sign in to join this conversation.
No Label pull-request
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#30699