Small fixes.

This commit is contained in:
Juergen Schmied 1998-12-18 14:52:08 +00:00 committed by Alexandre Julliard
parent e304228fe2
commit dd2e59c913
7 changed files with 21 additions and 17 deletions

View File

@ -14,7 +14,7 @@
#include "shell32_main.h" #include "shell32_main.h"
BOOL32 HCR_MapTypeToValue ( LPSTR szExtension, LPSTR szFileType, DWORD len) BOOL32 HCR_MapTypeToValue ( LPCSTR szExtension, LPSTR szFileType, DWORD len)
{ HKEY hkey; { HKEY hkey;
TRACE(shell, "%s %p\n",szExtension, szFileType ); TRACE(shell, "%s %p\n",szExtension, szFileType );

View File

@ -6,6 +6,7 @@
* Copyright 1998 <juergen.schmied@metronet.de> * Copyright 1998 <juergen.schmied@metronet.de>
*/ */
#include "debug.h" #include "debug.h"
#include "wintypes.h"
#include "shlobj.h" #include "shlobj.h"
#include "pidl.h" #include "pidl.h"
#include "winerror.h" #include "winerror.h"

View File

@ -512,7 +512,7 @@ static INT32 SIC_LoadIcon (LPCSTR sSourceFile, INT32 dwSourceIndex)
* look in the cache for a proper icon. if not available the icon is taken * look in the cache for a proper icon. if not available the icon is taken
* from the file and cached * from the file and cached
*/ */
static INT32 SIC_GetIconIndex (LPCSTR sSourceFile, INT32 dwSourceIndex ) INT32 SIC_GetIconIndex (LPCSTR sSourceFile, INT32 dwSourceIndex )
{ SIC_ENTRY sice; { SIC_ENTRY sice;
INT32 index; INT32 index;
@ -643,7 +643,7 @@ DWORD WINAPI SHMapPIDLToSystemImageListIndex(LPSHELLFOLDER sh,LPITEMIDLIST pidl,
DWORD dwNr, ret = INVALID_INDEX; DWORD dwNr, ret = INVALID_INDEX;
LPITEMIDLIST pidltemp = ILFindLastID(pidl); LPITEMIDLIST pidltemp = ILFindLastID(pidl);
WARN(shell,"(SF=%p,pidl=%p,%08lx)\n",sh,pidl,z); WARN(shell,"(SF=%p,pidl=%p,0x%08x)\n",sh,pidl,z);
pdump(pidl); pdump(pidl);
if (_ILIsDesktop(pidltemp)) if (_ILIsDesktop(pidltemp))
@ -652,7 +652,7 @@ DWORD WINAPI SHMapPIDLToSystemImageListIndex(LPSHELLFOLDER sh,LPITEMIDLIST pidl,
else if (_ILIsMyComputer(pidltemp)) else if (_ILIsMyComputer(pidltemp))
{ if (HCR_GetDefaultIcon("CLSID\\{20D04FE0-3AEA-1069-A2D8-08002B30309D}", sTemp, 64, &dwNr)) { if (HCR_GetDefaultIcon("CLSID\\{20D04FE0-3AEA-1069-A2D8-08002B30309D}", sTemp, 64, &dwNr))
{ ret = SIC_GetIconIndex(sTemp, dwNr); { ret = SIC_GetIconIndex(sTemp, dwNr);
return (( INVALID_INDEX == ret) ? 20 : ret); return (( INVALID_INDEX == ret) ? 15 : ret);
} }
} }
else if (_ILIsDrive (pidltemp)) else if (_ILIsDrive (pidltemp))

View File

@ -33,11 +33,20 @@ extern LPVOID (CALLBACK* pDPA_GetPtr) (const HDPA, INT32);
extern BOOL32 (CALLBACK* pDPA_Destroy) (const HDPA); extern BOOL32 (CALLBACK* pDPA_Destroy) (const HDPA);
extern INT32 (CALLBACK* pDPA_Search) (const HDPA, LPVOID, INT32, PFNDPACOMPARE, LPARAM, UINT32); extern INT32 (CALLBACK* pDPA_Search) (const HDPA, LPVOID, INT32, PFNDPACOMPARE, LPARAM, UINT32);
LPITEMIDLIST WINAPI ILClone (LPCITEMIDLIST pidl);
LPITEMIDLIST WINAPI ILGetNext(LPITEMIDLIST pidl);
LPITEMIDLIST WINAPI ILCombine(LPCITEMIDLIST iil1,LPCITEMIDLIST iil2);
LPITEMIDLIST WINAPI ILFindLastID(LPITEMIDLIST pidl);
DWORD WINAPI ILGetSize(LPITEMIDLIST pidl);
LPITEMIDLIST WINAPI ILCreateFromPath(LPVOID path);
/* Iconcache */ /* Iconcache */
#define INVALID_INDEX -1
BOOL32 SIC_Initialize(void); BOOL32 SIC_Initialize(void);
INT32 SIC_GetIconIndex (LPCSTR sSourceFile, INT32 dwSourceIndex );
/* Classes Root */ /* Classes Root */
BOOL32 HCR_MapTypeToValue ( LPSTR szExtension, LPSTR szFileType, DWORD len); BOOL32 HCR_MapTypeToValue ( LPCSTR szExtension, LPSTR szFileType, DWORD len);
BOOL32 HCR_GetExecuteCommand ( LPCSTR szClass, LPCSTR szVerb, LPSTR szDest, DWORD len ); BOOL32 HCR_GetExecuteCommand ( LPCSTR szClass, LPCSTR szVerb, LPSTR szDest, DWORD len );
BOOL32 HCR_GetDefaultIcon (LPCSTR szClass, LPSTR szDest, DWORD len, LPDWORD dwNr); BOOL32 HCR_GetDefaultIcon (LPCSTR szClass, LPSTR szDest, DWORD len, LPDWORD dwNr);

View File

@ -225,7 +225,7 @@ static HRESULT WINAPI IShellFolder_ParseDisplayName(
LPITEMIDLIST pidlFull=NULL, pidlTemp = NULL, pidlOld = NULL; LPITEMIDLIST pidlFull=NULL, pidlTemp = NULL, pidlOld = NULL;
LPSTR pszTemp, pszNext=NULL; LPSTR pszTemp, pszNext=NULL;
CHAR szElement[MAX_PATH]; CHAR szElement[MAX_PATH];
BOOL32 bType; BOOL32 bIsFile;
DWORD dwChars; DWORD dwChars;
TRACE(shell,"(%p)->(HWND=0x%08x,%p,%p=%s,%p,pidl=%p,%p)\n", TRACE(shell,"(%p)->(HWND=0x%08x,%p,%p=%s,%p,pidl=%p,%p)\n",
@ -250,9 +250,9 @@ static HRESULT WINAPI IShellFolder_ParseDisplayName(
{ pidlFull = _ILCreateMyComputer(); { pidlFull = _ILCreateMyComputer();
/* check if the lpszDisplayName is Folder or File*/ /* check if the lpszDisplayName is Folder or File*/
bType = ! (GetFileAttributes32A(pszNext) & FILE_ATTRIBUTE_DIRECTORY); bIsFile = ! (GetFileAttributes32A(pszTemp) & FILE_ATTRIBUTE_DIRECTORY);
pszNext = GetNextElement(pszTemp, szElement, MAX_PATH); pszNext = GetNextElement(pszTemp, szElement, MAX_PATH);
pidlTemp = _ILCreateDrive(szElement); pidlTemp = _ILCreateDrive(szElement);
pidlOld = pidlFull; pidlOld = pidlFull;
pidlFull = ILCombine(pidlFull,pidlTemp); pidlFull = ILCombine(pidlFull,pidlTemp);
@ -260,7 +260,7 @@ static HRESULT WINAPI IShellFolder_ParseDisplayName(
if(pidlFull) if(pidlFull)
{ while((pszNext=GetNextElement(pszNext, szElement, MAX_PATH))) { while((pszNext=GetNextElement(pszNext, szElement, MAX_PATH)))
{ if(!*pszNext && bType) { if(!*pszNext && bIsFile)
{ pidlTemp = _ILCreateValue(szElement); { pidlTemp = _ILCreateValue(szElement);
} }
else else

View File

@ -130,12 +130,6 @@ typedef struct
} ITEMIDLIST,*LPITEMIDLIST,*LPCITEMIDLIST; } ITEMIDLIST,*LPITEMIDLIST,*LPCITEMIDLIST;
#pragma pack(4) #pragma pack(4)
LPITEMIDLIST WINAPI ILClone (LPCITEMIDLIST pidl);
LPITEMIDLIST WINAPI ILGetNext(LPITEMIDLIST pidl);
LPITEMIDLIST WINAPI ILCombine(LPCITEMIDLIST iil1,LPCITEMIDLIST iil2);
LPITEMIDLIST WINAPI ILFindLastID(LPITEMIDLIST pidl);
DWORD WINAPI ILGetSize(LPITEMIDLIST pidl);
DWORD WINAPI SHGetPathFromIDList32A (LPCITEMIDLIST pidl,LPSTR pszPath); DWORD WINAPI SHGetPathFromIDList32A (LPCITEMIDLIST pidl,LPSTR pszPath);
DWORD WINAPI SHGetPathFromIDList32W (LPCITEMIDLIST pidl,LPWSTR pszPath); DWORD WINAPI SHGetPathFromIDList32W (LPCITEMIDLIST pidl,LPWSTR pszPath);
#define SHGetPathFromIDList WINELIB_NAME_AW(SHGetPathFromIDList) #define SHGetPathFromIDList WINELIB_NAME_AW(SHGetPathFromIDList)

View File

@ -13,7 +13,7 @@ init Shell32LibMain
5 stub SHChangeNotifyUpdateEntryList@16 5 stub SHChangeNotifyUpdateEntryList@16
6 stub CheckEscapesW@8 6 stub CheckEscapesW@8
7 stdcall CommandLineToArgvW(wstr ptr) CommandLineToArgvW 7 stdcall CommandLineToArgvW(wstr ptr) CommandLineToArgvW
8 stub Control_FillCache_RunDLL@16 8 stdcall Control_FillCache_RunDLL (long long long long) Control_FillCache_RunDLL
9 stub PifMgr_OpenProperties@16 9 stub PifMgr_OpenProperties@16
10 stub PifMgr_GetProperties@20 10 stub PifMgr_GetProperties@20
11 stub PifMgr_SetProperties@20 11 stub PifMgr_SetProperties@20
@ -63,7 +63,7 @@ init Shell32LibMain
55 stdcall PathQuoteSpaces (ptr) PathQuoteSpaces32AW 55 stdcall PathQuoteSpaces (ptr) PathQuoteSpaces32AW
56 stdcall PathUnquoteSpaces(str) PathUnquoteSpaces 56 stdcall PathUnquoteSpaces(str) PathUnquoteSpaces
57 stdcall PathGetDriveNumber (str) PathGetDriveNumber32 57 stdcall PathGetDriveNumber (str) PathGetDriveNumber32
58 stdcall ParseField(str long str long) ParseField32A 58 stdcall ParseField(str long ptr long) ParseField32A
59 stub RestartDialog@12 59 stub RestartDialog@12
60 stdcall ExitWindowsDialog(long) ExitWindowsDialog 60 stdcall ExitWindowsDialog(long) ExitWindowsDialog
61 stdcall RunFileDlg(long long long str str long) RunFileDlg 61 stdcall RunFileDlg(long long long str str long) RunFileDlg