Commit 51c74d82 authored by Juergen Schmied's avatar Juergen Schmied Committed by Alexandre Julliard

Complete cleanup, bugfixes.

New: PathStripPath, PathMakeUniqueName, PathStripToRoot, PathGetShortPath, PathParseIconLocation, PathRemoveExtension, PathRemoveArgs, PathAppend, PathBuildRoot, PathCanonicalize, PathFindNextComponent, PathRemoveFileSpec.
parent 24f4cdc6
......@@ -278,6 +278,6 @@ LPITEMIDLIST WINAPI SHBrowseForFolderA (LPBROWSEINFOA lpbi)
TRACE("(%lx,%s) empty stub!\n", (DWORD)lpbi, lpbi->lpszTitle);
return (LPITEMIDLIST) DialogBoxParamA( shell32_hInstance,
"SHBRSFORFOLDER_MSGBOX", 0,
"SHBRSFORFOLDER_MSGBOX", lpbi->hwndOwner,
BrsFolderDlgProc, (INT)lpbi );
}
......@@ -8,6 +8,7 @@
*/
#define INITGUID
#include "shlwapi.h"
/* #include "shlguid.h" */
/*
......
......@@ -8,16 +8,33 @@
#include "winversion.h"
#include "shlobj.h"
#include "shresdef.h"
#include "wine/undocshell.h"
DEFAULT_DEBUG_CHANNEL(shell);
#define ASK_DELETE_FILE 1
#define ASK_DELETE_FOLDER 2
#define ASK_DELETE_MULTIPLE_FILE 3
static BOOL SHELL_WarnFolderDelete (int nKindOfDialog, LPCSTR szDir)
{
char szCaption[255], szText[255], szBuffer[256];
LoadStringA(shell32_hInstance, IDS_DELETEFOLDER_TEXT, szText, sizeof(szText));
LoadStringA(shell32_hInstance, IDS_DELETEFOLDER_CAPTION, szCaption, sizeof(szCaption));
FormatMessageA(FORMAT_MESSAGE_FROM_STRING, szText, 0,0, szBuffer, sizeof(szBuffer), (DWORD*)&szDir);
return (IDOK == MessageBoxA(GetActiveWindow(),szText, szCaption, MB_OKCANCEL | MB_ICONEXCLAMATION));
}
/**************************************************************************
* SHELL_DeleteDirectoryA()
*
* like rm -r
*/
BOOL SHELL_DeleteDirectoryA(LPCSTR pszDir)
BOOL SHELL_DeleteDirectoryA(LPCSTR pszDir, BOOL bShowUI)
{
BOOL ret = FALSE;
HANDLE hFind;
......@@ -28,6 +45,8 @@ BOOL SHELL_DeleteDirectoryA(LPCSTR pszDir)
PathAddBackslashA(szTemp);
strcat(szTemp, "*.*");
if (bShowUI && !SHELL_WarnFolderDelete(ASK_DELETE_FOLDER, pszDir)) return FALSE;
if(INVALID_HANDLE_VALUE != (hFind = FindFirstFileA(szTemp, &wfd)))
{
do
......@@ -39,7 +58,7 @@ BOOL SHELL_DeleteDirectoryA(LPCSTR pszDir)
strcat(szTemp, wfd.cFileName);
if(FILE_ATTRIBUTE_DIRECTORY & wfd.dwFileAttributes)
SHELL_DeleteDirectoryA(szTemp);
SHELL_DeleteDirectoryA(szTemp, FALSE);
else
DeleteFileA(szTemp);
}
......@@ -124,3 +143,22 @@ DWORD WINAPI SHFileOperationAW(LPVOID lpFileOp)
return SHFileOperationW(lpFileOp);
return SHFileOperationA(lpFileOp);
}
/*************************************************************************
* SheGetDirW [SHELL32.281]
*
*/
HRESULT WINAPI SheGetDirW(LPWSTR u, LPWSTR v)
{ FIXME("%p %p stub\n",u,v);
return 0;
}
/*************************************************************************
* SheChangeDirW [SHELL32.274]
*
*/
HRESULT WINAPI SheChangeDirW(LPWSTR u)
{ FIXME("(%s),stub\n",debugstr_w(u));
return 0;
}
......@@ -209,6 +209,70 @@ static HRESULT SHELL32_GetDisplayNameOfChild(
}
/***********************************************************************
* SHELL32_GetItemAttributes
*
* NOTES
* observerd values:
* folder: 0xE0000177 FILESYSTEM | HASSUBFOLDER | FOLDER
* file: 0x40000177 FILESYSTEM
* drive: 0xf0000144 FILESYSTEM | HASSUBFOLDER | FOLDER | FILESYSANCESTOR
* mycomputer: 0xb0000154 HASSUBFOLDER | FOLDER | FILESYSANCESTOR
* (seems to be default for shell extensions if no registry entry exists)
*
* This functions does not set flags!! It only resets flags when nessesary.
*/
static HRESULT SHELL32_GetItemAttributes(
IShellFolder * psf,
LPITEMIDLIST pidl,
LPDWORD pdwAttributes)
{
GUID const * clsid;
DWORD dwAttributes;
TRACE("0x%08lx\n", *pdwAttributes);
if (*pdwAttributes & (0xcff3fe88))
WARN("attribute 0x%08lx not implemented\n", *pdwAttributes);
*pdwAttributes &= ~SFGAO_LINK; /* FIXME: for native filedialogs */
if (_ILIsDrive(pidl))
{
*pdwAttributes &= 0xf0000144;
}
else if ((clsid=_ILGetGUIDPointer(pidl)))
{
if (HCR_GetFolderAttributes(clsid, &dwAttributes))
{
*pdwAttributes &= dwAttributes;
}
else
{
*pdwAttributes &= 0xb0000154;
}
}
else if (_ILGetDataPointer(pidl))
{
dwAttributes = _ILGetFileAttributes(pidl, NULL, 0);
*pdwAttributes &= ~SFGAO_FILESYSANCESTOR;
if(( SFGAO_FOLDER & *pdwAttributes) && !(dwAttributes & FILE_ATTRIBUTE_DIRECTORY))
*pdwAttributes &= ~(SFGAO_FOLDER|SFGAO_HASSUBFOLDER);
if(( SFGAO_HIDDEN & *pdwAttributes) && !(dwAttributes & FILE_ATTRIBUTE_HIDDEN))
*pdwAttributes &= ~SFGAO_HIDDEN;
if(( SFGAO_READONLY & *pdwAttributes) && !(dwAttributes & FILE_ATTRIBUTE_READONLY))
*pdwAttributes &= ~SFGAO_READONLY;
}
else
{
*pdwAttributes &= 0xb0000154;
}
TRACE("-- 0x%08lx\n", *pdwAttributes);
return S_OK;
}
/***********************************************************************
* IShellFolder implementation
*/
......@@ -604,6 +668,17 @@ static HRESULT WINAPI IShellFolder_fnParseDisplayName(
}
else
{
if (pdwAttributes && *pdwAttributes)
{
SHELL32_GetItemAttributes(_IShellFolder_(This), pidlTemp, pdwAttributes);
/* WIN32_FIND_DATAA fd;
SHGetDataFromIDListA(_IShellFolder_(This), pidlTemp, SHGDFIL_FINDDATA, &fd, sizeof(fd));
if (!(FILE_ATTRIBUTE_DIRECTORY & fd.dwFileAttributes))
*pdwAttributes &= ~SFGAO_FOLDER;
if (FILE_ATTRIBUTE_READONLY & fd.dwFileAttributes)
*pdwAttributes &= ~(SFGAO_CANDELETE|SFGAO_CANMOVE|SFGAO_CANRENAME );
*/
}
hr = S_OK;
}
}
......@@ -682,12 +757,17 @@ static HRESULT WINAPI IShellFolder_fnBindToObject( IShellFolder2 * iface, LPCITE
return E_FAIL;
}
}
else
else if(_ILIsFolder(pidl))
{
LPITEMIDLIST pidltemp = ILCloneFirst(pidl);
pShellFolder = IShellFolder_Constructor(iface, pidltemp);
ILFree(pidltemp);
}
else
{
ERR("can't bind to a file\n");
return E_FAIL;
}
if (_ILIsPidlSimple(pidl))
{
......@@ -901,19 +981,8 @@ static HRESULT WINAPI IShellFolder_fnGetAttributesOf(
while (cidl > 0 && *apidl)
{
pdump (*apidl);
if (_ILIsFolder( *apidl))
{
*rgfInOut &= 0xe0000177;
goto next;
}
else if (_ILIsValue( *apidl))
{
*rgfInOut &= 0x40000177;
goto next;
}
hr = E_INVALIDARG;
next: apidl++;
SHELL32_GetItemAttributes(_IShellFolder_(This), *apidl, rgfInOut);
apidl++;
cidl--;
}
......@@ -1436,7 +1505,7 @@ static HRESULT WINAPI ISFHelper_fnDeleteItems(
LPITEMIDLIST pidl;
MESSAGE("delete %s\n", szPath);
if (! RemoveDirectoryA(szPath)) return E_FAIL;
if (! SHELL_DeleteDirectoryA(szPath, TRUE)) return E_FAIL;
pidl = ILCombine(This->absPidl, apidl[i]);
SHChangeNotifyA(SHCNE_RMDIR, SHCNF_IDLIST, pidl, NULL);
SHFree(pidl);
......@@ -1625,6 +1694,11 @@ static HRESULT WINAPI ISF_Desktop_fnParseDisplayName(
else
{
hr = S_OK;
if (pdwAttributes && *pdwAttributes)
{
SHELL32_GetItemAttributes(_IShellFolder_(This), pidlTemp, pdwAttributes);
}
}
*ppidl = pidlTemp;
......@@ -1769,12 +1843,14 @@ static HRESULT WINAPI ISF_Desktop_fnCreateViewObject( IShellFolder2 * iface,
/**************************************************************************
* ISF_Desktop_fnGetAttributesOf
*/
static HRESULT WINAPI ISF_Desktop_fnGetAttributesOf(IShellFolder2 * iface,UINT cidl,LPCITEMIDLIST *apidl,DWORD *rgfInOut)
static HRESULT WINAPI ISF_Desktop_fnGetAttributesOf(
IShellFolder2 * iface,
UINT cidl,
LPCITEMIDLIST *apidl,
DWORD *rgfInOut)
{
_ICOM_THIS_From_IShellFolder2(IGenericSFImpl, iface)
GUID const * clsid;
DWORD attributes;
HRESULT hr = S_OK;
TRACE("(%p)->(cidl=%d apidl=%p mask=0x%08lx)\n",This,cidl,apidl, *rgfInOut);
......@@ -1785,37 +1861,8 @@ static HRESULT WINAPI ISF_Desktop_fnGetAttributesOf(IShellFolder2 * iface,UINT c
while (cidl > 0 && *apidl)
{
pdump (*apidl);
if ((clsid=_ILGetGUIDPointer(*apidl)))
{
if (IsEqualIID(clsid, &CLSID_MyComputer))
{
*rgfInOut &= 0xb0000154;
goto next;
}
else if (HCR_GetFolderAttributes(clsid, &attributes))
{
*rgfInOut &= attributes;
goto next;
}
else
{ /* some shell-extension */
*rgfInOut &= 0xb0000154;
}
}
else if (_ILIsFolder( *apidl))
{
*rgfInOut &= 0xe0000177;
goto next;
}
else if (_ILIsValue( *apidl))
{
*rgfInOut &= 0x40000177;
goto next;
}
hr = E_INVALIDARG;
next: apidl++;
SHELL32_GetItemAttributes(_IShellFolder_(This), *apidl, rgfInOut);
apidl++;
cidl--;
}
......@@ -2086,6 +2133,10 @@ static HRESULT WINAPI ISF_MyComputer_fnParseDisplayName(
}
else
{
if (pdwAttributes && *pdwAttributes)
{
SHELL32_GetItemAttributes(_IShellFolder_(This), pidlTemp, pdwAttributes);
}
hr = S_OK;
}
*ppidl = pidlTemp;
......@@ -2213,12 +2264,14 @@ static HRESULT WINAPI ISF_MyComputer_fnCreateViewObject( IShellFolder2 * iface,
/**************************************************************************
* ISF_MyComputer_fnGetAttributesOf
*/
static HRESULT WINAPI ISF_MyComputer_fnGetAttributesOf(IShellFolder2 * iface,UINT cidl,LPCITEMIDLIST *apidl,DWORD *rgfInOut)
static HRESULT WINAPI ISF_MyComputer_fnGetAttributesOf(
IShellFolder2 * iface,
UINT cidl,
LPCITEMIDLIST *apidl,
DWORD *rgfInOut)
{
_ICOM_THIS_From_IShellFolder2(IGenericSFImpl, iface)
GUID const * clsid;
DWORD attributes;
HRESULT hr = S_OK;
TRACE("(%p)->(cidl=%d apidl=%p mask=0x%08lx)\n",This,cidl,apidl,*rgfInOut);
......@@ -2226,28 +2279,11 @@ static HRESULT WINAPI ISF_MyComputer_fnGetAttributesOf(IShellFolder2 * iface,UIN
if ( (!cidl) || (!apidl) || (!rgfInOut))
return E_INVALIDARG;
*rgfInOut = 0xffffffff;
while (cidl > 0 && *apidl)
{
pdump (*apidl);
if (_ILIsDrive(*apidl))
{
*rgfInOut &= 0xf0000144;
goto next;
}
else if ((clsid=_ILGetGUIDPointer(*apidl)))
{
if (HCR_GetFolderAttributes(clsid, &attributes))
{
*rgfInOut &= attributes;
goto next;
}
}
hr = E_INVALIDARG;
next: apidl++;
SHELL32_GetItemAttributes(_IShellFolder_(This), *apidl, rgfInOut);
apidl++;
cidl--;
}
......
......@@ -444,7 +444,7 @@ HMENU WINAPI FileMenu_FindSubMenuByPidl(
/*************************************************************************
* FileMenu_AppendFilesForPidl [SHELL32.124]
*/
HMENU WINAPI FileMenu_AppendFilesForPidl(
int WINAPI FileMenu_AppendFilesForPidl(
HMENU hmenu,
LPCITEMIDLIST pidl,
BOOL bAddSeperator)
......@@ -490,7 +490,7 @@ int WINAPI FileMenu_AddFilesForPidl (
/*************************************************************************
* FileMenu_TrackPopupMenuEx [SHELL32.116]
*/
HRESULT WINAPI FileMenu_TrackPopupMenuEx (
BOOL WINAPI FileMenu_TrackPopupMenuEx (
HMENU hMenu,
UINT uFlags,
int x,
......
......@@ -176,11 +176,11 @@ type win32
@ stub PathAddExtensionA
@ stub PathAddExtensionW
@ stdcall PathAppendA (str str) PathAppendA
@ stub PathAppendW
@ stdcall PathAppendW (str str) PathAppendW
@ stdcall PathBuildRootA (ptr long) PathBuildRootA
@ stub PathBuildRootW
@ stub PathCanonicalizeA
@ stub PathCanonicalizeW
@ stdcall PathBuildRootW (ptr long) PathBuildRootW
@ stdcall PathCanonicalizeA (ptr str) PathCanonicalizeA
@ stdcall PathCanonicalizeW (ptr wstr) PathCanonicalizeW
@ stdcall PathCombineA (ptr ptr ptr) PathCombineA
@ stdcall PathCombineW (ptr ptr ptr) PathCombineW
@ stub PathCommonPrefixA
......@@ -192,21 +192,21 @@ type win32
@ stub PathCreateFromUrlA
@ stub PathCreateFromUrlW
@ stdcall PathFileExistsA (str) PathFileExistsA
@ stub PathFileExistsW
@ stdcall PathFindExtensionA (ptr) PathFindExtensionA
@ stdcall PathFindExtensionW (ptr) PathFindExtensionW
@ stdcall PathFindFileNameA (ptr) PathFindFilenameA
@ stdcall PathFindFileNameW (ptr) PathFindFilenameW
@ stub PathFindNextComponentA
@ stub PathFindNextComponentW
@ stdcall PathFindOnPathA (ptr ptr) PathFindOnPathA
@ stdcall PathFindOnPathW (ptr ptr) PathFindOnPathW
@ stdcall PathFileExistsW (wstr) PathFileExistsW
@ stdcall PathFindExtensionA (str) PathFindExtensionA
@ stdcall PathFindExtensionW (wstr) PathFindExtensionW
@ stdcall PathFindFileNameA (str) PathFindFileNameA
@ stdcall PathFindFileNameW (wstr) PathFindFileNameW
@ stdcall PathFindNextComponentA (str) PathFindNextComponentA
@ stdcall PathFindNextComponentW (wstr) PathFindNextComponentW
@ stdcall PathFindOnPathA (str ptr) PathFindOnPathA
@ stdcall PathFindOnPathW (wstr ptr) PathFindOnPathW
@ stdcall PathGetArgsA (str) PathGetArgsA
@ stdcall PathGetArgsW (str) PathGetArgsW
@ stdcall PathGetArgsW (wstr) PathGetArgsW
@ stub PathGetCharTypeA
@ stub PathGetCharTypeW
@ stdcall PathGetDriveNumberA(str) PathGetDriveNumberA
@ stdcall PathGetDriveNumberW(str) PathGetDriveNumberW
@ stdcall PathGetDriveNumberA (str) PathGetDriveNumberA
@ stdcall PathGetDriveNumberW (wstr) PathGetDriveNumberW
@ stub PathIsContentTypeA
@ stub PathIsContentTypeW
@ stdcall PathIsDirectoryA(str) PathIsDirectoryA
......@@ -215,44 +215,44 @@ type win32
@ stub PathIsFileSpecW
@ stub PathIsPrefixA
@ stub PathIsPrefixW
@ stdcall PathIsRelativeA (ptr) PathIsRelativeA
@ stdcall PathIsRelativeW (ptr) PathIsRelativeW
@ stdcall PathIsRelativeA (str) PathIsRelativeA
@ stdcall PathIsRelativeW (wstr) PathIsRelativeW
@ stdcall PathIsRootA(str) PathIsRootA
@ stdcall PathIsRootW(wstr) PathIsRootW
@ stub PathIsSameRootA
@ stub PathIsSameRootW
@ stdcall PathIsSameRootA(str str) PathIsSameRootA
@ stdcall PathIsSameRootW(wstr wstr) PathIsSameRootW
@ stub PathIsSystemFolderA
@ stub PathIsSystemFolderW
@ stdcall PathIsUNCA (ptr) PathIsUNCA
@ stdcall PathIsUNCA (str) PathIsUNCA
@ stub PathIsUNCServerA
@ stub PathIsUNCServerShareA
@ stub PathIsUNCServerShareW
@ stub PathIsUNCServerW
@ stdcall PathIsUNCW(wstr) PathIsUNCW
@ stdcall PathIsURLA(str) PathIsURLA
@ stub PathIsURLW
@ stdcall PathIsURLW(wstr) PathIsURLW
@ stub PathMakePrettyA
@ stub PathMakePrettyW
@ stub PathMakeSystemFolderA
@ stub PathMakeSystemFolderW
@ stdcall PathMatchSpecA (str str) PathMatchSpecA
@ stdcall PathMatchSpecW (str str) PathMatchSpecW
@ stub PathParseIconLocationA
@ stub PathParseIconLocationW
@ stdcall PathParseIconLocationA (str) PathParseIconLocationA
@ stdcall PathParseIconLocationW (wstr) PathParseIconLocationW
@ stdcall PathQuoteSpacesA (ptr) PathQuoteSpacesA
@ stdcall PathQuoteSpacesW (ptr) PathQuoteSpacesW
@ stub PathRelativePathToA
@ stub PathRelativePathToW
@ stub PathRemoveArgsA
@ stub PathRemoveArgsW
@ stdcall PathRemoveBackslashA (ptr) PathRemoveBackslashA
@ stdcall PathRemoveBackslashW (ptr) PathRemoveBackslashW
@ stdcall PathRemoveArgsA(str)PathRemoveArgsA
@ stdcall PathRemoveArgsW(wstr)PathRemoveArgsW
@ stdcall PathRemoveBackslashA (str) PathRemoveBackslashA
@ stdcall PathRemoveBackslashW (wstr) PathRemoveBackslashW
@ stdcall PathRemoveBlanksA(str) PathRemoveBlanksA
@ stdcall PathRemoveBlanksW(wstr) PathRemoveBlanksW
@ stub PathRemoveExtensionA
@ stub PathRemoveExtensionW
@ stdcall PathRemoveExtensionA(str)PathRemoveExtensionA
@ stdcall PathRemoveExtensionW(wstr)PathRemoveExtensionW
@ stdcall PathRemoveFileSpecA (str) PathRemoveFileSpecA
@ stub PathRemoveFileSpecW
@ stdcall PathRemoveFileSpecW (wstr) PathRemoveFileSpecW
@ stub PathRenameExtensionA
@ stub PathRenameExtensionW
@ stub PathSearchAndQualifyA
......@@ -261,19 +261,19 @@ type win32
@ stdcall PathSetDlgItemPathW (long long ptr) PathSetDlgItemPathW
@ stub PathSkipRootA
@ stub PathSkipRootW
@ stub PathStripPathA
@ stub PathStripPathW
@ stub PathStripToRootA
@ stub PathStripToRootW
@ stdcall PathStripPathA(str)PathStripPathA
@ stdcall PathStripPathW(wstr)PathStripPathW
@ stdcall PathStripToRootA(str)PathStripToRootA
@ stdcall PathStripToRootW(wstr)PathStripToRootW
@ stub PathUnmakeSystemFolderA
@ stub PathUnmakeSystemFolderW
@ stdcall PathUnquoteSpacesA (str) PathUnquoteSpacesA
@ stdcall PathUnquoteSpacesW (str) PathUnquoteSpacesW
@ stdcall PathUnquoteSpacesW (wstr) PathUnquoteSpacesW
@ stub SHCreateShellPalette
@ stub SHDeleteEmptyKeyA
@ stub SHDeleteEmptyKeyW
@ stdcall SHDeleteKeyA(long str)SHRegDeleteKeyA
@ stdcall SHDeleteKeyW(long str)SHRegDeleteKeyW
@ stdcall SHDeleteKeyW(long wstr)SHRegDeleteKeyW
@ stub SHDeleteOrphanKeyA
@ stub SHDeleteOrphanKeyW
@ stub SHDeleteValueA
......
......@@ -129,6 +129,8 @@ STRINGTABLE DISCARDABLE
{
IDS_CREATEFOLDER_DENIED "Can not create new Folder: Permission denied."
IDS_CREATEFOLDER_CAPTION "Error during creating a new folder"
IDS_DELETEFOLDER_TEXT "Are you sure you want to delete %1 and all it's subfolders?"
IDS_DELETEFOLDER_CAPTION "Confirm file delete"
}
shv_accel ACCELERATORS
......
......@@ -24,5 +24,6 @@
#define IDS_CREATEFOLDER_DENIED 30
#define IDS_CREATEFOLDER_CAPTION 31
#define IDS_DELETEFOLDER_TEXT 32
#define IDS_DELETEFOLDER_CAPTION 33
#endif
......@@ -16,6 +16,7 @@
#include "shell32_main.h"
#include "shellfolder.h"
#include "shell.h" /* DROPFILESTRUCT */
#include "wine/undocshell.h"
DEFAULT_DEBUG_CHANNEL(shell)
......
......@@ -65,6 +65,7 @@ typedef struct
{ WORD cb; /* nr of bytes in this item */
BYTE abID[1];/* first byte in this item */
} SHITEMID,*LPSHITEMID;
typedef LPSHITEMID const LPCSHITEMID;
typedef struct
{ SHITEMID mkid; /* first itemid in list */
......@@ -87,94 +88,11 @@ DWORD WINAPI SHAddToRecentDocs(UINT uFlags, LPCVOID pv);
* SHGetSpecialFolderLocation API
*/
HRESULT WINAPI SHGetSpecialFolderLocation(HWND, INT, LPITEMIDLIST *);
/****************************************************************************
* string and path functions
*/
BOOL WINAPI PathIsRootA(LPCSTR x);
BOOL WINAPI PathIsRootW(LPCWSTR x);
#define PathIsRoot WINELIB_NAME_AW(PathIsRoot)
BOOL WINAPI PathIsRootAW(LPCVOID x);
LPSTR WINAPI PathAddBackslashA(LPSTR path);
LPWSTR WINAPI PathAddBackslashW(LPWSTR path);
#define PathAddBackslash WINELIB_NAME_AW(PathAddBackslash)
LPVOID WINAPI PathAddBackslashAW(LPVOID path);
BOOL WINAPI PathQualifyA(LPCSTR path);
BOOL WINAPI PathQualifyW(LPCWSTR path);
#define PathQualify WINELIB_NAME_AW(PathQualify)
BOOL WINAPI PathQualifyAW(LPCVOID path);
LPSTR WINAPI PathQuoteSpacesA(LPCSTR path);
LPWSTR WINAPI PathQuoteSpacesW(LPCWSTR path);
#define PathQuoteSpaces WINELIB_NAME_AW(PathQuoteSpaces)
LPVOID WINAPI PathQuoteSpacesAW(LPCVOID path);
LPSTR WINAPI PathCombineA(LPSTR szDest, LPCSTR lpszDir, LPCSTR lpszFile);
LPWSTR WINAPI PathCombineW(LPWSTR szDest, LPCWSTR lpszDir, LPCWSTR lpszFile);
#define PathCombine WINELIB_NAME_AW(PathCombine)
LPVOID WINAPI PathCombineAW(LPVOID szDest, LPCVOID lpszDir, LPCVOID lpszFile);
LPCSTR WINAPI PathFindExtensionA(LPCSTR path);
LPCWSTR WINAPI PathFindExtensionW(LPCWSTR path);
#define PathFindExtension WINELIB_NAME_AW(PathFindExtension)
LPCVOID WINAPI PathFindExtensionAW(LPCVOID path);
LPCSTR WINAPI PathGetExtensionA(LPCSTR path, DWORD y, DWORD x);
LPCWSTR WINAPI PathGetExtensionW(LPCWSTR path, DWORD y, DWORD x);
#define PathGetExtension WINELIB_NAME_AW(PathGetExtension)
LPCVOID WINAPI PathGetExtensionAW(LPCVOID path, DWORD y, DWORD x);
LPCSTR WINAPI PathFindFilenameA(LPCSTR path);
LPCWSTR WINAPI PathFindFilenameW(LPCWSTR path);
#define PathFindFilename WINELIB_NAME_AW(PathFindFilename)
LPCVOID WINAPI PathFindFilenameAW(LPCVOID path);
BOOL WINAPI PathMatchSpecA(LPCSTR x, LPCSTR y);
BOOL WINAPI PathMatchSpecW(LPCWSTR x, LPCWSTR y);
#define PathMatchSpec WINELIB_NAME_AW(PathMatchSpec)
BOOL WINAPI PathMatchSpecAW(LPVOID x, LPVOID y);
LPSTR WINAPI PathRemoveBlanksA(LPSTR str);
LPWSTR WINAPI PathRemoveBlanksW(LPWSTR str);
#define PathRemoveBlanks WINELIB_NAME_AW(PathRemoveBlanks)
LPVOID WINAPI PathRemoveBlanksAW(LPVOID str);
BOOL WINAPI PathIsRelativeA(LPCSTR str);
BOOL WINAPI PathIsRelativeW(LPCWSTR str);
#define PathIsRelative WINELIB_NAME_AW(PathIsRelative)
BOOL WINAPI PathIsRelativeAW(LPCVOID str);
BOOL WINAPI PathIsUNCA(LPCSTR str);
BOOL WINAPI PathIsUNCW(LPCWSTR str);
#define PathIsUNC WINELIB_NAME_AW(PathIsUNC)
BOOL WINAPI PathIsUNCAW(LPCVOID str);
BOOL WINAPI PathIsURLA(LPCSTR str);
BOOL WINAPI PathIsURLW(LPCWSTR str);
#define PathIsURL WINELIB_NAME_AW(PathIsURL)
BOOL WINAPI PathIsURLAW(LPCVOID str);
BOOL WINAPI PathFindOnPathA(LPSTR sFile, LPCSTR sOtherDirs);
BOOL WINAPI PathFindOnPathW(LPWSTR sFile, LPCWSTR sOtherDirs);
#define PathFindOnPath WINELIB_NAME_AW(PathFindOnPath)
BOOL WINAPI PathFindOnPathAW(LPVOID sFile, LPCVOID sOtherDirs);
LPSTR WINAPI StrFormatByteSizeA ( DWORD dw, LPSTR pszBuf, UINT cchBuf );
LPWSTR WINAPI StrFormatByteSizeW ( DWORD dw, LPWSTR pszBuf, UINT cchBuf );
#define StrFormatByteSize WINELIB_NAME_AW(StrFormatByteSize)
DWORD WINAPI PathCleanupSpecA(LPSTR x, LPSTR y);
DWORD WINAPI PathCleanupSpecW(LPWSTR x, LPWSTR y);
#define PathCleanupSpec WINELIB_NAME_AW(PathCleanupSpec)
/****************************************************************************
* other functions
*/
LPVOID WINAPI SHAlloc(DWORD len);
DWORD WINAPI SHFree(LPVOID x);
#define CSIDL_DESKTOP 0x0000
#define CSIDL_PROGRAMS 0x0002
#define CSIDL_CONTROLS 0x0003
......
......@@ -72,13 +72,9 @@ extern UINT cfFileContents;
* IShellView interface
*/
typedef GUID SHELLVIEWID;
#define SV_CLASS_NAME ("SHELLDLL_DefView")
UINT WINAPI SHMapPIDLToSystemImageListIndex(LPSHELLFOLDER sh, LPITEMIDLIST pidl, UINT * pIndex);
/****************************************************************************
* IShellIcon interface
*/
......@@ -341,29 +337,6 @@ typedef struct _SHELLVIEWDATA /* idl */
DWORD WINAPI SHGetMalloc(LPMALLOC *lpmal) ;
/****************************************************************************
* Shell File Menu API
*/
/* FileMenu_Create nSelHeight */
#define FM_FULL_SELHEIGHT -1;
#define FM_DEFAULT_SELHEIGHT 0
/* FileMenu_Create uFlags */
#define FMF_SMALL_ICONS 0x00
#define FMF_LARGE_ICONS 0x08
#define FMF_NO_COLUMN_BREAK 0x10
/* FileMenu_InsertUsingPidl uFlags */
#define FMF_NO_EMPTY_ITEM 0x01
#define FMF_NO_PROGRAM_GROUPS 0x04
typedef void (CALLBACK * LPFNFMCALLBACK)(LPCITEMIDLIST pidlFolder, LPCITEMIDLIST pidlFile);
/* FileMenu_AppendItem lpszText */
#define FM_SEPARATOR (LPCSTR)1
#define FM_BLANK_ICON -1
#define FM_DEFAULT_HEIGHT 0
/**********************************************************************
* SHGetSettings ()
*/
......
#ifndef __WINE_SHLWAPI_H
#define __WINE_SHLWAPI_H
#include "windef.h"
#include "wine/obj_queryassociations.h"
#ifdef __cplusplus
extern "C" {
#endif /* defined(__cplusplus) */
LPSTR WINAPI PathFindFileNameA(LPCSTR pPath);
LPWSTR WINAPI PathFindFileNameW(LPCWSTR pPath);
#define PathFindFileName WINELIB_NAME_AW(PathFindFileName)
LPVOID WINAPI PathFindFileNameAW(LPCVOID path);
int WINAPI PathGetDriveNumberA(LPCSTR lpszPath);
int WINAPI PathGetDriveNumberW(LPCWSTR lpszPath);
#define PathGetDriveNumber WINELIB_NAME_AW(PathGetDriveNumber)
BOOL WINAPI PathCanonicalizeA(LPSTR lpszDst, LPCSTR lpszSrc);
BOOL WINAPI PathCanonicalizeW(LPWSTR lpszDst, LPCWSTR lpszSrc);
#define PathCanonicalize WINELIB_NAME_AW(PathCanonicalize)
LPSTR WINAPI PathFindNextComponentA(LPCSTR pszPath);
LPWSTR WINAPI PathFindNextComponentW(LPCWSTR pszPath);
#define PathFindNextComponent WINELIB_NAME_AW(PathFindNextComponent)
BOOL WINAPI PathIsURLA(LPCSTR pszPath);
BOOL WINAPI PathIsURLW(LPCWSTR pszPath);
#define PathIsURL WINELIB_NAME_AW(PathIsURL)
#ifdef __cplusplus
} /* extern "C" */
#endif /* defined(__cplusplus) */
#endif /* __WINE_SHLWAPI_H */
......@@ -58,14 +58,6 @@ DEFINE_SHLGUID(IID_IShellBrowser, 0x000214E2L, 0, 0);
#define FCT_CONFIGABLE 0x0002
#define FCT_ADDTOEND 0x0004
/* undocumented, found in the web posted by Chris Becke */
#define CWM_SETPATH (WM_USER+2)
#define CWM_WANTIDLE (WM_USER+3)
#define CWM_GETSETCURRENTINFO (WM_USER+4)
#define CWM_SELECTITEM (WM_USER+5)
#define CWM_STOPWAITING (WM_USER+6)
#define CWM_GETISHELLBROWSER (WM_USER+7)
#define ICOM_INTERFACE IShellBrowser
#define IShellBrowser_METHODS \
ICOM_METHOD2(HRESULT, InsertMenusSB, HMENU, hmenuShared, LPOLEMENUGROUPWIDTHS, lpMenuWidths) \
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment