mirror of
https://github.com/doublecmd/doublecmd.git
synced 2026-06-21 09:58:13 +00:00
UPD: Store cache in the program directory in portable mode
This commit is contained in:
parent
c6e5f13764
commit
070a667cc9
1 changed files with 7 additions and 1 deletions
|
|
@ -10,6 +10,7 @@ var
|
|||
gpLngDir : String = ''; // path to language *.po files
|
||||
gpPixmapPath : String = ''; // path to pixmaps
|
||||
gpHighPath : String = ''; // editor highlighter directory
|
||||
gpCacheDir : String = ''; // cache directory
|
||||
gpThumbCacheDir : String = ''; // thumbnails cache directory
|
||||
|
||||
//Global Configuration Filename
|
||||
|
|
@ -60,6 +61,11 @@ begin
|
|||
gpCfgDir := gpGlobalCfgDir;
|
||||
end;
|
||||
end;
|
||||
if gpCfgDir <> gpGlobalCfgDir then
|
||||
gpCacheDir := GetAppCacheDir
|
||||
else begin
|
||||
gpCacheDir := gpExePath + 'cache';
|
||||
end;
|
||||
DCDebug('Executable directory: ', gpExePath);
|
||||
DCDebug('Configuration directory: ', gpCfgDir);
|
||||
DCDebug('Global configuration directory: ', gpGlobalCfgDir);
|
||||
|
|
@ -68,7 +74,7 @@ begin
|
|||
gpLngDir := gpExePath + 'language' + DirectorySeparator;
|
||||
gpPixmapPath := gpExePath + 'pixmaps' + DirectorySeparator;
|
||||
gpHighPath:= gpExePath + 'highlighters' + DirectorySeparator;
|
||||
gpThumbCacheDir := GetAppCacheDir + PathDelim + 'thumbnails';
|
||||
gpThumbCacheDir := gpCacheDir + PathDelim + 'thumbnails';
|
||||
|
||||
// set up environment variables
|
||||
UpdateEnvironmentVariable;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue