09-09-2008, 07:10 PM
what is faster ?
using the str solution makes it more intuitive for me.
;/
function# iid FILTER&f
str cla.getwinclass(f.hwnd)
str childclass.getwinclass(f.hwnd2)
str win_exe.getwinexe(win());err
int+ _xm = xm
int+ _ym = ym
int+ lhwnd = f.hwnd
if(!f.hwnd2) ret -2
sel _s.getwinexe(f.hwnd) 1
,case "qm"
,,if cla="#32768"
,,,out "cla="#32768" && win_exe="explorer""
,case "devenv"
,,if(childtest(f.hwnd2 "" "VsTextEditPane"))
,,,out "childtest(f.hwnd2 "" "VsTextEditPane")"
,,,ret -1 ;;eat click
,,
,case else ret -2 ;;default action in other programs
using the str solution makes it more intuitive for me.
;/
function# iid FILTER&f
str cla.getwinclass(f.hwnd)
str childclass.getwinclass(f.hwnd2)
str win_exe.getwinexe(win());err
int+ _xm = xm
int+ _ym = ym
int+ lhwnd = f.hwnd
if(!f.hwnd2) ret -2
sel _s.getwinexe(f.hwnd) 1
,case "qm"
,,if cla="#32768"
,,,out "cla="#32768" && win_exe="explorer""
,case "devenv"
,,if(childtest(f.hwnd2 "" "VsTextEditPane"))
,,,out "childtest(f.hwnd2 "" "VsTextEditPane")"
,,,ret -1 ;;eat click
,,
,case else ret -2 ;;default action in other programs