Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2008-06

Win32 Delphi Application.HookMainWindow() equivalent

3 messages · 3 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Brad Campbell

G'day all,

I'm not all that new to Lazarus, but I'm new to Lazarus on Win32.

I'm trying to receive WM_DEVICECHANGE events. With Delphi I can HookMainWindow() and filter on the TMessage value. I've seen in win32winapi.inc there is a TWinControl.DefaultHandler which looks like it gets the messages I want to hook.

Is there a relatively easy way to hook the event queue from a GUI application?

Regards,
Brad

"Human beings, who are almost unique in having the ability to learn from the experience of others, are also remarkable for their apparent disinclination to do so." -- Douglas Adams

Reply by email