Combining long press and double tapping scripts
Posted: 06 Apr 2024, 18:23
Hi all,
The following two scripts work well separately but not together. Any chance of combining it so that one script can send short press/single tap, long press, double tap and triple press?
Thank you in advance.
The following two scripts work well separately but not together. Any chance of combining it so that one script can send short press/single tap, long press, double tap and triple press?
Thank you in advance.
Code: Select all
#IFWinActive, ahk_exe notepad.exe
d::
{
count++
settimer, actions, 350
}
return
actions:
{
if (count = 1)
{
send d
}
else if (count = 2)
{
send e
}
else if (count = 3)
{
send f
}
count := 0
}
return
#IFWinActive
Code: Select all
#IFWinActive, ahk_exe notepad.exe
$d::
keywait, d, T0.5
if errorlevel {
SoundBeep
Send e
} else Send d
keywait, d
; d key down would immediately trigger $d:: again
return
#IFWinActive