02-18-2009, 04:29 AM
I'm playing around with the AltMouseTriggers but I can't get a basic mouse wheel trigger to work. Am I missing something?
function [nCode] [wParam] [MSLLHOOKSTRUCT*m]
if(getopt(nargs)=0)
,int+ g_mhook=SetWindowsHookEx(WH_MOUSE_LL &AltMouseTriggers _hinst 0)
,opt waitmsg 1
,AddTrayIcon "mouse.ico" "My mouse triggers" ;;remove this line if tray icon is not needed
,wait -1 -V g_mhook
,ret
if(nCode<0) goto g1
if(m.flags&LLMHF_INJECTED) goto g1 ;;not user-generated
sel wParam
,case WM_MOUSEWHEEL
,if(m.mouseData>0) out "forward"
,else if(m.mouseData<0) out "backward"
g1
ret CallNextHookEx(g_mhook nCode wParam m)