Thanks, Chris for the example.
Bob Mechler
Announcement
Collapse
No announcement yet.
Getmessage question
Collapse
X
-
I concur with the point of leaving it alone (the message loop), unless you have some funky special-needs app.
There are a multitude of methods to obtain keystrokes: a few are subclassing, superclassing, using a custom control, or keyboard accelerators (see ACCEL in PB help).
Leave a comment:
-
Message Watch Utility
Bob,
Check this out in the source code forum.
I wrote a quick app that allows you to see what messages are being sent through the message loop versus to the dialog procedure directly.
http://www.powerbasic.com/support/pb...173#post315173
Leave a comment:
-
I never trap messages in the message loop; I trap them at the destination window.
If you want a 'system wide' or even a 'thread' thing, you can look at hooks.
I don't avoid this for any technical reason, I do it for maitenance purposes: the message loop is the message loop is the message loop.
In your case (" the %WM_KEY,%WM_KEYDOWN,%WM_CHAR are messages that can be trapped here for the control with input focus"), "subclassing" is the LED which turns on when I need to do this.
YMMV.
Leave a comment:
-
Getmessage question
Code:While GetMessage(Msg,%NULL,0,0) Call TranslateMessage(Msg) Call DispatchMessage(Msg) Wend
Bob MechlerTags: None
Leave a comment: