-
-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathModal.pas
More file actions
63 lines (50 loc) · 1.23 KB
/
Copy pathModal.pas
File metadata and controls
63 lines (50 loc) · 1.23 KB
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
unit Modal;
interface
uses
Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants, System.Classes, Vcl.Graphics,
Vcl.Controls, Vcl.Forms, Vcl.Dialogs, AdvSmoothButton, Vcl.ExtCtrls, AdvPanel;
type
TfrmModal = class(TForm)
pnlStatus: TAdvPanel;
pnlHidden: TPanel;
pnlMain: TPanel;
AdvSmoothButton1: TAdvSmoothButton;
AdvSmoothButton2: TAdvSmoothButton;
procedure AdvSmoothButton2Click(Sender: TObject);
procedure AdvSmoothButton1Click(Sender: TObject);
private
{ Private declarations }
protected
function SaveChanges: Boolean; virtual;
procedure UpdateMainForm; virtual;
procedure CancelChanges; virtual;
public
{ Public declarations }
end;
implementation
{$R *.dfm}
procedure TfrmModal.AdvSmoothButton1Click(Sender: TObject);
begin
CancelChanges;
ModalResult := mrCancel; // Close;
end;
procedure TfrmModal.AdvSmoothButton2Click(Sender: TObject);
begin
if SaveChanges then begin
UpdateMainForm;
ModalResult := mrOK; // Close;
end;
end;
function TfrmModal.SaveChanges: Boolean;
begin
Result := True;
end;
procedure TfrmModal.CancelChanges;
begin
// virtual
end;
procedure TfrmModal.UpdateMainForm;
begin
// virtual
end;
end.