[Lazarus] Windows.PostMessage vs Application.QueueAsyncCall
Michael Schnell
mschnell at lumino.de
Wed Mar 19 13:01:26 CET 2014
On 03/19/2014 02:04 AM, Hans-Peter Diettrich wrote:
>
> For Windows applications you should eventually know some bits about
> the main thread message queue.
Not really, as LCL and RTL provide as well TThread.Queue and
Application.QueueAsyncCall in Windows and Linux (and Mac, AFAIK). In
Delphi you just have TThread.Queue. (Hence TThread.Queue in fact is my
favorite way of asynchronous signaling. )
The "very old style" Delphi / Windows way for asynchronous signaling was
using " PostMessage(); "and "Procedure ....message .. ".
We poor Delphi programmers were forced to do this before Borland and
friends implemented " TThread.Queue() ". In fact they were bold enough
to provide the documentation for TThread.Queue only several versions
later than the actually working implementation.
-Michael
More information about the Lazarus
mailing list