OnGuard: Replace in all demo projects .lrs resource by .res resource. Less hints and warnings.

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@8724 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
wp_xxyyzz
2023-02-20 17:36:51 +00:00
parent 91b3ac7ce0
commit e456d87021
100 changed files with 824 additions and 2317 deletions

View File

@@ -58,8 +58,8 @@
<UnitName Value="Exdys30u"/>
<IsVisibleTab Value="True"/>
<EditorIndex Value="1"/>
<TopLine Value="9"/>
<CursorPos X="22" Y="35"/>
<TopLine Value="21"/>
<CursorPos Y="53"/>
<UsageCount Value="212"/>
<Loaded Value="True"/>
<LoadedDesigner Value="True"/>
@@ -97,7 +97,7 @@
<UsageCount Value="10"/>
</Unit6>
</Units>
<JumpHistory Count="10" HistoryIndex="9">
<JumpHistory Count="13" HistoryIndex="12">
<Position1>
<Filename Value="exdys30u.pas"/>
<Caret Line="130" TopLine="115"/>
@@ -138,6 +138,18 @@
<Filename Value="exdys30u.pas"/>
<Caret Line="108" TopLine="108"/>
</Position10>
<Position11>
<Filename Value="exdys30u.pas"/>
<Caret Line="73" Column="4" TopLine="59"/>
</Position11>
<Position12>
<Filename Value="exdys30u.pas"/>
<Caret Line="28" Column="8" TopLine="35"/>
</Position12>
<Position13>
<Filename Value="exdys30u.pas"/>
<Caret Line="38" Column="16" TopLine="101"/>
</Position13>
</JumpHistory>
</ProjectOptions>
<CompilerOptions>

View File

@@ -1,30 +0,0 @@
{ This is an automatically generated lazarus resource file }
LazarusResources.Add('TForm1','FORMDATA',[
'TPF0'#6'TForm1'#5'Form1'#4'Left'#3'D'#1#6'Height'#3#158#0#3'Top'#3#4#1#5'Wid'
+'th'#3#229#0#11'BorderStyle'#7#8'bsDialog'#7'Caption'#6#5'Form1'#12'ClientHe'
+'ight'#3#158#0#11'ClientWidth'#3#229#0#8'OnCreate'#7#10'FormCreate'#8'Positi'
+'on'#7#14'poScreenCenter'#10'LCLVersion'#6#7'2.3.0.0'#0#6'TLabel'#16'lblDays'
+'Remaining'#22'AnchorSideLeft.Control'#7#5'Owner'#19'AnchorSideLeft.Side'#7#9
+'asrCenter'#21'AnchorSideTop.Control'#7#4'Info'#18'AnchorSideTop.Side'#7#9'a'
+'srBottom'#4'Left'#2'E'#6'Height'#2#15#3'Top'#2':'#5'Width'#2'['#9'Alignment'
+#7#8'taCenter'#17'BorderSpacing.Top'#2#16#7'Caption'#6#16'Days Remaining: '
+#11'ParentColor'#8#0#0#7'TBitBtn'#8'CloseBtn'#22'AnchorSideLeft.Control'#7#5
+'Owner'#19'AnchorSideLeft.Side'#7#9'asrCenter'#21'AnchorSideTop.Control'#7#6
+'Bevel1'#18'AnchorSideTop.Side'#7#9'asrBottom'#4'Left'#2'['#6'Height'#2#26#3
+'Top'#2'h'#5'Width'#2'.'#8'AutoSize'#9#17'BorderSpacing.Top'#2#12#20'BorderS'
+'pacing.Bottom'#2#12#4'Kind'#7#7'bkClose'#8'TabOrder'#2#0#0#0#6'TLabel'#4'In'
+'fo'#22'AnchorSideLeft.Control'#7#5'Owner'#21'AnchorSideTop.Control'#7#5'Own'
+'er'#23'AnchorSideRight.Control'#7#5'Owner'#20'AnchorSideRight.Side'#7#9'asr'
+'Bottom'#4'Left'#2#12#6'Height'#2#30#3'Top'#2#12#5'Width'#3#205#0#7'Anchors'
+#11#5'akTop'#6'akLeft'#7'akRight'#0#20'BorderSpacing.Around'#2#12#7'Caption'
+#6':If you can edit this, then your program was allowed to run'#8'WordWrap'#9
+#0#0#6'TBevel'#6'Bevel1'#22'AnchorSideLeft.Control'#7#4'Info'#21'AnchorSideT'
+'op.Control'#7#16'lblDaysRemaining'#18'AnchorSideTop.Side'#7#9'asrBottom'#23
+'AnchorSideRight.Control'#7#4'Info'#20'AnchorSideRight.Side'#7#9'asrBottom'#4
+'Left'#2#12#6'Height'#2#3#3'Top'#2'Y'#5'Width'#3#205#0#7'Anchors'#11#5'akTop'
+#6'akLeft'#7'akRight'#0#17'BorderSpacing.Top'#2#16#5'Shape'#7#9'bsTopLine'#0
+#0#11'TOgDaysCode'#11'OgDaysCode1'#9'OnChecked'#7#18'OgDaysCode1Checked'#8'O'
+'nGetKey'#7#17'OgDaysCode1GetKey'#9'OnGetCode'#7#18'OgDaysCode1GetCode'#12'O'
+'nChangeCode'#7#21'OgDaysCode1ChangeCode'#4'Left'#2'('#3'Top'#2'X'#0#0#0
]);

