mirror of
https://github.com/reactos/reactos.git
synced 2025-02-23 17:05:46 +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
|
@ -284,14 +284,6 @@ DesktopOnInitDialog(IN HWND hwndDlg, IN PDESKTOP_DATA pData)
|
||||||
|
|
||||||
if (SHGetValue(HKEY_CURRENT_USER, szClassPath, IconChange[i].IconName, &dwType,
|
if (SHGetValue(HKEY_CURRENT_USER, szClassPath, IconChange[i].IconName, &dwType,
|
||||||
pData->LocalIcon[i].szTitle, &cbData) != ERROR_SUCCESS || dwType != REG_SZ)
|
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 */
|
/* Fallback to predefined strings */
|
||||||
LoadString(GetModuleHandle(TEXT("shell32.dll")),
|
LoadString(GetModuleHandle(TEXT("shell32.dll")),
|
||||||
|
@ -299,7 +291,6 @@ DesktopOnInitDialog(IN HWND hwndDlg, IN PDESKTOP_DATA pData)
|
||||||
pData->LocalIcon[i].szTitle,
|
pData->LocalIcon[i].szTitle,
|
||||||
_countof(pData->LocalIcon[i].szTitle));
|
_countof(pData->LocalIcon[i].szTitle));
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
hIcon = GetIconFromLocation(pData->LocalIcon[i].szPath);
|
hIcon = GetIconFromLocation(pData->LocalIcon[i].szPath);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue