-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathunit5.pas
More file actions
82 lines (66 loc) · 2.29 KB
/
unit5.pas
File metadata and controls
82 lines (66 loc) · 2.29 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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
(******************************************************************************)
(* *)
(* Author : Uwe Schächterle (Corpsman) *)
(* *)
(* This file is part of Episode manager *)
(* *)
(* See the file license.md, located under: *)
(* https://github.com/PascalCorpsman/Software_Licenses/blob/main/license.md *)
(* for details about the license. *)
(* *)
(* It is not allowed to change or remove this text from any *)
(* source file of the project. *)
(* *)
(******************************************************************************)
Unit unit5;
{$MODE ObjFPC}{$H+}
Interface
Uses
Classes, SysUtils, Forms, Controls, Graphics, Dialogs, StdCtrls,
uepisodenmanager;
Type
{ TForm5 }
TForm5 = Class(TForm)
Button1: TButton;
Button2: TButton;
Button3: TButton;
CheckBox1: TCheckBox;
Edit1: TEdit;
Edit2: TEdit;
Edit3: TEdit;
Label3: TLabel;
Label4: TLabel;
Label5: TLabel;
Procedure FormCreate(Sender: TObject);
private
public
Procedure Init(Const aDataSet: TDatensatz);
Function lclToDatensatz(): TDatensatz;
End;
Var
Form5: TForm5;
Implementation
{$R *.lfm}
{ TForm5 }
Procedure TForm5.FormCreate(Sender: TObject);
Begin
caption := 'Detailview';
Constraints.MinWidth := Width;
Constraints.MinHeight := Height;
Constraints.MaxHeight := Height;
End;
Procedure TForm5.Init(Const aDataSet: TDatensatz);
Begin
CheckBox1.Checked := aDataSet.Gesehen;
edit1.text := aDataSet.Serie;
edit2.text := aDataSet.Staffel;
edit3.text := aDataSet.Episodenname;
End;
Function TForm5.lclToDatensatz(): TDatensatz;
Begin
result.Gesehen := CheckBox1.Checked;
result.Serie := Edit1.Text;
result.Staffel := Edit2.Text;
result.Episodenname := Edit3.Text;
End;
End.