autotext_pop and DynamicLVKeys can become 1 function with a couple small adjustments.
Function DynamicLVKeys
Trigger !v"" "" "" "SysListView32" /QM
and in DynamicLV
change this line
;0 "" 0x90080AC8 0x0 0 0 184 108 "Dialog_DLV"
to
0 "" 0x90080AC8 0x0 0 0 184 108 ""
the other function will need to remain separate as the hook function needs to be just the keyboard hook.
Function DynamicLVKeys
Trigger !v"" "" "" "SysListView32" /QM
int- hwnd=TriggerWindow
int- hlv=child("" "SysListView32" hwnd)
int cid=GetWinId(hlv)
if(SelInt(cid 8888 3)=0) ret
int hh=SetWindowsHookEx(WH_KEYBOARD_LL &sub.Hook_WH_KEYBOARD_LL _hinst 0)
opt waitmsg 1
rep
,0.2 -WV hlv
,err
,,continue
,break
UnhookWindowsHookEx hh
#sub Hook_WH_KEYBOARD_LL
function# nCode message KBDLLHOOKSTRUCT&k
if(nCode<0) goto gNext
int- hlv
int- hwnd
int isActive=hlv
if(!isActive) SendMessage hlv WM_ACTIVATE WA_ACTIVE 0
int up=k.flags&LLKHF_UP
FormatKeyString k.vkCode 0 &_s;
if _s=","
,if(!up)
,,SendKeysToWindow2(hlv key(D))
,ret 1
if _s="."
,if(!up)
,,SendKeysToWindow2(hlv key(U))
,ret 1
if _s="/"
,if(!up)
,,clo hwnd
,ret 1
if _s="Tab"
,,if(!up)
,,,SendKeysToWindow2(hwnd key(Y))
,,ret 1
;gNext
ret CallNextHookEx(0 nCode message &k)
and in DynamicLV
change this line
;0 "" 0x90080AC8 0x0 0 0 184 108 "Dialog_DLV"
to
0 "" 0x90080AC8 0x0 0 0 184 108 ""
the other function will need to remain separate as the hook function needs to be just the keyboard hook.