View Single Post
  #1  
Old 07-05-2006, 06:14
Mkz Mkz is offline
Friend
 
Join Date: Jan 2002
Posts: 98
Rept. Given: 0
Rept. Rcvd 2 Times in 2 Posts
Thanks Given: 5
Thanks Rcvd at 25 Times in 17 Posts
Mkz Reputation: 2
I think the key might be here:

Code:
<00174> 0024094C P WM_SYSKEYDOWN nVirtKey:VK_MENU cRepeat:1 ScanCode:00 fExtended:0 fAltDown:1 fRepeat:0 fUp:0
<00175> 0024094C S message:0xBD04 [Benutzerdefiniert:WM_USER+47364] wParam:00000012 lParam:20000001
<00176> 004206AA S message:0xB016 [Benutzerdefiniert:WM_USER+44054] wParam:00000012 lParam:20000001
<00177> 004206AA R message:0xB016 [Benutzerdefiniert:WM_USER+44054] lResult:00000000
<00178> 0024094C R message:0xBD04 [Benutzerdefiniert:WM_USER+47364] lResult:00000000
<00179> 0024094C P WM_SYSKEYDOWN nVirtKey:'P' cRepeat:1 ScanCode:00 fExtended:0 fAltDown:1 fRepeat:0 fUp:0
<00180> 0024094C S message:0xBD04 [Benutzerdefiniert:WM_USER+47364] wParam:00000050 lParam:20000001
<00181> 004206AA S message:0xB016 [Benutzerdefiniert:WM_USER+44054] wParam:00000050 lParam:20000001
<00182> 004206AA S message:0xB03F [Benutzerdefiniert:WM_USER+44095] wParam:00000000 lParam:01CB8420
....
<00200> 004206AA R message:0xB016 [Benutzerdefiniert:WM_USER+44054] lResult:00000001
<00201> 0024094C R message:0xBD04 [Benutzerdefiniert:WM_USER+47364] lResult:00000001
First when you press ALT, the user message USER+47364 message is sent, with wparam=12 and lparam=20000001, which in turn generates another message USER+44054.
Afterwards, you press P. This is the moment that things get done, when the key goes down and not up. Of course this always ends up being a decision of the developer, but for menus for instance, they appear when the key goes down and not up. Anyway, when P goes down there is this message once again, USER+43764, this time with wparam=50.
Have you tried sending this message? If you have, have you also tried sending it first with wparam=12 (ALT down), then with wparam=50 (P down)?

I believe the developer might have implemented triggering the action on the equivalent of the OnKeyDown event:
if Key = 'P' then ....

Which leads me to another suggestion. How about sending the WM_SYSKEYDOWN messages yourself? The WM_USER messages might be just for other stuff, maybe the action you want is executed directly in the key down event, without resorting to any further message exchanges.
Reply With Quote