-
Notifications
You must be signed in to change notification settings - Fork 6.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
lowlevel_keyboard_event_data.h doesn't seem to swallow keyboard events #1944
Comments
@JordanAnthonyKing Win+L cannot be suppressed by a low level hook, but Win+Plus and Win+Minus should get suppressed by the hook. Can you post the code snippet of how you handled Win+Plus? |
@arjunbalgovind You're right, Win+Plus is blocked properly, I likely made a mistake when I first gave it a go. Thanks for letting me know that Win+L cannot be unbound. Perhaps the comment in Shall I close the issue? |
I don't have a proper resource about which key combinations can't be blocked, apart from stack overflow answers and just trial and error. While working on the Keyboard Manager(#6) we have found that Win+L and Ctrl+Alt+Del can't be suppressed. These are two that we are aware of right now. We will be looking into other shortcuts later, but most of the Win shortcuts that we have been testing with seem to get suppressed with low level hooks.
@crutkas I'll defer that to you. |
I defer to @enricogior and his team here. |
That code has been working consistently since version 0.11, for existing module it hasn't caused any problem. |
Environment
Steps to reproduce
I've been playing around with the source code for FancyZones a lot recently. When adding keybindings the header file
interface/lowlevel_keyboard_event_data.h
is used to prevent keyboard events being sent to the OS. I don't believe this functionality actually works. An example given to block Win+L in the file is:Testing this out by altering the code in
FancyZones.cpp
like thus:OnSnapHotkey
has been updated accordingly.Pressing Win+L locks the computer. The window does move accordingly and placing a breakpoint in the if statement shows that it does get hit. The keyboard event just isn't being swallowed as it should.
Win+L is notoriously difficult to block, though I have found this affects other keys too, like Win+plus which is also not blocked and opens the magnifier.
Expected behavior
The defined key presses should not be passed to the OS.
Actual behavior
Key presses are being passed to the OS preventing them from being effectively rebound.
The text was updated successfully, but these errors were encountered: