Handle / detect <Alt> key combinations
- From: Jatin <triplederby100-propos@xxxxxxxxx>
- Date: Wed, 28 May 2008 21:47:34 -0700
I have a custom panel component that derives from TCustomPanel. In its implementation, I have message handler for WM_KEYDOWN. The handler just posts the message to the application that hosts the panel in its form.
Two of the key combinations that I am interested in detecting are <Alt><Ctrl>F, and also <Ctrl>F. Here's the handler code;
procedure TAppPanel.WMKeyDown(var Message : TWMKeyDown);
begin
if (hwndApp <> 0) then
PostMessage(hwndApp, Message.Msg, Message.CharCode, Message.KeyData);
end;
The handler just posts the message to the application that handles it.
What happens is that when the <Alt><Ctrl>F combination is pressed, the application (whose handle is hwndApp) only receives <Ctrl>F combination, and processes it. Somehow the <Alt> key combination is never received by it. How can I make sure that it also receives <Alt><Ctrl>F combination as well?
Jatin
.
- Follow-Ups:
- Re: Handle / detect <Alt> key combinations
- From: Jamie
- Re: Handle / detect <Alt> key combinations
- Prev by Date: Re: Use pdf as background for form
- Next by Date: Re: Use pdf as background for form
- Previous by thread: Which form in Application.OnModalBegin and Application.OnModalEnd
- Next by thread: Re: Handle / detect <Alt> key combinations
- Index(es):
Relevant Pages
|