OnGuard: Rework sample projects.

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@8721 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
wp_xxyyzz
2023-02-20 11:17:45 +00:00
parent a1792b0941
commit d6279b614d
103 changed files with 2214 additions and 1689 deletions

View File

@ -58,8 +58,8 @@
<UnitName Value="Exnetu"/>
<IsVisibleTab Value="True"/>
<EditorIndex Value="1"/>
<TopLine Value="118"/>
<CursorPos X="59" Y="141"/>
<TopLine Value="119"/>
<CursorPos X="59" Y="142"/>
<UsageCount Value="20"/>
<Loaded Value="True"/>
<LoadedDesigner Value="True"/>
@ -83,7 +83,7 @@
<UsageCount Value="10"/>
</Unit4>
</Units>
<JumpHistory Count="2" HistoryIndex="1">
<JumpHistory Count="3" HistoryIndex="2">
<Position1>
<Filename Value="exnetu.pas"/>
<Caret Line="141" Column="59" TopLine="118"/>
@ -92,6 +92,10 @@
<Filename Value="exnetu.pas"/>
<Caret Line="140" Column="59" TopLine="117"/>
</Position2>
<Position3>
<Filename Value="exnetu.pas"/>
<Caret Line="141" Column="59" TopLine="118"/>
</Position3>
</JumpHistory>
</ProjectOptions>
<CompilerOptions>

View File

@ -14,12 +14,12 @@ object Form1: TForm1
Position = poScreenCenter
LCLVersion = '2.3.0.0'
object StatusLbl: TLabel
AnchorSideLeft.Control = Memo1
AnchorSideLeft.Control = Info
AnchorSideTop.Control = CloseBtn
AnchorSideTop.Side = asrCenter
Left = 12
Height = 15
Top = 231
Top = 244
Width = 32
BorderSpacing.Bottom = 12
Caption = 'Status'
@ -68,15 +68,16 @@ object Form1: TForm1
TabOrder = 0
end
object CloseBtn: TBitBtn
AnchorSideTop.Control = Memo1
AnchorSideTop.Control = Bevel1
AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = Memo1
AnchorSideRight.Control = Info
AnchorSideRight.Side = asrBottom
Left = 403
Height = 25
Top = 226
Top = 239
Width = 75
Anchors = [akTop, akRight]
BorderSpacing.Top = 10
BorderSpacing.Bottom = 12
Kind = bkClose
TabOrder = 1
@ -86,7 +87,7 @@ object Form1: TForm1
AnchorSideRight.Control = CloseBtn
Left = 302
Height = 25
Top = 226
Top = 239
Width = 97
Anchors = [akTop, akRight]
BorderSpacing.Right = 4
@ -95,7 +96,7 @@ object Form1: TForm1
OnClick = RemoveBtnClick
TabOrder = 2
end
object Memo1: TLabel
object Info: TLabel
AnchorSideLeft.Control = Owner
AnchorSideTop.Control = CodeBtn
AnchorSideTop.Side = asrBottom
@ -112,6 +113,19 @@ object Form1: TForm1
ParentColor = False
WordWrap = True
end
object Bevel1: TBevel
AnchorSideLeft.Control = Info
AnchorSideTop.Control = Info
AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = Info
AnchorSideRight.Side = asrBottom
Left = 12
Height = 3
Top = 226
Width = 466
Anchors = [akTop, akLeft, akRight]
Shape = bsTopLine
end
object OgNetCode1: TOgNetCode
OnChecked = CodeChecked
OnGetKey = GetKey

View File

