ВУЗ:
Составители:
77
    procedure TMyThread.UpdateCaption; 
    begin 
      Form1.Caption := 'Updated in a thread'; 
    end;} 
{TMyThread} 
procedure TMyThread.Execute; 
begin 
  {Place thread code here} 
  Synchronize(UpdateCaption); // действие потока 
end; 
procedure TMyThread.UpdateCaption; 
var 
  lblThread: TLabel; 
begin 
  if Form1.Caption <> 'Main program window' then 
    StartPosY := StartPosY + 20; 
  if StartPosY > 220 then begin 
    StartPosX := StartPosX + 120; 
    StartPosY := 50 
  end; 
  Form1.Caption := 'New thread started'; 
  lblThread := TLabel.Create(Form1); 
  with lblThread do begin 
    Left := StartPosX; 
    Top := StartPosY; 
    Parent := Form1; 
    Visible := True; 
Страницы
- « первая
- ‹ предыдущая
- …
- 75
- 76
- 77
- 78
- 79
- …
- следующая ›
- последняя »
