mirror of
https://github.com/Xevion/easy7zip.git
synced 2025-12-08 16:07:04 -06:00
easy 7-zip mod for 23.01: rebased from 19.00
This commit is contained in:
committed by
shunf4
parent
6086b78b4f
commit
b34719746b
@@ -31,6 +31,8 @@ static LPCTSTR const kListMode = TEXT("ListMode");
|
||||
static LPCTSTR const kFolderHistoryValueName = TEXT("FolderHistory");
|
||||
static LPCTSTR const kFastFoldersValueName = TEXT("FolderShortcuts");
|
||||
static LPCTSTR const kCopyHistoryValueName = TEXT("CopyHistory");
|
||||
static LPCTSTR const kOpenOutputFolderValueName = TEXT("OpenOutputFolder");
|
||||
static LPCTSTR const kClose7ZipValueName = TEXT("Close7Zip");
|
||||
|
||||
static NSynchronization::CCriticalSection g_CS;
|
||||
|
||||
@@ -328,3 +330,39 @@ void AddUniqueStringToHeadOfList(UStringVector &list, const UString &s)
|
||||
i++;
|
||||
list.Insert(0, s);
|
||||
}
|
||||
|
||||
void SaveOptOpenOutputFolder(bool bOpen)
|
||||
{
|
||||
CKey key;
|
||||
key.Create(HKEY_CURRENT_USER, kCUBasePath);
|
||||
key.SetValue(kOpenOutputFolderValueName, bOpen);
|
||||
}
|
||||
|
||||
bool ReadOptOpenOutputFolder()
|
||||
{
|
||||
CKey key;
|
||||
if (key.Open(HKEY_CURRENT_USER, kCUBasePath, KEY_READ) != ERROR_SUCCESS)
|
||||
return false;
|
||||
bool bOpen;
|
||||
if (key.QueryValue(kOpenOutputFolderValueName, bOpen) != ERROR_SUCCESS)
|
||||
return false;
|
||||
return bOpen;
|
||||
}
|
||||
|
||||
void SaveOptClose7Zip(bool bClose7Zip)
|
||||
{
|
||||
CKey key;
|
||||
key.Create(HKEY_CURRENT_USER, kCUBasePath);
|
||||
key.SetValue(kClose7ZipValueName, bClose7Zip);
|
||||
}
|
||||
|
||||
bool ReadOptClose7Zip()
|
||||
{
|
||||
CKey key;
|
||||
if (key.Open(HKEY_CURRENT_USER, kCUBasePath, KEY_READ) != ERROR_SUCCESS)
|
||||
return false;
|
||||
bool bOpen;
|
||||
if (key.QueryValue(kClose7ZipValueName, bOpen) != ERROR_SUCCESS)
|
||||
return false;
|
||||
return bOpen;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user