unit2.~pas
来自「Linux 下 C 语言编程」· ~PAS 代码 · 共 42 行
~PAS
42 行
unit Unit2;
interface
uses
Classes;
type
TPbThread = class(TThread)
private
{ Private declarations }
protected
procedure Execute; override;
procedure StepProgress;
public
PbID:1..2;
end;
implementation
uses Unit1;
{ TPbThread }
procedure TPbThread.Execute;
var
i : cardinal;
begin
i := 1;
while (i < 100000) do
begin
Synchronize(StepProgress);
Inc(i);
end;
end;
procedure TPbThread.StepProgress;
begin
if PbID=1 then Form1.Pb1.StepIt
else Form1.Pb2.StepIt;
end;
end.
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?