Correct failing test and transform it into a bunch of another tests.
[wine.git] / dlls / shell32 / shellreg.c
blob700ab519d8f0d5063151b517434f12c1005be1e7
1 /*
2 * Shell Registry Access
4 * Copyright 2000 Juergen Schmied
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2.1 of the License, or (at your option) any later version.
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with this library; if not, write to the Free Software
18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
21 #include "config.h"
23 #include <string.h>
24 #include <stdarg.h>
25 #include <stdio.h>
27 #include "windef.h"
28 #include "winbase.h"
29 #include "shellapi.h"
30 #include "wingdi.h"
31 #include "winuser.h"
32 #include "shlobj.h"
33 #include "winerror.h"
34 #include "winreg.h"
35 #include "winnls.h"
37 #include "undocshell.h"
38 #include "wine/winbase16.h"
40 #include "wine/debug.h"
42 WINE_DEFAULT_DEBUG_CHANNEL(shell);
44 /*************************************************************************
45 * SHRegOpenKeyA [SHELL32.506]
48 HRESULT WINAPI SHRegOpenKeyA(
49 HKEY hKey,
50 LPSTR lpSubKey,
51 PHKEY phkResult)
53 TRACE("(%p, %s, %p)\n", hKey, debugstr_a(lpSubKey), phkResult);
54 return RegOpenKeyA(hKey, lpSubKey, phkResult);
57 /*************************************************************************
58 * SHRegOpenKeyW [SHELL32.507] NT 4.0
61 HRESULT WINAPI SHRegOpenKeyW (
62 HKEY hkey,
63 LPCWSTR lpszSubKey,
64 PHKEY retkey)
66 WARN("%p %s %p\n",hkey,debugstr_w(lpszSubKey),retkey);
67 return RegOpenKeyW( hkey, lpszSubKey, retkey );
70 /*************************************************************************
71 * SHRegQueryValueExA [SHELL32.509]
74 HRESULT WINAPI SHRegQueryValueExA(
75 HKEY hkey,
76 LPSTR lpValueName,
77 LPDWORD lpReserved,
78 LPDWORD lpType,
79 LPBYTE lpData,
80 LPDWORD lpcbData)
82 TRACE("%p %s %p %p %p %p\n", hkey, lpValueName, lpReserved, lpType, lpData, lpcbData);
83 return RegQueryValueExA (hkey, lpValueName, lpReserved, lpType, lpData, lpcbData);
86 /*************************************************************************
87 * SHRegQueryValueW [SHELL32.510] NT4.0
90 HRESULT WINAPI SHRegQueryValueW(
91 HKEY hkey,
92 LPWSTR lpszSubKey,
93 LPWSTR lpszData,
94 LPDWORD lpcbData )
96 WARN("%p %s %p %p semi-stub\n",
97 hkey, debugstr_w(lpszSubKey), lpszData, lpcbData);
98 return RegQueryValueW( hkey, lpszSubKey, lpszData, lpcbData );
101 /*************************************************************************
102 * SHRegQueryValueExW [SHELL32.511] NT4.0
104 * FIXME
105 * if the datatype REG_EXPAND_SZ then expand the string and change
106 * *pdwType to REG_SZ.
108 HRESULT WINAPI SHRegQueryValueExW (
109 HKEY hkey,
110 LPWSTR pszValue,
111 LPDWORD pdwReserved,
112 LPDWORD pdwType,
113 LPVOID pvData,
114 LPDWORD pcbData)
116 DWORD ret;
117 WARN("%p %s %p %p %p %p semi-stub\n",
118 hkey, debugstr_w(pszValue), pdwReserved, pdwType, pvData, pcbData);
119 ret = RegQueryValueExW ( hkey, pszValue, pdwReserved, pdwType, pvData, pcbData);
120 return ret;
123 /*************************************************************************
124 * SHRegDeleteKeyA [SHELL32.?]
126 HRESULT WINAPI SHRegDeleteKeyA(
127 HKEY hkey,
128 LPCSTR pszSubKey)
130 FIXME("hkey=%p, %s\n", hkey, debugstr_a(pszSubKey));
131 return 0;
134 /*************************************************************************
135 * SHRegDeleteKeyW [SHELL32.512]
137 HRESULT WINAPI SHRegDeleteKeyW(
138 HKEY hkey,
139 LPCWSTR pszSubKey)
141 FIXME("hkey=%p, %s\n", hkey, debugstr_w(pszSubKey));
142 return 0;
145 /*************************************************************************
146 * SHRegCloseKey [SHELL32.505] NT 4.0
149 HRESULT WINAPI SHRegCloseKey (HKEY hkey)
151 TRACE("%p\n",hkey);
152 return RegCloseKey( hkey );