forked from desenvolvimentojd3/DelphiToastMessage
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathUnit1.pas
More file actions
46 lines (36 loc) · 939 Bytes
/
Unit1.pas
File metadata and controls
46 lines (36 loc) · 939 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
unit Unit1;
interface
uses
Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants, System.Classes, Vcl.Graphics,
Vcl.Controls, Vcl.Forms, Vcl.Dialogs, Vcl.StdCtrls, Vcl.ExtCtrls;
type
TForm1 = class(TForm)
Panel1: TPanel;
Panel2: TPanel;
Button1: TButton;
Edit1: TEdit;
RadioGroup1: TRadioGroup;
procedure Button1Click(Sender: TObject);
procedure FormResize(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
implementation
uses uTToastMessage;
{$R *.dfm}
procedure TForm1.Button1Click(Sender: TObject);
var
AType: TpLabelType;
begin
AType := TpLabelType(RadioGroup1.ItemIndex);
TToastMessage.ToastIt(Self, AType, tpError,'Error','Hello, found a error!');
end;
procedure TForm1.FormResize(Sender: TObject);
begin
Edit1.Left := Trunc(Self.Width /2);
end;
end.