REQUEST: KeyDown / KeyUp support
Posted: 09 Apr 2011, 16:51
Hi Petr,
If you could consider adding support for KeyUp/KeyDown events, that would be great.
It would make it very easy to deal with key hold down situations with toggle switches on a "keyboard hack".
If I could write scripts such as the following one, it would solve most of my problems:
(Routines)
(Script for g key)
So when holding down the g key, on the first g keypress event, HIDmacro would send "g" and set the gkeydownFlag to true.
On future keypress event, since the gkeydownFlag would be set to true, HIDmacros would not send anything.
When releasing the g key, HIDmacro would set the gkeydownFlag to false, so that it can send "g" again on the next keypress event.
What do you think?
If you could consider adding support for KeyUp/KeyDown events, that would be great.
It would make it very easy to deal with key hold down situations with toggle switches on a "keyboard hack".
If I could write scripts such as the following one, it would solve most of my problems:
(Routines)
Code: Select all
dim gkeydownFlag
gkeydownFlag = false
Code: Select all
if HIDmacros.keydown then
if gkeydownFlag = false then
gkeydownFlag = true
sendkeys "g"
end if
end if
if HIDmacros.keyup then
gkeydownFlag = false
end if
On future keypress event, since the gkeydownFlag would be set to true, HIDmacros would not send anything.
When releasing the g key, HIDmacro would set the gkeydownFlag to false, so that it can send "g" again on the next keypress event.
What do you think?