58 lines
1.1 KiB
ObjectPascal
58 lines
1.1 KiB
ObjectPascal
unit Unit1;
|
|
|
|
interface
|
|
|
|
uses
|
|
System.SysUtils, System.Types, System.UITypes, System.Classes, System.Variants,
|
|
FMX.Types, FMX.Controls, FMX.Forms, FMX.Graphics, FMX.Dialogs, CoreCipher,
|
|
FMX.StdCtrls, FMX.Controls.Presentation, FMX.Memo,
|
|
DoStatusIO, FMX.Layouts;
|
|
|
|
type
|
|
TForm1 = class(TForm)
|
|
Memo1: TMemo;
|
|
Button1: TButton;
|
|
procedure Button1Click(Sender: TObject);
|
|
procedure FormCreate(Sender: TObject);
|
|
procedure FormDestroy(Sender: TObject);
|
|
private
|
|
{ Private declarations }
|
|
public
|
|
{ Public declarations }
|
|
procedure DoStatusNear(AText: string; const ID: Integer = 0);
|
|
end;
|
|
|
|
var
|
|
Form1: TForm1;
|
|
|
|
implementation
|
|
|
|
{$R *.fmx}
|
|
|
|
|
|
procedure TForm1.Button1Click(Sender: TObject);
|
|
begin
|
|
Button1.Visible:=False;
|
|
TestCoreCipher;
|
|
Button1.Visible:=True;
|
|
end;
|
|
|
|
procedure TForm1.DoStatusNear(AText: string; const ID: Integer);
|
|
begin
|
|
Memo1.Lines.Add(AText);
|
|
Memo1.GoToTextEnd;
|
|
Application.ProcessMessages;
|
|
end;
|
|
|
|
procedure TForm1.FormCreate(Sender: TObject);
|
|
begin
|
|
AddDoStatusHook(Self, DoStatusNear);
|
|
end;
|
|
|
|
procedure TForm1.FormDestroy(Sender: TObject);
|
|
begin
|
|
DeleteDoStatusHook(Self);
|
|
end;
|
|
|
|
end.
|