microsoft-ui-xaml
microsoft-ui-xaml copied to clipboard
Multiple windows in WinUI 3 cannot register hotkeys with the same hotkey ID.
Describe the bug
I want to call RegisterHotKey to register global hotkeys for different windows, but when the hotkey IDs are the same, the registration fails.
Steps to reproduce the bug
- Clone https://github.com/GochenRyan/WinUISample.git
- Checkout commit fe334cce48856a6dd842a9448098d746d09f649e
- Set Hotkeys as startup project
- Insert a break point at https://github.com/GochenRyan/WinUISample/blob/fe334cce48856a6dd842a9448098d746d09f649e/WinUISample/Hotkeys/GlobalHotkeyManager.cs#L43
- Upon running the application and clicking the 'Create new window' button, the attempt to register the hotkey will fail.
Expected behavior
No response
Screenshots
No response
NuGet package version
WinUI 3 - Windows App SDK 1.6.1: 1.6.240923002
Windows version
Windows Insider Build (xxxxx)
Additional context
No response