AxibugEmuOnline/References/virtuanessrc097-master/Registry.h
2024-08-05 17:58:53 +08:00

38 lines
2.1 KiB
C++
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

//
// レジストリサポートクラス
//
#ifndef __CREGISTRY_INCLUDED__
#define __CREGISTRY_INCLUDED__
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
#include <windowsx.h>
#include <TCHAR.h>
#include <string>
using namespace std;
class CRegistry
{
public:
static void SetRegistryKey( LPCSTR lpszKey );
static UINT GetProfileInt ( LPCSTR lpszSection, LPCSTR lpszEntry, INT nDefault );
static BOOL GetProfileString( LPCSTR lpszSection, LPCSTR lpszEntry, LPVOID lpData, UINT nBytes );
static BOOL GetProfileBinary( LPCSTR lpszSection, LPCSTR lpszEntry, LPVOID lpData, UINT nBytes );
static BOOL WriteProfileInt( LPCSTR lpszSection, LPCSTR lpszEntry, INT nValue );
static BOOL WriteProfileString( LPCSTR lpszSection, LPCSTR lpszEntry, LPCSTR lpszValue );
static BOOL WriteProfileBinary( LPCSTR lpszSection, LPCSTR lpszEntry, LPVOID pData, UINT nBytes );
protected:
static CHAR m_szRegistryKey[MAX_PATH];
static HKEY GetRegistryKey();
static HKEY GetSectionKey( LPCTSTR lpszSection );
private:
};
#endif // !__CREGISTRY_INCLUDED__