-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathUntMain.pas
80 lines (67 loc) · 1.71 KB
/
UntMain.pas
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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
unit UntMain;
interface
uses
Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants,
System.Classes, Vcl.Graphics, Vcl.Controls, Vcl.Forms,
Vcl.Dialogs, Vcl.ExtCtrls, Vcl.StdCtrls, dxGDIPlusClasses;
type
TForm1 = class(TForm)
Panel1: TPanel;
ImgFechar: TImage;
ImgMinimizar: TImage;
Label1: TLabel;
Label2: TLabel;
Label3: TLabel;
Edit1: TEdit;
Memo1: TMemo;
Edit2: TEdit;
Panel2: TPanel;
Image1: TImage;
ImgCancelar: TImage;
procedure Panel1MouseDown(Sender: TObject; Button: TMouseButton;
Shift: TShiftState; X, Y: Integer);
procedure ImgMinimizarMouseMove(Sender: TObject; Shift: TShiftState; X,
Y: Integer);
procedure ImgMinimizarMouseLeave(Sender: TObject);
procedure ImgMinimizarClick(Sender: TObject);
procedure ImgFecharClick(Sender: TObject);
procedure ImgCancelarClick(Sender: TObject);
private
public
end;
var
Form1: TForm1;
implementation
{$R *.dfm}
procedure TForm1.ImgCancelarClick(Sender: TObject);
begin
Edit1.Clear;
Edit2.Clear;
Memo1.Lines.Clear;
end;
procedure TForm1.ImgFecharClick(Sender: TObject);
begin
Close();
end;
procedure TForm1.ImgMinimizarClick(Sender: TObject);
begin
Application.Minimize;
end;
procedure TForm1.ImgMinimizarMouseLeave(Sender: TObject);
begin
Screen.Cursor := crDefault;
end;
procedure TForm1.ImgMinimizarMouseMove(Sender: TObject; Shift: TShiftState; X,
Y: Integer);
begin
Screen.Cursor := crHandPoint;
end;
procedure TForm1.Panel1MouseDown(Sender: TObject; Button: TMouseButton;
Shift: TShiftState; X, Y: Integer);
begin
Screen.Cursor := crSizeAll;
ReleaseCapture;
Self.Perform(wm_nclbuttondown,HTCAPTION,0);
Screen.Cursor := crDefault;
end;
end.