mirror of
https://github.com/reactos/reactos.git
synced 2025-02-22 16:36:33 +00:00
[DESK] Do not load system-defined class name
In fact Windows XP/2003 desk.cpl uses only user-defined values, and performs fallback to shell32.dll strings in case they are missing. CORE-18565 CORE-8427
This commit is contained in:
parent
6f03be8570
commit
9c21d0c124
1 changed files with 5 additions and 14 deletions
|
@ -285,20 +285,11 @@ DesktopOnInitDialog(IN HWND hwndDlg, IN PDESKTOP_DATA pData)
|
|||
if (SHGetValue(HKEY_CURRENT_USER, szClassPath, IconChange[i].IconName, &dwType,
|
||||
pData->LocalIcon[i].szTitle, &cbData) != ERROR_SUCCESS || dwType != REG_SZ)
|
||||
{
|
||||
/* Try loading system-defined class icon title */
|
||||
StringCchCopy(szClassPath, _countof(szClassPath), szSysClass);
|
||||
StringCchCat(szClassPath, _countof(szClassPath), IconChange[i].CLSID);
|
||||
cbData = sizeof(pData->LocalIcon[i].szTitle);
|
||||
|
||||
if (SHGetValue(HKEY_CLASSES_ROOT, szClassPath, IconChange[i].IconName, &dwType,
|
||||
pData->LocalIcon[i].szTitle, &cbData) != ERROR_SUCCESS || dwType != REG_SZ)
|
||||
{
|
||||
/* Fallback to predefined strings */
|
||||
LoadString(GetModuleHandle(TEXT("shell32.dll")),
|
||||
IconChange[i].TitleId,
|
||||
pData->LocalIcon[i].szTitle,
|
||||
_countof(pData->LocalIcon[i].szTitle));
|
||||
}
|
||||
/* Fallback to predefined strings */
|
||||
LoadString(GetModuleHandle(TEXT("shell32.dll")),
|
||||
IconChange[i].TitleId,
|
||||
pData->LocalIcon[i].szTitle,
|
||||
_countof(pData->LocalIcon[i].szTitle));
|
||||
}
|
||||
|
||||
hIcon = GetIconFromLocation(pData->LocalIcon[i].szPath);
|
||||
|
|
Loading…
Reference in a new issue