diff options
-rw-r--r-- | src/corelib/fpg_utils.pas | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/corelib/fpg_utils.pas b/src/corelib/fpg_utils.pas index 7c7869b4..78848e40 100644 --- a/src/corelib/fpg_utils.pas +++ b/src/corelib/fpg_utils.pas @@ -62,6 +62,8 @@ function fpgExtractFileName(const FileName: TfpgString): TfpgString; function fpgExtractFileExt(const FileName: TfpgString): TfpgString; function fpgForceDirectories(const ADirectory: TfpgString): Boolean; function fpgChangeFileExt(const FileName, Extension: TfpgString): TfpgString; +function fpgGetAppConfigDir(const Global: Boolean): TfpgString; +function fpgGetAppConfigFile(const Global: Boolean; const SubDir: Boolean): TfpgString; implementation @@ -160,6 +162,16 @@ begin Result := ChangeFileExt(fpgToOSEncoding(Filename), Extension); end; +function fpgGetAppConfigDir(const Global: Boolean): TfpgString; +begin + Result := fpgFromOSEncoding(GetAppConfigDir(Global)); +end; + +function fpgGetAppConfigFile(const Global: Boolean; const SubDir: Boolean): TfpgString; +begin + Result := fpgFromOSEncoding(GetAppConfigFile(Global, SubDir)); +end; + function fpgAppendPathDelim(const Path: TfpgString): TfpgString; begin if (Path <> '') and (Path[length(Path)] <> PathDelim) then |