Browse Source

* aaccess also for treginifile.

git-svn-id: trunk@8169 -
marco 18 years ago
parent
commit
6a133f11f3
2 changed files with 12 additions and 0 deletions
  1. 10 0
      packages/fcl-registry/src/regini.inc
  2. 2 0
      packages/fcl-registry/src/registry.pp

+ 10 - 0
packages/fcl-registry/src/regini.inc

@@ -13,6 +13,16 @@ begin
    fPath := '';
 end;
 
+constructor TRegIniFile.Create(const FN: String;aaccess:longword);
+begin
+  inherited Create(aaccess);
+  fFileName := FN;
+  if fFileName<>'' then
+   fPath := fFileName + '\'
+  else
+   fPath := '';
+end;
+
 procedure TRegIniFile.DeleteKey(const Section, Ident: String);
 begin
 	if not OpenKey(fPath+Section,true) then Exit;

+ 2 - 0
packages/fcl-registry/src/registry.pp

@@ -14,6 +14,7 @@ Uses
     Windows,
   {$endif XMLREG}
     Classes,
+    inifiles,
     SysUtils;
 
   {$I regdef.inc}
@@ -132,6 +133,7 @@ type
     fPath    : String;
   public
     constructor Create(const FN: string);
+    constructor Create(const FN: string;aaccess:longword); overload;
     function ReadString(const Section, Ident, Default: string): string;
     function ReadInteger(const Section, Ident: string;
                 Default: Longint): Longint;