AppleWin/source/Registry.h
TomCh 7b55e994ec
Config GUI for DiskII card in slot-5 & improved slot config in Registry (#975, #977, PR #978)
Change to using Registry's 'Configuration\Slot n' for disk ii image pathnames (was 'Preferences').
Delete Registry's 'Configuration\Slot n' section each time there's a change of card.
Add same functionality to conf.ini.
LoadConfiguration(): load from the new Slot-n section (or otherwise the old legacy key).
Only update Registry's 'Starting Directory' for s6,d1.
Update help doc.
2021-08-29 11:39:51 +01:00

16 lines
895 B
C++

#pragma once
#define REGLOAD(a, b) RegLoadValue(TEXT(REG_CONFIG), (a), TRUE, (b))
#define REGLOAD_DEFAULT(a, b, c) RegLoadValue(TEXT(REG_CONFIG), (a), TRUE, (b), (c))
#define REGSAVE(a, b) RegSaveValue(TEXT(REG_CONFIG), (a), TRUE, (b))
BOOL RegLoadString (LPCTSTR section, LPCTSTR key, BOOL peruser, LPTSTR buffer, DWORD chars);
BOOL RegLoadString (LPCTSTR section, LPCTSTR key, BOOL peruser, LPTSTR buffer, DWORD chars, LPCTSTR defaultValue);
BOOL RegLoadValue (LPCTSTR section, LPCTSTR key, BOOL peruser, DWORD* value);
BOOL RegLoadValue (LPCTSTR section, LPCTSTR key, BOOL peruser, DWORD* value, DWORD defaultValue);
void RegSaveString (LPCTSTR section, LPCTSTR key, BOOL peruser, const std::string & buffer);
void RegSaveValue (LPCTSTR section, LPCTSTR key, BOOL peruser, DWORD value);
std::string& RegGetConfigSlotSection(UINT slot);
void RegDeleteConfigSlotSection(UINT slot);