windows: Fix keystroke (#30753)

Closes #22656

Part of #29144, this PR completely rewrites the key handling logic on
Windows, making it much more consistent with how things work on macOS.
However, one remaining issue is that on Windows, we should be using
`Ctrl+Shift+4` instead of `Ctrl+$`. That part is expected to be
addressed in #29144.


Release Notes:

- N/A
58ba833792张小白 committed on 5/15/2025, 12:49:06 PM· committed by GitHubparentf021b40
4 files changedLine totals unavailable