@ -6,12 +6,12 @@ LazarusResources.Add('TForm1','FORMDATA',[
+'AutoSize'#9#11'BorderStyle'#7#8'bsDialog'#7'Caption'#6#20'Network Code Exam'
+'ple'#12'ClientHeight'#3'='#1#11'ClientWidth'#3#234#1#8'OnCreate'#7#10'FormC'
+'reate'#8'Position'#7#14'poScreenCenter'#10'LCLVersion'#6#7'2.3.0.0'#0#6'TLa'
+'bel'#9'StatusLbl'#22'AnchorSideLeft.Control'#7#5'Memo1'#21'AnchorSideTop.Co'
+'ntrol'#7#8'CloseBtn'#18'AnchorSideTop.Side'#7#9'asrCenter'#4'Left'#2#12#6'H'
+'eight'#2#15#3'Top'#3#231#0#5'Width'#2' '#20'BorderSpacing.Bottom'#2#12#7'Ca'
+'ption'#6#6'Status'#5'Color'#7#6'clNone'#11'ParentColor'#8#0#0#6'TLabel'#6'L'
+'abel1'#22'AnchorSideLeft.Control'#7#7'CodeBtn'#19'AnchorSideLeft.Side'#7#9
+'asrBottom'#21'AnchorSideTop.Control'#7#7'CodeBtn'#18'AnchorSideTop.Side'#7#9
+'bel'#9'StatusLbl'#22'AnchorSideLeft.Control'#7#4'Info'#21'AnchorSideTop.Con'
+'trol'#7#8'CloseBtn'#18'AnchorSideTop.Side'#7#9'asrCenter'#4'Left'#2#12#6'He'
+'ight'#2#15#3'Top'#3#244#0#5'Width'#2' '#20'BorderSpacing.Bottom'#2#12#7'Cap'
+'tion'#6#6'Status'#5'Color'#7#6'clNone'#11'ParentColor'#8#0#0#6'TLabel'#6'La'
+'bel1'#22'AnchorSideLeft.Control'#7#7'CodeBtn'#19'AnchorSideLeft.Side'#7#9'a'
+'srBottom'#21'AnchorSideTop.Control'#7#7'CodeBtn'#18'AnchorSideTop.Side'#7#9
+'asrCenter'#4'Left'#3#181#0#6'Height'#2#15#3'Top'#2#17#5'Width'#2'H'#18'Bord'
+'erSpacing.Left'#2'P'#7'Caption'#6#13'Current code:'#5'Color'#7#6'clNone'#11
+'ParentColor'#8#0#0#6'TLabel'#7'CodeLbl'#22'AnchorSideLeft.Control'#7#6'Labe'
@ -23,29 +23,34 @@ LazarusResources.Add('TForm1','FORMDATA',[
+'Left'#2#12#6'Height'#2#25#3'Top'#2#12#5'Width'#2'Y'#20'BorderSpacing.Around'
+#2#12#25'BorderSpacing.InnerBorder'#2#4#7'Caption'#6#10'Enter Code'#7'OnClic'
+'k'#7#12'CodeBtnClick'#8'TabOrder'#2#0#0#0#7'TBitBtn'#8'CloseBtn'#21'AnchorS'
+'ideTop.Control'#7#5'Memo1'#18'AnchorSideTop.Side'#7#9'asrBottom'#23'AnchorS'
+'ideRight.Control'#7#5'Memo1'#20'AnchorSideRight.Side'#7#9'asrBottom'#4'Left'
+#3#147#1#6'Height'#2#25#3'Top'#3#226#0#5'Width'#2'K'#7'Anchors'#11#5'akTop'#7
+'akRight'#0#20'BorderSpacing.Bottom'#2#12#4'Kind'#7#7'bkClose'#8'TabOrder'#2
+#1#0#0#7'TButton'#9'RemoveBtn'#21'AnchorSideTop.Control'#7#8'CloseBtn'#23'An'
+'chorSideRight.Control'#7#8'CloseBtn'#4'Left'#3'.'#1#6'Height'#2#25#3'Top'#3
+#226#0#5'Width'#2'a'#7'Anchors'#11#5'akTop'#7'akRight'#0#19'BorderSpacing.Ri'
+'ght'#2#4#25'BorderSpacing.InnerBorder'#2#4#7'Caption'#6#11'Remove Code'#7'O'
+'nClick'#7#14'RemoveBtnClick'#8'TabOrder'#2#2#0#0#6'TLabel'#5'Memo1'#22'Anch'
+'orSideLeft.Control'#7#5'Owner'#21'AnchorSideTop.Control'#7#7'CodeBtn'#18'An'
+'chorSideTop.Side'#7#9'asrBottom'#23'AnchorSideRight.Control'#7#5'Owner'#20
+'AnchorSideRight.Side'#7#9'asrBottom'#4'Left'#2#12#6'Height'#3#165#0#3'Top'#2
+'1'#5'Width'#3#210#1#7'Anchors'#11#5'akTop'#6'akLeft'#7'akRight'#0#20'Border'
+'Spacing.Around'#2#12#7'Caption'#12'H'#2#0#0'The label at the bottom of this'
+' form indicates the status of the code. An invalid code indicates that the '
+'code is either the incorrect type or that none has been entered. '#13#10#13
+#10'If the proper code has not been entered or the ONGUARD.INI file was dele'
+'ted, the message will say that the code is invalid.'#13#10#13#10'Use the "E'
+'nter Code" button to enter a code (the CODEGEN program can be used to gener'
+'ate the proper "Usage" code). '#13#10#13#10'The "Remove Code" button can be'
+' used to remove the entered code from the INI file. Doing so will cause the'
+' TOgNetCode component to report that the code is invalid.'#5'Color'#7#9'clB'
+'tnFace'#11'ParentColor'#8#8'WordWrap'#9#0#0#10'TOgNetCode'#10'OgNetCode1'#9
+'OnChecked'#7#11'CodeChecked'#8'OnGetKey'#7#6'GetKey'#9'OnGetCode'#7#7'GetCo'
+'de'#8'FileName'#6#9'EXNET.NAF'#4'Left'#3#192#0#3'Top'#3#208#0#0#0#0
+'ideTop.Control'#7#6'Bevel1'#18'AnchorSideTop.Side'#7#9'asrBottom'#23'Anchor'
+'SideRight.Control'#7#4'Info'#20'AnchorSideRight.Side'#7#9'asrBottom'#4'Left'
+#3#147#1#6'Height'#2#25#3'Top'#3#239#0#5'Width'#2'K'#7'Anchors'#11#5'akTop'#7
+'akRight'#0#17'BorderSpacing.Top'#2#10#20'BorderSpacing.Bottom'#2#12#4'Kind'
+#7#7'bkClose'#8'TabOrder'#2#1#0#0#7'TButton'#9'RemoveBtn'#21'AnchorSideTop.C'
+'ontrol'#7#8'CloseBtn'#23'AnchorSideRight.Control'#7#8'CloseBtn'#4'Left'#3'.'
+#1#6'Height'#2#25#3'Top'#3#239#0#5'Width'#2'a'#7'Anchors'#11#5'akTop'#7'akRi'
+'ght'#0#19'BorderSpacing.Right'#2#4#25'BorderSpacing.InnerBorder'#2#4#7'Capt'
+'ion'#6#11'Remove Code'#7'OnClick'#7#14'RemoveBtnClick'#8'TabOrder'#2#2#0#0#6
+'TLabel'#4'Info'#22'AnchorSideLeft.Control'#7#5'Owner'#21'AnchorSideTop.Cont'
+'rol'#7#7'CodeBtn'#18'AnchorSideTop.Side'#7#9'asrBottom'#23'AnchorSideRight.'
+'Control'#7#5'Owner'#20'AnchorSideRight.Side'#7#9'asrBottom'#4'Left'#2#12#6
+'Height'#3#165#0#3'Top'#2'1'#5'Width'#3#210#1#7'Anchors'#11#5'akTop'#6'akLef'
+'t'#7'akRight'#0#20'BorderSpacing.Around'#2#12#7'Caption'#12'H'#2#0#0'The la'
+'bel at the bottom of this form indicates the status of the code. An invalid'
+' code indicates that the code is either the incorrect type or that none has'
+' been entered. '#13#10#13#10'If the proper code has not been entered or the'
+' ONGUARD.INI file was deleted, the message will say that the code is invali'
+'d.'#13#10#13#10'Use the "Enter Code" button to enter a code (the CODEGEN pr'
+'ogram can be used to generate the proper "Usage" code). '#13#10#13#10'The "'
+'Remove Code" button can be used to remove the entered code from the INI fil'
+'e. Doing so will cause the TOgNetCode component to report that the code is '
+'invalid.'#5'Color'#7#9'clBtnFace'#11'ParentColor'#8#8'WordWrap'#9#0#0#6'TBe'
+'vel'#6'Bevel1'#22'AnchorSideLeft.Control'#7#4'Info'#21'AnchorSideTop.Contro'
+'l'#7#4'Info'#18'AnchorSideTop.Side'#7#9'asrBottom'#23'AnchorSideRight.Contr'
+'ol'#7#4'Info'#20'AnchorSideRight.Side'#7#9'asrBottom'#4'Left'#2#12#6'Height'
+#2#3#3'Top'#3#226#0#5'Width'#3#210#1#7'Anchors'#11#5'akTop'#6'akLeft'#7'akRi'
+'ght'#0#5'Shape'#7#9'bsTopLine'#0#0#10'TOgNetCode'#10'OgNetCode1'#9'OnChecke'
+'d'#7#11'CodeChecked'#8'OnGetKey'#7#6'GetKey'#9'OnGetCode'#7#7'GetCode'#8'Fi'
+'leName'#6#9'EXNET.NAF'#4'Left'#3#192#0#3'Top'#3#208#0#0#0#0
]);

View File

@ -5,16 +5,17 @@ interface
uses
SysUtils, Classes,Controls, Forms, Dialogs,
StdCtrls, Buttons,LResources, OnGuard, IniFiles, OgUtil, OgNetWrk;
StdCtrls, Buttons,LResources, ExtCtrls, OnGuard, IniFiles, OgUtil, OgNetWrk;
type
{ TForm1 }
TForm1 = class(TForm)
Bevel1: TBevel;
CodeBtn: TButton;
CloseBtn: TBitBtn;
Memo1: TLabel;
Info: TLabel;
StatusLbl: TLabel;
Label1: TLabel;
CodeLbl: TLabel;