> >> Also the HTTP server is >> implemented as a component (TComponent descendant), so I gather the >> thoughts was that some day they would like it to sit on the Lazarus >> component palette, where it will be dropped onto some form or data >> module - thus rendering that application frozen too. > > It was never meant as such. > > It is meant as the "main program loop", as Leonardo surmised. The component > is meant to be simple. > > And using a TComponent does not automatically mean that it will sit on the > component palette. I use TComponent because I like the automated memory > management it offers; e.g. it also means the TDatamodules it creates for > servicing requests can be owned by the server component itself. > > If you want still to have a "main program", you should use a thread and > create the component in the thread. Which is exactly what happens in a > service application, the intended environment for the component. > > Michael.
I have to agree this is a very odd interface. IMHO setting a property is expected to return quickly; a call that's meant to be used as "program loop" should be a explicit method and named accordingly... (Listen/Run/Execute/ActivateAndWait/etc) -Flávio _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal