[lazarus] circular unit reference

Florian Klaempfl Florian.Klaempfl at gmx.de
Sat Nov 15 06:18:57 EST 2003


Mattias Gaertner wrote:
> On Sat, 15 Nov 2003 02:40:00 +0100
> Florian Klaempfl <Florian.Klaempfl at gmx.de> wrote:
> 
> 
>>Mattias Gaertner wrote:
>>
>>>This means the LCL is not any longer really platform independent. :(
>>>OTOH you can now write win32 specific applications easier.
>>>
>>
>>Why? messages is a win32 specific file which is provided by lazarus for 
>>other platform. It's like another couple of win32 functions you emulate.
> 
> 
> That's the problem: the LCL does not really emulate. It makes porting easy.
> So, it provides most commonly used functions of Delphi applications. The LCL
> does not and can not guarantee, that they will work as the winapi
> documentation. For example a function creating a win32 api button does very
> different things in the gtk. Because most Delphi applications don't care for
> the details, the LCL work. That's the whole magic.
> 
> By using the real messages.pp (and the other win32 api units provided by
> fpc), 

If you consider messages.pp as win32 api unit I would suggest to remove 
the references to it in the common lcl code and replace it by lmessages.pp.

> one can use the real stuff. And this way a developer can write
> programs that are win32 specific without noticing.
> Of course, if a developer wants to write win32 specific stuff (like the
> win32 intf itself), he needs the real stuff. Therefore I applied the
> nonwin32 workaround. I just wish, there would be a better way, so that
> people wanting to write platform independent code can notice win32
> specifics. But I don't know no better way. So, win32 developers have to live
> with it.






More information about the Lazarus mailing list