Hotkeys with [Fn]
Hey everyone, what I'd like very much to do is create a program that will recognize hotkeys that involve the Fn key of my laptop. However, RegisterHotKey() doesn't seem to have support for the Fn key. I then looked at the WM_SETHOTKEY message, which allows the HOTKEYF_EXT flag ('extended key'). I seem to recall somewhere else on MSDN saying that 'extended key' can refer to the Fn key, but I'm not sure; does anyone know more about this?
Also, MSDN says "When the user presses the hot key, the system activates the window." Does this just mean a WM_ACTIVATE message is sent to it each time the hotkey is pressed? If so, can the window always remain hidden and just spawn a second window to interact with the user, or will the window itself spontaneously appear?
Thanks in advance for any info (and ideas for better ways of achieving this are also very much appreciated).
Hm. Well, WM_SETHOTKEY doesn't do it, but it seems that a unique virtual-key code is sent for different Fn-F# combinations, and since I have a seemingly unused Fn-F12 combination, that shall suit my purposes just fine with the regular SetHotKey(). Ran into more problems with some other stuff (jeez, power settings on a laptop aren't simple to modify programmatically!), but I'm sure it'll all work out in the end with enough experimentation.
Thanks goes out to the 10 people who've looked at this thread :)
Never mind about power settings not being easy to modify. I didn't realize there's a handy dandy API that makes what I want to do pretty much as simple as 2 function calls...[/edit]