Re: [2/2] shell32: Add proper support for SHGetFileInfo(SHGFI_ICONLOCATION | SHGFI_USEFILEATTRIBUTES).
On 18.01.2007 16:23, Francois Gouget wrote:
+ if (dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) + { + lstrcpyW(psfi->szDisplayName, swShell32Name); + psfi->iIcon = -IDI_SHELL_FOLDER; + }
At least on Windows, folders have a file type, too - see HKCR\Folder. So maybe use 'HCR_GetDefaultIconW(L"Folder", ...)' when the directory attribute is set, and 'HCR_GetDefaultIconW(sTemp, ...)' otherwise? -f.r.
On Thu, 18 Jan 2007, Frank Richter wrote:
On 18.01.2007 16:23, Francois Gouget wrote:
+ if (dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) + { + lstrcpyW(psfi->szDisplayName, swShell32Name); + psfi->iIcon = -IDI_SHELL_FOLDER; + }
At least on Windows, folders have a file type, too - see HKCR\Folder. So maybe use 'HCR_GetDefaultIconW(L"Folder", ...)' when the directory attribute is set, and 'HCR_GetDefaultIconW(sTemp, ...)' otherwise?
Are you sure? I have rigged the test to print the values returned by this SHGetFileInfo() test, and then I modified the HKCR\Folder\DefaultIcon value. However I observed no change in the test output. It also had no effect on the icon shown in the Windows Explorer. -- Francois Gouget <fgouget(a)free.fr> http://fgouget.free.fr/ Before you criticize someone, walk a mile in his shoes. That way, if he gets angry, he'll be a mile away - and barefoot.
participants (2)
-
Francois Gouget -
Frank Richter