21#define RSF_WHOLESTRING 0x00000001
22#define RSF_LOOKATKEYS 0x00000002
23#define RSF_LOOKATVALUES 0x00000004
24#define RSF_LOOKATDATA 0x00000008
25#define RSF_MATCHCASE 0x00010000
63 for(
i = 0;
i <= cch1 - cch2;
i++)
66 psz1 +
i, cch2, psz2, cch2) == 2)
77 return wcscmp(pszName1, pszName2) == 0;
79 return _wcsicmp(pszName1, pszName2) == 0;
102 for (
i = 0;
i <= cch1 - cch2;
i++)
131 LPWSTR *ppszFoundValueName)
147 wcscpy(szSubKey, pszSubKey);
159 if (ppszNames ==
NULL)
164 for(
i = 0;
i <
c;
i++)
188 fPast = (pszValueName ==
NULL);
191 for (
i = 0;
i <
c;
i++)
196 if (!fPast &&
_wcsicmp(ppszNames[
i], pszValueName) == 0)
207 *ppszFoundSubKey =
_wcsdup(szSubKey);
208 *ppszFoundValueName =
_wcsdup(ppszNames[
i]);
226 *ppszFoundSubKey =
_wcsdup(szSubKey);
227 *ppszFoundValueName =
_wcsdup(ppszNames[
i]);
234 if (ppszNames !=
NULL)
236 for(
i = 0;
i <
c;
i++)
248 if (ppszNames ==
NULL)
253 for(
i = 0;
i <
c;
i++)
277 for(
i = 0;
i <
c;
i++)
285 *ppszFoundSubKey =
malloc(
288 if (*ppszFoundSubKey ==
NULL)
292 wcscpy(*ppszFoundSubKey, szSubKey);
296 **ppszFoundSubKey = 0;
297 wcscat(*ppszFoundSubKey, ppszNames[
i]);
298 *ppszFoundValueName =
NULL;
306 LPWSTR psz = *ppszFoundSubKey;
307 *ppszFoundSubKey =
malloc(
309 if (*ppszFoundSubKey ==
NULL)
313 wcscpy(*ppszFoundSubKey, szSubKey);
317 **ppszFoundSubKey = 0;
318 wcscat(*ppszFoundSubKey, psz);
325 if (ppszNames !=
NULL)
327 for(
i = 0;
i <
c;
i++)
336 if (ppszNames !=
NULL)
338 for(
i = 0;
i <
c;
i++)
351 LPWSTR *ppszFoundValueName)
355 HKEY hBaseKey, hSubKey;
359 BOOL fPast, fKeyMatched;
367 if (
RegFindRecurse(hBaseKey, pszSubKey, pszValueName, ppszFoundSubKey,
371 wcscpy(szSubKey, pszSubKey);
372 while(szSubKey[0] != 0)
380 wcscpy(szKeyName, szSubKey);
400 if (ppszNames ==
NULL)
404 for(
i = 0;
i <
c;
i++)
425 for(
i = 0;
i <
c;
i++)
430 if (!fPast &&
_wcsicmp(ppszNames[
i], szKeyName) == 0)
441 *ppszFoundSubKey =
malloc(
444 if (*ppszFoundSubKey ==
NULL)
448 wcscpy(*ppszFoundSubKey, szSubKey);
452 **ppszFoundSubKey = 0;
453 wcscat(*ppszFoundSubKey, ppszNames[
i]);
454 *ppszFoundValueName =
NULL;
458 fKeyMatched = (
_wcsicmp(ppszNames[
i], szKeyName) == 0);
460 ppszFoundSubKey, ppszFoundValueName))
462 LPWSTR psz = *ppszFoundSubKey;
463 *ppszFoundSubKey =
malloc(
466 if (*ppszFoundSubKey ==
NULL)
470 wcscpy(*ppszFoundSubKey, szSubKey);
474 **ppszFoundSubKey = 0;
475 wcscat(*ppszFoundSubKey, psz);
480 if (ppszNames !=
NULL)
482 for(
i = 0;
i <
c;
i++)
488 if (hBaseKey != hSubKey)
525 if (ppszNames !=
NULL)
527 for(
i = 0;
i <
c;
i++)
531 if (hBaseKey != hSubKey)
536 if (ppszNames !=
NULL)
538 for(
i = 0;
i <
c;
i++)
542 if (hBaseKey != hSubKey)
551 DWORD dwType, dwValue, cbData;
557 cbData =
sizeof(dwValue);
561 dwFlags = (
dwFlags & ~0x0000FFFF) | ((dwValue & 0x0000FFFF) << 0);
565 cbData =
sizeof(dwValue);
569 dwFlags = (
dwFlags & ~0xFFFF0000) | ((dwValue & 0x0000FFFF) << 16);
628 WCHAR szFullKey[512];
630 LPWSTR pszFoundSubKey, pszFoundValueName;
641 if (pszKeyPath ==
NULL)
664 fSuccess =
RegFindWalk(&hKeyRoot, pszKeyPath, pszValueName,
665 &pszFoundSubKey, &pszFoundValueName);
682 free(pszFoundSubKey);
684 if (pszFoundValueName !=
NULL)
687 free(pszFoundValueName);
704 static WCHAR s_szSavedFindValue[256];
798 if (s_szSavedFindValue[0])
799 lStyle &= ~WS_DISABLED;
const TCHAR g_szGeneralRegKey[]
BOOL GetKeyName(LPWSTR pszDest, size_t iDestLength, HKEY hRootKey, LPCWSTR lpSubKey)
BOOL RegFindRecurse(HKEY hKey, LPCWSTR pszSubKey, LPCWSTR pszValueName, LPWSTR *ppszFoundSubKey, LPWSTR *ppszFoundValueName)
static WCHAR s_szName[MAX_PATH]
static BOOL CompareName(LPCWSTR pszName1, LPCWSTR pszName2)
void FindNextMessageBox(HWND hWnd)
VOID SetValueName(HWND hwndLV, LPCWSTR pszValueName)
BOOL RegFindWalk(HKEY *phKey, LPCWSTR pszSubKey, LPCWSTR pszValueName, LPWSTR *ppszFoundSubKey, LPWSTR *ppszFoundValueName)
static INT_PTR CALLBACK FindDialogProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
static void SetFindFlags(DWORD dwFlags)
static HWND s_hwndAbortDialog
static const WCHAR s_szFindFlagsR[]
static const WCHAR s_empty[]
static INT_PTR CALLBACK AbortFindDialogProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
static BOOL MatchString(LPCWCH pch1, INT cch1, LPCWCH pch2, INT cch2)
void FindDialog(HWND hWnd)
static LPWSTR lstrstri(LPCWSTR psz1, LPCWSTR psz2)
static DWORD GetFindFlags(void)
static WCHAR s_szFindWhat[256]
static const WCHAR s_szFindFlags[]
static const WCHAR s_backslash[]
WCHAR * GetValueName(HWND hwndLV, int iStartAt)
BOOL SelectNode(HWND hwndTV, LPCWSTR keyPath)
LPCWSTR GetItemPath(HWND hwndTV, HTREEITEM hItem, HKEY *phRootKey)
#define IDC_LOOKAT_VALUES
#define RegCloseKey(hKey)
LONG WINAPI RegCreateKeyExW(_In_ HKEY hKey, _In_ LPCWSTR lpSubKey, _In_ DWORD Reserved, _In_opt_ LPWSTR lpClass, _In_ DWORD dwOptions, _In_ REGSAM samDesired, _In_opt_ LPSECURITY_ATTRIBUTES lpSecurityAttributes, _Out_ PHKEY phkResult, _Out_opt_ LPDWORD lpdwDisposition)
LONG WINAPI RegOpenKeyExW(HKEY hKey, LPCWSTR lpSubKey, DWORD ulOptions, REGSAM samDesired, PHKEY phkResult)
LONG WINAPI RegEnumKeyExW(_In_ HKEY hKey, _In_ DWORD dwIndex, _Out_ LPWSTR lpName, _Inout_ LPDWORD lpcbName, _Reserved_ LPDWORD lpReserved, _Out_opt_ LPWSTR lpClass, _Inout_opt_ LPDWORD lpcbClass, _Out_opt_ PFILETIME lpftLastWriteTime)
LONG WINAPI RegOpenKeyW(HKEY hKey, LPCWSTR lpSubKey, PHKEY phkResult)
LONG WINAPI RegSetValueExW(_In_ HKEY hKey, _In_ LPCWSTR lpValueName, _In_ DWORD Reserved, _In_ DWORD dwType, _In_ CONST BYTE *lpData, _In_ DWORD cbData)
LONG WINAPI RegEnumValueW(_In_ HKEY hKey, _In_ DWORD index, _Out_ LPWSTR value, _Inout_ PDWORD val_count, _Reserved_ PDWORD reserved, _Out_opt_ PDWORD type, _Out_opt_ LPBYTE data, _Inout_opt_ PDWORD count)
LONG WINAPI RegQueryInfoKeyW(HKEY hKey, LPWSTR lpClass, LPDWORD lpcClass, LPDWORD lpReserved, LPDWORD lpcSubKeys, LPDWORD lpcMaxSubKeyLen, LPDWORD lpcMaxClassLen, LPDWORD lpcValues, LPDWORD lpcMaxValueNameLen, LPDWORD lpcMaxValueLen, LPDWORD lpcbSecurityDescriptor, PFILETIME lpftLastWriteTime)
LONG WINAPI RegQueryValueExW(_In_ HKEY hkeyorg, _In_ LPCWSTR name, _In_ LPDWORD reserved, _In_ LPDWORD type, _In_ LPBYTE data, _In_ LPDWORD count)
#define ERROR_NO_MORE_ITEMS
GLint GLint GLint GLint GLint x
GLuint GLuint GLsizei GLenum type
GLint GLint GLint GLint GLint GLint y
GLboolean GLboolean GLboolean b
GLboolean GLboolean GLboolean GLboolean a
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
_CRTIMP size_t __cdecl wcslen(_In_z_ const wchar_t *_Str)
_CONST_RETURN wchar_t *__cdecl wcsstr(_In_z_ const wchar_t *_Str, _In_z_ const wchar_t *_SubStr)
INT WINAPI CompareStringW(LCID lcid, DWORD flags, LPCWSTR str1, INT len1, LPCWSTR str2, INT len2)
static HANDLE ULONG_PTR dwData
static HMODULE MODULEINFO DWORD cb
#define REG_OPTION_NON_VOLATILE
#define LOCALE_SYSTEM_DEFAULT
#define UNREFERENCED_PARAMETER(P)
_Check_return_ _CRTIMP int __cdecl _wcsicmp(_In_z_ const wchar_t *_Str1, _In_z_ const wchar_t *_Str2)
_CRTIMP wchar_t *__cdecl wcscpy(_Out_writes_z_(_String_length_(_Source)+1) wchar_t *_Dest, _In_z_ const wchar_t *_Source)
_Check_return_ _CRTIMP int __cdecl wcscmp(_In_z_ const wchar_t *_Str1, _In_z_ const wchar_t *_Str2)
_Check_return_ _CRTIMP wchar_t *__cdecl _wcsdup(_In_z_ const wchar_t *_Str)
_CRTIMP wchar_t *__cdecl wcscat(_Inout_updates_z_(_String_length_(_Dest)+_String_length_(_Source)+1) wchar_t *_Dest, _In_z_ const wchar_t *_Source)
void __cdecl qsort(_Inout_updates_bytes_(_NumOfElements *_SizeOfElements) void *_Base, _In_ size_t _NumOfElements, _In_ size_t _SizeOfElements, _In_ int(__cdecl *_PtFuncCompare)(const void *, const void *))
TW_UINT32 TW_UINT16 TW_UINT16 MSG
int WINAPI GetWindowTextW(HWND hWnd, LPWSTR lpString, int nMaxCount)
#define success(from, fromstr, to, tostr)
_In_ PCCERT_CONTEXT _In_ DWORD dwFlags
#define HKEY_LOCAL_MACHINE
#define HKEY_CURRENT_CONFIG
#define HKEY_CURRENT_USER
#define HKEY_CLASSES_ROOT
BOOL WINAPI RedrawWindow(_In_opt_ HWND, _In_opt_ LPCRECT, _In_opt_ HRGN, _In_ UINT)
BOOL WINAPI TranslateMessage(_In_ const MSG *)
BOOL WINAPI ShowWindow(_In_ HWND, _In_ int)
BOOL WINAPI IsDialogMessageW(_In_ HWND, _In_ LPMSG)
int WINAPI LoadStringW(_In_opt_ HINSTANCE hInstance, _In_ UINT uID, _Out_writes_to_(cchBufferMax, return+1) LPWSTR lpBuffer, _In_ int cchBufferMax)
int WINAPI MessageBoxW(_In_opt_ HWND hWnd, _In_opt_ LPCWSTR lpText, _In_opt_ LPCWSTR lpCaption, _In_ UINT uType)
HWND WINAPI GetDlgItem(_In_opt_ HWND, _In_ int)
BOOL WINAPI SetWindowTextW(_In_ HWND, _In_opt_ LPCWSTR)
HWND WINAPI SetFocus(_In_opt_ HWND)
BOOL WINAPI PeekMessageW(_Out_ LPMSG, _In_opt_ HWND, _In_ UINT, _In_ UINT, _In_ UINT)
BOOL WINAPI UpdateWindow(_In_ HWND)
BOOL WINAPI EnableWindow(_In_ HWND, _In_ BOOL)
#define CreateDialogW(h, n, w, f)
LRESULT WINAPI DispatchMessageW(_In_ const MSG *)
#define MB_ICONINFORMATION
#define MAKEINTRESOURCEW(i)
BOOL WINAPI DestroyWindow(_In_ HWND)
LRESULT WINAPI SendMessageW(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
INT_PTR WINAPI DialogBoxParamW(_In_opt_ HINSTANCE, _In_ LPCWSTR, _In_opt_ HWND, _In_opt_ DLGPROC, _In_ LPARAM)
BOOL WINAPI EndDialog(_In_ HWND, _In_ INT_PTR)
_IRQL_requires_same_ _In_ PVOID _In_ PVOID MatchData