1996-03-31 16:40:13 +00:00
|
|
|
/*
|
2002-03-09 23:29:33 +00:00
|
|
|
* Win32 registry defines (see also winnt.h)
|
|
|
|
*
|
|
|
|
* Copyright (C) the Wine project
|
|
|
|
*
|
|
|
|
* This library is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU Lesser General Public
|
|
|
|
* License as published by the Free Software Foundation; either
|
|
|
|
* version 2.1 of the License, or (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This library is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
|
* Lesser General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU Lesser General Public
|
|
|
|
* License along with this library; if not, write to the Free Software
|
2006-05-18 12:49:52 +00:00
|
|
|
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
1996-03-31 16:40:13 +00:00
|
|
|
*/
|
2002-03-09 23:29:33 +00:00
|
|
|
|
1996-03-31 16:40:13 +00:00
|
|
|
#ifndef __WINE_WINREG_H
|
|
|
|
#define __WINE_WINREG_H
|
|
|
|
|
1999-06-12 10:53:06 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif /* defined(__cplusplus) */
|
|
|
|
|
1999-04-25 11:05:30 +00:00
|
|
|
#define HKEY_CLASSES_ROOT ((HKEY) 0x80000000)
|
|
|
|
#define HKEY_CURRENT_USER ((HKEY) 0x80000001)
|
|
|
|
#define HKEY_LOCAL_MACHINE ((HKEY) 0x80000002)
|
|
|
|
#define HKEY_USERS ((HKEY) 0x80000003)
|
|
|
|
#define HKEY_PERFORMANCE_DATA ((HKEY) 0x80000004)
|
|
|
|
#define HKEY_CURRENT_CONFIG ((HKEY) 0x80000005)
|
|
|
|
#define HKEY_DYN_DATA ((HKEY) 0x80000006)
|
1996-03-31 16:40:13 +00:00
|
|
|
|
1999-02-12 13:44:38 +00:00
|
|
|
/*
|
|
|
|
* registry provider structs
|
|
|
|
*/
|
2002-05-31 23:06:46 +00:00
|
|
|
typedef struct value_entA
|
1999-02-12 13:44:38 +00:00
|
|
|
{ LPSTR ve_valuename;
|
|
|
|
DWORD ve_valuelen;
|
|
|
|
DWORD_PTR ve_valueptr;
|
|
|
|
DWORD ve_type;
|
|
|
|
} VALENTA, *PVALENTA;
|
|
|
|
|
|
|
|
typedef struct value_entW {
|
|
|
|
LPWSTR ve_valuename;
|
|
|
|
DWORD ve_valuelen;
|
|
|
|
DWORD_PTR ve_valueptr;
|
|
|
|
DWORD ve_type;
|
|
|
|
} VALENTW, *PVALENTW;
|
|
|
|
|
1999-07-04 11:01:21 +00:00
|
|
|
typedef ACCESS_MASK REGSAM;
|
2007-09-17 22:40:48 +00:00
|
|
|
typedef LONG LSTATUS;
|
1999-02-12 13:44:38 +00:00
|
|
|
|
2004-10-08 20:50:06 +00:00
|
|
|
/*
|
|
|
|
* InitiateSystemShutdown() reasons
|
|
|
|
*/
|
|
|
|
#include <reason.h>
|
|
|
|
|
|
|
|
#define REASON_OTHER (SHTDN_REASON_MAJOR_OTHER | SHTDN_REASON_MINOR_OTHER)
|
|
|
|
#define REASON_UNKNOWN SHTDN_REASON_UNKNOWN
|
|
|
|
#define REASON_LEGACY_API SHTDN_REASON_LEGACY_API
|
|
|
|
#define REASON_PLANNED_FLAG SHTDN_REASON_FLAG_PLANNED
|
|
|
|
|
|
|
|
#define MAX_SHUTDOWN_TIMEOUT (10*365*24*60*60)
|
|
|
|
|
2005-07-03 11:19:03 +00:00
|
|
|
/*
|
|
|
|
* RegGetValue() restrictions
|
|
|
|
*/
|
|
|
|
|
|
|
|
#define RRF_RT_REG_NONE (1 << 0)
|
|
|
|
#define RRF_RT_REG_SZ (1 << 1)
|
|
|
|
#define RRF_RT_REG_EXPAND_SZ (1 << 2)
|
|
|
|
#define RRF_RT_REG_BINARY (1 << 3)
|
|
|
|
#define RRF_RT_REG_DWORD (1 << 4)
|
|
|
|
#define RRF_RT_REG_MULTI_SZ (1 << 5)
|
|
|
|
#define RRF_RT_REG_QWORD (1 << 6)
|
|
|
|
#define RRF_RT_DWORD (RRF_RT_REG_BINARY | RRF_RT_REG_DWORD)
|
|
|
|
#define RRF_RT_QWORD (RRF_RT_REG_BINARY | RRF_RT_REG_QWORD)
|
2007-08-08 08:40:35 +00:00
|
|
|
#define RRF_RT_ANY 0xffff
|
2005-07-03 11:19:03 +00:00
|
|
|
#define RRF_NOEXPAND (1 << 28)
|
|
|
|
#define RRF_ZEROONFAILURE (1 << 29)
|
2004-10-08 20:50:06 +00:00
|
|
|
|
2003-03-17 21:21:15 +00:00
|
|
|
BOOL WINAPI AbortSystemShutdownA(LPSTR);
|
|
|
|
BOOL WINAPI AbortSystemShutdownW(LPWSTR);
|
|
|
|
#define AbortSystemShutdown WINELIB_NAME_AW(AbortSystemShutdown)
|
|
|
|
BOOL WINAPI InitiateSystemShutdownA(LPSTR,LPSTR,DWORD,BOOL,BOOL);
|
|
|
|
BOOL WINAPI InitiateSystemShutdownW(LPWSTR,LPWSTR,DWORD,BOOL,BOOL);
|
|
|
|
#define InitiateSystemShutdown WINELIB_NAME_AW(InitiateSystemShutdown);
|
|
|
|
BOOL WINAPI InitiateSystemShutdownExA(LPSTR,LPSTR,DWORD,BOOL,BOOL,DWORD);
|
|
|
|
BOOL WINAPI InitiateSystemShutdownExW(LPWSTR,LPWSTR,DWORD,BOOL,BOOL,DWORD);
|
|
|
|
#define InitiateSystemShutdownEx WINELIB_NAME_AW(InitiateSystemShutdownEx);
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegCreateKeyExA(HKEY,LPCSTR,DWORD,LPSTR,DWORD,REGSAM,
|
2002-10-03 19:46:27 +00:00
|
|
|
LPSECURITY_ATTRIBUTES,PHKEY,LPDWORD);
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegCreateKeyExW(HKEY,LPCWSTR,DWORD,LPWSTR,DWORD,REGSAM,
|
2002-10-03 19:46:27 +00:00
|
|
|
LPSECURITY_ATTRIBUTES,PHKEY,LPDWORD);
|
1999-02-09 15:46:25 +00:00
|
|
|
#define RegCreateKeyEx WINELIB_NAME_AW(RegCreateKeyEx)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegDisablePredefinedCache(void);
|
|
|
|
LSTATUS WINAPI RegSaveKeyA(HKEY,LPCSTR,LPSECURITY_ATTRIBUTES);
|
|
|
|
LSTATUS WINAPI RegSaveKeyW(HKEY,LPCWSTR,LPSECURITY_ATTRIBUTES);
|
1999-02-09 15:46:25 +00:00
|
|
|
#define RegSaveKey WINELIB_NAME_AW(RegSaveKey)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegSetKeySecurity(HKEY,SECURITY_INFORMATION,PSECURITY_DESCRIPTOR);
|
|
|
|
LSTATUS WINAPI RegConnectRegistryA(LPCSTR,HKEY,PHKEY);
|
|
|
|
LSTATUS WINAPI RegConnectRegistryW(LPCWSTR,HKEY,PHKEY);
|
1999-02-09 15:46:25 +00:00
|
|
|
#define RegConnectRegistry WINELIB_NAME_AW(RegConnectRegistry)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegEnumKeyExA(HKEY,DWORD,LPSTR,LPDWORD,LPDWORD,LPSTR,
|
1999-02-09 15:46:25 +00:00
|
|
|
LPDWORD,LPFILETIME);
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegEnumKeyExW(HKEY,DWORD,LPWSTR,LPDWORD,LPDWORD,LPWSTR,
|
1999-02-09 15:46:25 +00:00
|
|
|
LPDWORD,LPFILETIME);
|
|
|
|
#define RegEnumKeyEx WINELIB_NAME_AW(RegEnumKeyEx)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegGetKeySecurity(HKEY,SECURITY_INFORMATION,PSECURITY_DESCRIPTOR,LPDWORD);
|
|
|
|
LSTATUS WINAPI RegGetValueA(HKEY,LPCSTR,LPCSTR,DWORD,LPDWORD,PVOID,LPDWORD);
|
|
|
|
LSTATUS WINAPI RegGetValueW(HKEY,LPCWSTR,LPCWSTR,DWORD,LPDWORD,PVOID,LPDWORD);
|
2005-07-18 15:10:22 +00:00
|
|
|
#define RegGetValue WINELIB_NAME_AW(RegGetValue)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegLoadKeyA(HKEY,LPCSTR,LPCSTR);
|
|
|
|
LSTATUS WINAPI RegLoadKeyW(HKEY,LPCWSTR,LPCWSTR);
|
1999-02-09 15:46:25 +00:00
|
|
|
#define RegLoadKey WINELIB_NAME_AW(RegLoadKey)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegLoadMUIStringA(HKEY,LPCSTR,LPSTR,DWORD,LPDWORD,DWORD,LPCSTR);
|
|
|
|
LSTATUS WINAPI RegLoadMUIStringW(HKEY,LPCWSTR,LPWSTR,DWORD,LPDWORD,DWORD,LPCWSTR);
|
2006-02-14 09:41:18 +00:00
|
|
|
#define RegLoadMUIString WINELIB_NAME_AW(RegLoadMUIString)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegNotifyChangeKeyValue(HKEY,BOOL,DWORD,HANDLE,BOOL);
|
|
|
|
LSTATUS WINAPI RegOpenCurrentUser(REGSAM,PHKEY);
|
|
|
|
LSTATUS WINAPI RegOpenKeyExW(HKEY,LPCWSTR,DWORD,REGSAM,PHKEY);
|
|
|
|
LSTATUS WINAPI RegOpenKeyExA(HKEY,LPCSTR,DWORD,REGSAM,PHKEY);
|
1999-02-09 15:46:25 +00:00
|
|
|
#define RegOpenKeyEx WINELIB_NAME_AW(RegOpenKeyEx)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegOpenUserClassesRoot(HANDLE,DWORD,REGSAM,PHKEY);
|
|
|
|
LSTATUS WINAPI RegQueryInfoKeyW(HKEY,LPWSTR,LPDWORD,LPDWORD,LPDWORD,
|
1999-02-09 15:46:25 +00:00
|
|
|
LPDWORD,LPDWORD,LPDWORD,LPDWORD,LPDWORD,
|
|
|
|
LPDWORD,LPFILETIME);
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegQueryInfoKeyA(HKEY,LPSTR,LPDWORD,LPDWORD,LPDWORD,
|
1999-02-09 15:46:25 +00:00
|
|
|
LPDWORD,LPDWORD,LPDWORD,LPDWORD,LPDWORD,
|
|
|
|
LPDWORD,LPFILETIME);
|
|
|
|
#define RegQueryInfoKey WINELIB_NAME_AW(RegQueryInfoKey)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegQueryMultipleValuesA(HKEY,PVALENTA,DWORD,LPSTR,LPDWORD);
|
|
|
|
LSTATUS WINAPI RegQueryMultipleValuesW(HKEY,PVALENTW,DWORD,LPWSTR,LPDWORD);
|
2002-07-20 20:02:55 +00:00
|
|
|
#define RegQueryMultipleValues WINELIB_NAME_AW(RegQueryMultipleValues)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegReplaceKeyA(HKEY,LPCSTR,LPCSTR,LPCSTR);
|
|
|
|
LSTATUS WINAPI RegReplaceKeyW(HKEY,LPCWSTR,LPCWSTR,LPCWSTR);
|
1999-02-09 15:46:25 +00:00
|
|
|
#define RegReplaceKey WINELIB_NAME_AW(RegReplaceKey)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegRestoreKeyA(HKEY,LPCSTR,DWORD);
|
|
|
|
LSTATUS WINAPI RegRestoreKeyW(HKEY,LPCWSTR,DWORD);
|
1999-02-09 15:46:25 +00:00
|
|
|
#define RegRestoreKey WINELIB_NAME_AW(RegRestoreKey)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegUnLoadKeyA(HKEY,LPCSTR);
|
|
|
|
LSTATUS WINAPI RegUnLoadKeyW(HKEY,LPCWSTR);
|
1999-02-09 15:46:25 +00:00
|
|
|
#define RegUnLoadKey WINELIB_NAME_AW(RegUnLoadKey)
|
|
|
|
|
|
|
|
/* Declarations for functions that are the same in Win16 and Win32 */
|
|
|
|
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegCloseKey(HKEY);
|
|
|
|
LSTATUS WINAPI RegFlushKey(HKEY);
|
1999-02-09 15:46:25 +00:00
|
|
|
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegCreateKeyA(HKEY,LPCSTR,PHKEY);
|
|
|
|
LSTATUS WINAPI RegCreateKeyW(HKEY,LPCWSTR,PHKEY);
|
1999-02-09 15:46:25 +00:00
|
|
|
#define RegCreateKey WINELIB_NAME_AW(RegCreateKey)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegDeleteKeyA(HKEY,LPCSTR);
|
|
|
|
LSTATUS WINAPI RegDeleteKeyW(HKEY,LPCWSTR);
|
1999-02-09 15:46:25 +00:00
|
|
|
#define RegDeleteKey WINELIB_NAME_AW(RegDeleteKey)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegDeleteKeyValueA(HKEY,LPCSTR,LPCSTR);
|
|
|
|
LSTATUS WINAPI RegDeleteKeyValueW(HKEY,LPCWSTR,LPCWSTR);
|
2007-08-09 08:32:35 +00:00
|
|
|
#define RegDeleteKeyValue WINELIB_NAME_AW(RegDeleteKeyValue)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegDeleteTreeA(HKEY,LPCSTR);
|
|
|
|
LSTATUS WINAPI RegDeleteTreeW(HKEY,LPCWSTR);
|
2007-05-25 16:15:54 +00:00
|
|
|
#define RegDeleteTree WINELIB_NAME_AW(RegDeleteTree)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegDeleteValueA(HKEY,LPCSTR);
|
|
|
|
LSTATUS WINAPI RegDeleteValueW(HKEY,LPCWSTR);
|
1999-02-09 15:46:25 +00:00
|
|
|
#define RegDeleteValue WINELIB_NAME_AW(RegDeleteValue)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegEnumKeyA(HKEY,DWORD,LPSTR,DWORD);
|
|
|
|
LSTATUS WINAPI RegEnumKeyW(HKEY,DWORD,LPWSTR,DWORD);
|
1999-02-09 15:46:25 +00:00
|
|
|
#define RegEnumKey WINELIB_NAME_AW(RegEnumKey)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegEnumValueA(HKEY,DWORD,LPSTR,LPDWORD,LPDWORD,LPDWORD,LPBYTE,LPDWORD);
|
|
|
|
LSTATUS WINAPI RegEnumValueW(HKEY,DWORD,LPWSTR,LPDWORD,LPDWORD,LPDWORD,LPBYTE,LPDWORD);
|
1999-02-09 15:46:25 +00:00
|
|
|
#define RegEnumValue WINELIB_NAME_AW(RegEnumValue)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegOpenKeyA(HKEY,LPCSTR,PHKEY);
|
|
|
|
LSTATUS WINAPI RegOpenKeyW(HKEY,LPCWSTR,PHKEY);
|
1999-02-09 15:46:25 +00:00
|
|
|
#define RegOpenKey WINELIB_NAME_AW(RegOpenKey)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegQueryValueA(HKEY,LPCSTR,LPSTR,LPLONG);
|
|
|
|
LSTATUS WINAPI RegQueryValueW(HKEY,LPCWSTR,LPWSTR,LPLONG);
|
1999-02-09 15:46:25 +00:00
|
|
|
#define RegQueryValue WINELIB_NAME_AW(RegQueryValue)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegQueryValueExA(HKEY,LPCSTR,LPDWORD,LPDWORD,LPBYTE,LPDWORD);
|
|
|
|
LSTATUS WINAPI RegQueryValueExW(HKEY,LPCWSTR,LPDWORD,LPDWORD,LPBYTE,LPDWORD);
|
1999-02-09 15:46:25 +00:00
|
|
|
#define RegQueryValueEx WINELIB_NAME_AW(RegQueryValueEx)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegSetValueA(HKEY,LPCSTR,DWORD,LPCSTR,DWORD);
|
|
|
|
LSTATUS WINAPI RegSetValueW(HKEY,LPCWSTR,DWORD,LPCWSTR,DWORD);
|
1999-02-09 15:46:25 +00:00
|
|
|
#define RegSetValue WINELIB_NAME_AW(RegSetValue)
|
2007-09-17 22:40:48 +00:00
|
|
|
LSTATUS WINAPI RegSetValueExA(HKEY,LPCSTR,DWORD,DWORD,CONST BYTE*,DWORD);
|
|
|
|
LSTATUS WINAPI RegSetValueExW(HKEY,LPCWSTR,DWORD,DWORD,CONST BYTE*,DWORD);
|
1999-02-09 15:46:25 +00:00
|
|
|
#define RegSetValueEx WINELIB_NAME_AW(RegSetValueEx)
|
|
|
|
|
1999-06-12 10:53:06 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
} /* extern "C" */
|
|
|
|
#endif /* defined(__cplusplus) */
|
|
|
|
|
1996-03-31 16:40:13 +00:00
|
|
|
#endif /* __WINE_WINREG_H */
|