-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathfrmOptionsDlg.pas
54 lines (43 loc) · 1.25 KB
/
frmOptionsDlg.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
unit frmOptionsDlg;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls, ComCtrls;
type
TOptionsDlg = class(TForm)
cmdOK: TButton;
cmdCancel: TButton;
pgOptions: TPageControl;
tsEditor: TTabSheet;
chkSongLayoutColNumbers: TCheckBox;
GroupBox1: TGroupBox;
optPatternRowDec: TRadioButton;
optPatternRowHex: TRadioButton;
procedure FormShow(Sender: TObject);
procedure cmdOKClick(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
OptionsDlg: TOptionsDlg;
implementation
uses frmSTMainWnd;
{$R *.dfm}
procedure TOptionsDlg.cmdOKClick(Sender: TObject);
begin
STMainWnd.RegSettings.ShowLayoutColNumbers := chkSongLayoutColNumbers.Checked;
STMainWnd.RegSettings.PatternRowNumbersHex := optPatternRowHex.Checked;
STMainWnd.RegSettings.SaveSettings;
ModalResult := mrOK;
end;
procedure TOptionsDlg.FormShow(Sender: TObject);
begin
chkSongLayoutColNumbers.Checked := STMainWnd.RegSettings.ShowLayoutColNumbers;
if STMainWnd.RegSettings.PatternRowNumbersHex then
optPatternRowHex.Checked := true
else
optPatternRowDec.Checked := true;
end;
end.