mirror of
https://github.com/microsoft/PowerToys.git
synced 2024-12-05 04:39:08 +08:00
ShortcutGuide: change vk_code to suppress Start
Use reserved 0xCF virtual key-code to suppress the Start menu from appearing instead of 0x07 which is used by the Xbox Controller for the Xbox Guide button. Fixes: https://github.com/microsoft/PowerToys/issues/595
This commit is contained in:
parent
52ead7ad1b
commit
b767773742
@ -23,14 +23,14 @@ bool TargetState::signal_event(unsigned vk_code, bool key_down) {
|
||||
cv.notify_one();
|
||||
if (supress) {
|
||||
// Send a fake key-stroke to prevent the start menu from appearing.
|
||||
// We use 0x07 VK code, which is undefined. It still prevents the
|
||||
// We use 0xCF VK code, which is reserved. It still prevents the
|
||||
// start menu from appearing, but should not interfere with any
|
||||
// keyboard shortcuts.
|
||||
INPUT input[3] = { {},{},{} };
|
||||
input[0].type = INPUT_KEYBOARD;
|
||||
input[0].ki.wVk = 0x07;
|
||||
input[0].ki.wVk = 0xCF;
|
||||
input[1].type = INPUT_KEYBOARD;
|
||||
input[1].ki.wVk = 0x07;
|
||||
input[1].ki.wVk = 0xCF;
|
||||
input[1].ki.dwFlags = KEYEVENTF_KEYUP;
|
||||
input[2].type = INPUT_KEYBOARD;
|
||||
input[2].ki.wVk = VK_LWIN;
|
||||
|
Loading…
Reference in New Issue
Block a user