Posts: 1,769
Threads: 410
Joined: Feb 2003
lets say i have a toolbar with no buttons.
lets say i have a jpeg set as the background of that toolbar.
Now, lets say i want to trigger a macro when i click anywhere in an area that is
10 10
20 20
is that possible and if so can i also make different types of shapes (eg circles, triangles, trees)?
thanks!
phase 1: bug the ever-living-bejesus out of Gintaras for functions almost no one else will use.
phase 2:
phase 3

ROFIT!
Posts: 1,769
Threads: 410
Joined: Feb 2003
i'm currently doing this with a dual trigger setup. but i'm getting so weird things happening.
I have a macro that is triggered by the toolbar becoming active
!a"TOOLBARPIC" "QM_toolbar"
however, it only triggers when i double click on it (I would like a single click). also, I get a quick flash of a window being created and destroyed; i'd like to not have that happen. is there a way to keep that from happening? I have the toolbar locked down with "0x9F". here's the window activity log
created 21106628 "#32770" "Customize Toolbar"
active 21106628 "#32770" "Customize Toolbar"
visible 21106628 "#32770" "Customize Toolbar"
active 226755548 "QM_toolbar" "TOOLBARPIC"
Thanks.
Posts: 12,140
Threads: 142
Joined: Dec 2002
Toolbar hook function
;/
function# hWnd message wParam lParam
sel message
,case WM_SETCURSOR
,if(!(wParam=hWnd or GetDlgCtrlID(wParam)=9999)) ret
,sel lParam
,,case WM_LBUTTONUP<<16|HTCLIENT ;;or WM_LBUTTONDOWN
,,POINT p; GetCursorPos &p; ScreenToClient hWnd &p
,,out "%i %i" p.x p.y
,,;now launch macros (mac) depending on coordinates
,,,
,,
Posts: 1,769
Threads: 410
Joined: Feb 2003
WOW!!!
that is SOOO much tighter than my double macro thing!!!!
is there a way to make that toolbar not always-on-top?
BTW: THANKS!!!!
Posts: 12,140
Threads: 142
Joined: Dec 2002
mac "Toolbar7" "+Progman"
Posts: 1,769
Threads: 410
Joined: Feb 2003
that works mostly but now everything takes precedence over the window even if i use ont on it. is there a way to make it move around in the z order like a normal app window?
thanks.
Posts: 12,140
Threads: 142
Joined: Dec 2002
No, but yes. Run this function.
int ho=CreateWindowEx(WS_EX_TOOLWINDOW "#32770" 0 WS_VISIBLE|WS_POPUP 0 0 -10000 -10000 0 0 _hinst 0)
int htb=mac("Toolbar7" ho)
opt waitmsg 1
wait 0 WD htb
"Activate owner" must be checked.
Posts: 1,769
Threads: 410
Joined: Feb 2003
DANG!!!
That works really nice!!
thanks.