-
Notifications
You must be signed in to change notification settings - Fork 8.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Allow the mapping of OEM keys ({}|\<>/_-=+) in key bindings
This commit introduces support for key bindings containing keys traditionally classified as "OEM" keys. It uses VkKeyScanW and MapVirtualKeyW, and translates the modifiers that come out of VkKeyScanW to key chord modifiers. The net result of this is that you can use bindings like "ctrl+|" in your settings. That one in particular will be reserialized (and displayed in any menus) as "ctrl+shift+\". Admittedly, this is not clear, but it _is_ the truest representation of the key. This commit also moves the Xaml key chord name override generator into App as a static function, *AND* it forces its use for all modifier names. This will present a localization issue, which will be helped in part by #1972. This is required to work around microsoft/microsoft-ui-xaml#708. I've kept the original code around guarded by a puzzling ifdef, because it absolutely has value. Fixes #1212.
- Loading branch information
Showing
4 changed files
with
65 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters