Anonymous thread question: this is possible to access Terminated flag from thread body or I always should use TThread.CurrentThread.CheckTerminated like in my code below?
Anonymous thread question: this is possible to access Terminated flag from thread body or I always should use TThread.CurrentThread.CheckTerminated like in my code below?
Thread := TThread.CreateAnonymousThread(procedure()
begin
while not TThread.CurrentThread.CheckTerminated do
begin
end;
end);
Thread.Start;
Thread := TThread.CreateAnonymousThread(procedure()
begin
while not TThread.CurrentThread.CheckTerminated do
begin
end;
end);
Thread.Start;
Comments
Post a Comment