[fpc-pascal] TThread.Queue vs TThread.Synchronize

Graeme Geldenhuys mailinglists at geldenhuys.co.uk
Mon Feb 23 18:58:25 CET 2015

Continuing on the TThread.Queue subject - is there any way to pass
parameters (or record structure with basic types) to the Queue() call?

That would be super useful instead of putting thread locking on
variables (for example, reading a progress value to update a GUI
progress bar).

I understand that anonymous methods (something I again don't know much
about) take a snapshot of local variables. So that could possibly be
used with TThread.Queue() to send variable (simple data types)
information? Please correct my if I am wrong - like I said, I don't
really know anonymous methods or their real usage.

  - Graeme -

fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal

More information about the fpc-pascal mailing list