RegisterHotkey Fn Modifier?

戏子无情 提交于 2020-01-03 18:50:54

问题


I know you can use CTRL, ALT, SHIFT, etc. modifiers for RegisterHotKey, but what about the Fn key?

I used to have some bloatware on my laptop that changed brightness when Fn+Up/Down was pressed. I removed all the bloatware, and I want to write a program that does the same thing.

Any help is appreciated!


回答1:


Fn key is modifier but not software like ALT, SHIFT, etc. which are processed by operation system. Fn is hardware key modifier so it changes keycode keyboard sends to operation system.

For example is 37 and Fn + is 36 so when you need to handle Fn + press you need to react on 36 keycode.

PS. On some keyboards Fn key send keycode so it can be handled seperatly, but usualy they don't.



来源:https://stackoverflow.com/questions/10052194/registerhotkey-fn-modifier

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!