delphi: Fix Delphi IDE specific errors

Cannot WaitFor a thread that destroys itself.

Cannot pass a thread to it self in the constructor.
Remove debug print