02-12-2010, 07:42 AM
When need to assign 2 or more existing filter functions to a macro, you can instead assign new filter function that calls these filter functions. Then you don't have to edit the existing functions.
Simple example.
Here FF_A and FF_B are existing filter functions. FF_A_and_B is new filter function.
Don't forget to check "This function is a filter function" in Properties.
Macro Macro1281
Trigger CSa //FF_A_and_B
Function FF_A_and_B
Function FF_A
Function FF_B
Simple example.
Here FF_A and FF_B are existing filter functions. FF_A_and_B is new filter function.
Don't forget to check "This function is a filter function" in Properties.
Macro Macro1281
Trigger CSa //FF_A_and_B

Function FF_A_and_B
;/
;Allows starting macro only in QM window AND only if Caps Lock is on.
function# iid FILTER&f
iid=FF_A(iid f); if(iid<=0) ret iid
;if need more filter functions:
;iid=FF_C(iid f); if(iid<=0) ret iid
;iid=FF_D(iid f); if(iid<=0) ret iid
;...
ret FF_B(iid f)Function FF_A
;/
;Allows starting macro only in QM window.
function# iid FILTER&f
if(wintest(f.hwnd "" "QM_Editor")) ret iidFunction FF_B
