| |
|
|
| iF (23.01.11)
Nebenbeispiel trop Jörgs rClicked ( [...] ) : {$cleq}
Cls
Déclarer hButton1&,hButton2&,hButton3&
hButton1& = someMessagesToUserMessages(Créer("Button",%hwnd,"Test 1",10,50,48,20),0,0,0)
hButton2& = someMessagesToUserMessages(Créer("Button",%hwnd,"Test 2",10,80,48,20),0,0,0)
hButton3& = someMessagesToUserMessages(Créer("Button",%hwnd,"Test 3",10,110,48,20),0,0,0)
messages de l'utilisateur WM_RBUTTONDOWN,wm_rButtonDblClk,wm_lButtonDown,wm_lButtonDblClk
Tandis que 1
WaitInput
sélectionner uMessage
caseof WM_RBUTTONDOWN
sélectionner uwParam
caseof hButton1&
imprimer "Button1 rechts"
caseof hButton2&
imprimer "Button2 rechts"
caseof hButton3&
imprimer "Button2 rechts"
EndSelect
caseof wm_rButtonDblClk
sélectionner uwParam
caseof hButton1&
imprimer "Button1 doppelrechts"
caseof hButton2&
imprimer "Button2 doppelrechts"
caseof hButton3&
imprimer "Button2 doppelrechts"
EndSelect
caseof wm_lButtonDown
sélectionner uwParam
caseof hButton1&
imprimer "Button1 links"
caseof hButton2&
imprimer "Button2 links"
caseof hButton3&
imprimer "Button2 links"
EndSelect
caseof wm_lButtonDblClk
sélectionner uwParam
caseof hButton1&
imprimer "Button1 doppellinks"
caseof hButton2&
imprimer "Button2 doppellinks"
caseof hButton3&
imprimer "Button2 doppellinks"
EndSelect
EndSelect
Wend
nProc someMessagesToUserMessages
parameters wnd&,msg&,wp&,lp&
var owp&=getWindowLong(wnd&,gwl_userData)
ifnot owp&
setWindowLong(wnd&,gwl_userData,setWindowLong(wnd&,gwl_wndProc,procaddr(someMessagesToUserMessages,4)))
d'autre
cas msg&=WM_RBUTTONDOWN or msg&=wm_rButtonDblClk or msg&=wm_lButtonDown or msg&=wm_lButtonDblClk : sendMessage(%hWnd,msg&,wnd&,lp&)
return callWindowProc(owp&,wnd&,msg&,wp&,lp&)
endif
return wnd&
endproc
|
|
|
| |
|
|