View File

@@ -12,9 +12,9 @@ unit Exdys30u;
interface
uses
SysUtils, Classes, Controls,
Forms, Dialogs, LResources, StdCtrls, Buttons, ExtCtrls,
OnGuard, OgUtil, IniFiles;
SysUtils, Classes, Controls, Forms, Dialogs, StdCtrls, Buttons, ExtCtrls,
IniFiles,
OnGuard, OgUtil;
const
CKey : TKey = ($E5,$8F,$84,$D6,$92,$C9,$A4,$D8,
@@ -36,7 +36,7 @@ type
procedure OgDaysCode1ChangeCode(Sender: TObject; Code: TCode);
procedure OgDaysCode1Checked(Sender: TObject; Status: TCodeStatus);
private
codeinvalid : Boolean;
codeInvalid: Boolean;
public
{ Public declarations }
TheDir : string;
@@ -48,7 +48,7 @@ var
implementation
{$R *.lfm}
{==========================================================================}
@@ -59,7 +59,7 @@ end;
procedure TForm1.FormCreate(Sender: TObject);
begin
codeinvalid := false;
codeInvalid := false;
end;
{==========================================================================}
@@ -104,7 +104,7 @@ end;
procedure TForm1.OgDaysCode1ChangeCode(Sender: TObject; Code: TCode);
var
S : string;
S: string;
begin
if codeinvalid then Exit;
IniFile := TIniFile.Create(TheDir + 'Days30.INI');
@@ -124,29 +124,24 @@ var
S : string;
begin
case Status of
ogValidCode : begin
lblDaysRemaining.Caption := 'Days Remaining: '
+ IntToStr(OgDaysCode1.GetValue);
Exit;
end;
ogInvalidCode :
begin
S := 'Invalid Code';
codeinvalid := true;
end;
ogDayCountUsed : S := 'Program used more than 30 days' + #13 +
'Please register NOW';
ogCodeExpired : S := 'Evaluation period expired' + #13 +
'Please register NOW';
ogValidCode:
begin
lblDaysRemaining.Caption := Format('Days Remaining: %d', [OgDaysCode1.GetValue]);
Exit;
end;
ogInvalidCode:
begin
S := 'Invalid Code';
codeInvalid := true;
end;
ogDayCountUsed:
S := 'Program used more than 30 days' + LineEnding + 'Please register NOW';
ogCodeExpired:
S := 'Evaluation period expired' + LineEnding + 'Please register NOW';
end;
ShowMessage(S);
Application.Terminate;
end;
initialization
{$i exdys30u.lrs}
end.