Why not hotkeys? (Edit: Oh, I just followed the link to EvilC's post. There's probably a way to query for pressed keys and get them all returned. But you might also be interested in the
Input command, though it has some limitations.)
If you need hotkeys to all do the same thing, like literally telling you you pressed a particular key, see this code:
Code: Select all
Loop, 255
Hotkey, % "~" Format("vk{:x}",A_Index), pressed, On
return
pressed:
Tooltip % "You pressed " GetKeyName(SubStr(A_ThisHotkey,2))
return
Edit: Based on EvilC's post, you might be able to make use of A_
PriorKey and the use of A_
TimeIdlePhysical or with Hotekys: A_
PriorHotkey (or A_
ThisHotkey if you incorporate it into the Hotkey's actions)and A_
TimeSincePriorHotkey. The potential problem with using A_
TimeIdlePhysical is that it responds to mouse movement.
Edit 2: And he linked his source code, so it would be worthwhile to check out his code to see what his implementation was to see if you can directly use that.