[Lazarus] Web Module not works on Linux

Michael Van Canneyt michael at freepascal.org
Sun Nov 21 18:02:52 CET 2010

On Sun, 21 Nov 2010, Graeme Geldenhuys wrote:

> On 21 November 2010 16:34, Michael Van Canneyt  wrote:
>>  Procedure TCustomWebApplication.CreateForm(AClass : TComponentClass; out
>> Reference);
> And in essence, that method should really be renamed, as it can create
> any TComponent instance - it doesn't really relate to TForm (or any
> forms) in general. The same goes for LCL's Application.CreateForm() -
> but the latter will probably stay for that annoying "delphi
> compatibility" thing. But the TCustomWebApplication is not a Delphi
> clone (as far as I know), so why stick to the crappy method name? Name
> is something more appropriate.

It is done so because then the Lazarus IDE doesn't have to be told 
what this method is when auto-creating forms or data modules.

If each TApplication instance used it's own name, then the IDE 
would need to know what kind of project it is and how the method 
to auto-create forms is called (and what arguments it accepts) 
when modifying the project file. That's just cumbersome.

So there is a reason for this besides Delphi compatibility.
But of course I think a name like 'TApplication.CreateInstance()'
would have been more appropriate.


More information about the Lazarus mailing list