Remove ben's win/nsIconChannel.cpp dependency on IE allowing it to work on W95/NT4 again also fixing mingw builds p=lorenzo@colitti.com r=me sr=mscott

This commit is contained in:
neil%parkwaycc.co.uk 2004-06-29 20:16:00 +00:00
Родитель ae5e2bdd51
Коммит f0a4cfdf64
1 изменённых файлов: 7 добавлений и 7 удалений

Просмотреть файл

@ -249,14 +249,14 @@ static DWORD GetSpecialFolderIcon(nsIFile* aFile, int aFolder, SHFILEINFO* aSFI,
aFile->GetNativePath(fileNativePathStr);
::GetShortPathName(fileNativePathStr.get(), fileNativePath, sizeof(fileNativePath));
char specialNativePath[MAX_PATH];
::SHGetSpecialFolderPath(NULL, specialNativePath, aFolder, FALSE);
::GetShortPathName(specialNativePath, specialNativePath, sizeof(specialNativePath));
LPITEMIDLIST idList;
HRESULT hr = ::SHGetSpecialFolderLocation(NULL, aFolder, &idList);
if (SUCCEEDED(hr)) {
char specialNativePath[MAX_PATH];
::SHGetPathFromIDList(idList, specialNativePath);
::GetShortPathName(specialNativePath, specialNativePath, sizeof(specialNativePath));
if (nsDependentCString(fileNativePath).EqualsIgnoreCase(specialNativePath)) {
LPITEMIDLIST idList;
HRESULT hr = ::SHGetSpecialFolderLocation(NULL, aFolder, &idList);
if (SUCCEEDED(hr)) {
if (nsDependentCString(fileNativePath).EqualsIgnoreCase(specialNativePath)) {
aInfoFlags |= (SHGFI_PIDL | SHGFI_SYSICONINDEX);
shellResult = ::SHGetFileInfo((LPCTSTR)(LPCITEMIDLIST)idList, 0, aSFI,
sizeof(SHFILEINFO), aInfoFlags);