[Lazarus] [lazarus] Patch for processing WM_COPYDATA in Win32 / BugID 9210
Lukas Gradl
lazarus at ssn.at
Mon Feb 18 12:13:23 CET 2008
Vincent Snijders schrieb:
> Lukas Gradl schreef:
>> Vincent Snijders schrieb:
>>> Christian U. schreef:
>>>> I want to remember this Patch, its good and as i see the correct Way.
>>>> Why it is not applied ?
>>> What LCL components listen to WM_COPYDATA?
>>>
>> This patch was not for the LCL but for general Windows compatibility.
>
> Compatibility with windows?
>
>> At the moment the Windows part of the LCL eats up the
>> WM_COPYDATA-Messages, so you can't interact with quite some application
>> using this message to exchange control information with other apps.
>>
>
> If you want to use WM_COPYDATA messages on windows, you can add your own
> windows handler with windows.setwindowlong. No need to polute own
> LCL-message handler with it.
>
>> With this patch WM_COPYDATA will get throug the LCL-Messagehandler
>> untouched and can be handled in the application specific messagehandler.
>>
>
> I don't think we should add this to our event handler. Let the
> application specific message handler handle it. Maybe it should be
> easier to add one, but OTOH, what is difficult about this?
> Windows.SetWindowLong(MyForm.Handle, GWL_WNDPROC,
> PtrInt(SubClassWndProc));
>
> Let's keep the LCL win32 widgetset interface clean and just add things
> that are used by the LCL and keep custom extension outside it.
SetWindowLong is an option I've to check.
But IMHO this is not a real solution to the problem. The Pascal-way of
handling Messages is to define a custom messagehandler. This is how it
is done in countless applications.
In some later post in this thread you write "...we want the LCL to be
*VCL* compatible..." and in the VCL this is the way to go.
So I'm quite shure, that this should work in Lazarus accordingly.
So perhaps we should take a look at the LCL messagehandler in total to
stop it from eating up messages that are not necessary for the LCL.
I, for my part will keep my patch till there is a better solution - I'm
not willing to change all the custom Message-Handlers I wrote in the
last 15 years (or something like that - I use WM_COPYDATA quite a lot)
if there is a simple way to avoid this.
regards
Lukas
--
----------------------------
software security networks
Lukas Gradl <lazarus#ssn.at>
Eduard-Bodem-Gasse 9
A - 6020 Innsbruck
Tel: +43-720-300168-0
Fax: +43-512-341033-19
----------------------------
More information about the Lazarus
mailing list