ReactOS 0.4.16-dev-905-gc1b8c4f
settings.cpp
Go to the documentation of this file.
1/*
2 * PROJECT: ReactOS browseui
3 * LICENSE: LGPL-2.1-or-later (https://spdx.org/licenses/LGPL-2.1-or-later)
4 * PURPOSE: Stores settings for the file explorer UI.
5 * COPYRIGHT: Copyright 2023 Carl Bialorucki <cbialo2@outlook.com>
6 */
7
8#include "precomp.h"
9
11
13{
14 SHRegSetUSValueW(L"Software\\Microsoft\\Internet Explorer\\Main", L"StatusBarOther",
16
17 SHRegSetUSValueW(L"Software\\Microsoft\\Internet Explorer\\Main", L"ShowGoButton",
19
20 SHRegSetUSValueW(L"Software\\Microsoft\\Internet Explorer\\Toolbar", L"Locked",
22}
23
25{
26 fStatusBarVisible = SHRegGetBoolUSValueW(L"Software\\Microsoft\\Internet Explorer\\Main",
27 L"StatusBarOther", FALSE, TRUE);
28
30
31 fLocked = SHRegGetBoolUSValueW(L"Software\\Microsoft\\Internet Explorer\\Toolbar",
32 L"Locked", FALSE, TRUE);
33}
34
36{
37 this->cLength = sizeof(CABINETSTATE);
38 ReadCabinetState(this, this->cLength);
39
40 /* Overrides */
41 fFullPathTitle = SHRegGetBoolUSValueW(L"Software\\Microsoft\\Windows\\CurrentVersion\\Explorer\\CabinetState",
42 L"FullPath", FALSE, FALSE);
43
44 fFullPathAddress = SHRegGetBoolUSValueW(L"Software\\Microsoft\\Windows\\CurrentVersion\\Explorer\\CabinetState",
45 L"FullPathAddress", FALSE, TRUE);
46}
static BOOL ShouldShowGoButton()
Definition: addressband.cpp:55
#define TRUE
Definition: types.h:120
#define FALSE
Definition: types.h:117
CabinetStateSettings gCabinetState
Definition: settings.cpp:10
LONG WINAPI SHRegSetUSValueW(LPCWSTR pszSubKey, LPCWSTR pszValue, DWORD dwType, LPVOID pvData, DWORD cbData, DWORD dwFlags)
Definition: reg.c:673
BOOL WINAPI SHRegGetBoolUSValueW(LPCWSTR pszSubKey, LPCWSTR pszValue, BOOL fIgnoreHKCU, BOOL fDefault)
Definition: reg.c:770
#define L(x)
Definition: ntvdm.h:50
#define REG_DWORD
Definition: sdbapi.c:596
BOOL WINAPI ReadCabinetState(CABINETSTATE *cs, int length)
Definition: shellord.c:1806
#define SHREGSET_FORCE_HKCU
Definition: shlwapi.h:321
WORD cLength
Definition: shlobj.h:2393
BOOL fFullPathTitle
Definition: shlobj.h:2395
void Save()
Definition: settings.cpp:12
void Load()
Definition: settings.cpp:24
BOOL fStatusBarVisible
Definition: settings.h:17
BOOL fLocked
Definition: settings.h:15
BOOL fShowGoButton
Definition: settings.h:16