split wndproc into its own file

This commit is contained in:
freedom
2023-07-19 02:17:52 -06:00
parent 3d82ea0745
commit d2c8b2ba53
6 changed files with 132 additions and 56 deletions

View File

@@ -30,4 +30,37 @@ BOOL InitializeRegistryKeys()
return TRUE;
}
return FALSE;
}
}
/* * * *\
IsProgMgrDefaultShell -
Detects if Program Manager is the default shell.
RETURNS -
True if successful, false if unsuccessful.
\* * * */
#if 0
BOOL IsProgMgrDefaultShell()
{
HKEY hkeyWinlogon;
DWORD dwType;
DWORD cbBuffer;
if (RegOpenKeyEx(HKEY_LOCAL_MACHINE, SHELL_KEY, 0, KEY_READ, &hkeyWinlogon) == ERROR_SUCCESS) {
cbBuffer = sizeof(szBuffer);
if (RegQueryValueEx(hkeyWinlogon, L"Shell", 0, NULL, (LPBYTE)szBuffer, &cbBuffer) == ERROR_SUCCESS) {
CharLower(szBuffer);
lpt = szBuffer;
while (lpt = wcsstr(lpt, szProgmgr)) {
// we probably found progman
lpt += lstrlen(szProgmgr);
if (*lpt == TEXT(' ') || *lpt == TEXT('.') || *lpt == TEXT(',') || !*lpt)
bExitWindows = TRUE;
}
}
else {
// assume that progman is the shell.
bExitWindows = TRUE;
}
return FALSE;
}
#endif