From b45c5496ad75b9448c806bef6c5bc20fc294f3d3 Mon Sep 17 00:00:00 2001 From: Dmitry Chapyshev Date: Tue, 3 Feb 2009 20:56:26 +0000 Subject: [PATCH] - Add missed structure and function to shellapi.h - Add more stubs to shell32 svn path=/trunk/; revision=39350 --- reactos/dll/win32/shell32/shell32.spec | 62 ++-- reactos/dll/win32/shell32/stubs.c | 402 ++++++++++++++++++++++++- reactos/include/psdk/shellapi.h | 18 ++ 3 files changed, 447 insertions(+), 35 deletions(-) diff --git a/reactos/dll/win32/shell32/shell32.spec b/reactos/dll/win32/shell32/shell32.spec index 1f17705faba..b7d165fd552 100644 --- a/reactos/dll/win32/shell32/shell32.spec +++ b/reactos/dll/win32/shell32/shell32.spec @@ -254,18 +254,18 @@ 254 stub -noname DisconnectWindowsDialog 255 stdcall Options_RunDLLA(ptr ptr str long) 256 stdcall SHCreateShellFolderView(ptr ptr) -257 stub -noname SHGetShellFolderViewCB # Fixme +257 stdcall -noname SHGetShellFolderViewCB(ptr) 258 stdcall -noname LinkWindow_RegisterClass() 259 stdcall -noname LinkWindow_UnregisterClass() 260 stdcall Options_RunDLLW(ptr ptr wstr long) -261 stub PrintersGetCommand_RunDLL -262 stub PrintersGetCommand_RunDLLA -263 stub PrintersGetCommand_RunDLLW -264 stub RealShellExecuteA -265 stub RealShellExecuteExA -266 stub RealShellExecuteExW -267 stub RealShellExecuteW -268 stub RegenerateUserEnvironment +261 stdcall PrintersGetCommand_RunDLL(ptr ptr wstr long) +262 stdcall PrintersGetCommand_RunDLLA(ptr ptr str long) +263 stdcall PrintersGetCommand_RunDLLW(ptr ptr wstr long) +264 stdcall RealShellExecuteA(ptr str str str str str str str long ptr) +265 stdcall RealShellExecuteExA(ptr str str str str str str str long ptr long) +266 stdcall RealShellExecuteExW(ptr str str str str str str str long ptr long) +267 stdcall RealShellExecuteW(ptr wstr wstr wstr wstr wstr wstr wstr long ptr) +268 stdcall RegenerateUserEnvironment(ptr long) 269 stdcall SHAddToRecentDocs(long ptr) 270 stdcall SHAppBarMessage(long ptr) 271 stdcall SHBindToParent(ptr ptr ptr ptr) @@ -273,18 +273,18 @@ 273 stdcall SHBrowseForFolderA(ptr) 274 stdcall SHBrowseForFolderW(ptr) 275 stdcall SHChangeNotify(long long ptr ptr) -276 stub SHChangeNotifySuspendResume +276 stdcall SHChangeNotifySuspendResume(long ptr long long) 277 stdcall SHCreateDirectoryExA(long str ptr) 278 stdcall SHCreateDirectoryExW(long wstr ptr) 279 stub SHCreateLocalServerRunDll -280 stub SHCreateProcessAsUserW -281 stub SHCreateQueryCancelAutoPlayMoniker +280 stdcall SHCreateProcessAsUserW(ptr) +281 stdcall SHCreateQueryCancelAutoPlayMoniker(ptr) 282 stdcall SHCreateShellItem(ptr ptr ptr ptr) 283 stdcall SHEmptyRecycleBinA(long str long) 284 stdcall SHEmptyRecycleBinW(long wstr long) 285 stub SHEnableServiceObject 286 stub SHEnumerateUnreadMailAccountsW -287 stub SHExtractIconsW +287 stdcall SHExtractIconsW(wstr long long long ptr ptr long long) user32.PrivateExtractIconsW 288 stdcall SHFileOperation(ptr) SHFileOperationA 289 stdcall SHFileOperationA(ptr) 290 stdcall SHFileOperationW(ptr) @@ -320,8 +320,8 @@ 320 stdcall SHHelpShortcuts_RunDLL(long long long long) SHHelpShortcuts_RunDLLA 321 stdcall SHHelpShortcuts_RunDLLA(long long long long) 322 stdcall SHHelpShortcuts_RunDLLW(long long long long) -323 stub SHInvokePrinterCommandA -324 stub SHInvokePrinterCommandW +323 stdcall SHInvokePrinterCommandA(ptr long str str long) +324 stdcall SHInvokePrinterCommandW(ptr long wstr wstr long) 325 stdcall SHIsFileAvailableOffline(wstr ptr) 326 stdcall SHLoadInProc(long) 327 stdcall SHLoadNonloadedIconOverlayIdentifiers() @@ -335,27 +335,27 @@ 335 stub SHSetUnreadMailCountW 336 stdcall SHUpdateRecycleBinIcon() 337 stdcall SheChangeDirA(str) -338 stub SheChangeDirExA -339 stub SheChangeDirExW +338 stdcall SheChangeDirExA(str) +339 stdcall SheChangeDirExW(wstr) 340 stdcall SheChangeDirW(wstr) -341 stub SheConvertPathW -342 stub SheFullPathA -343 stub SheFullPathW -344 stub SheGetCurDrive +341 stdcall SheConvertPathW(wstr wstr long) +342 stdcall SheFullPathA(str long str) +343 stdcall SheFullPathW(wstr long wstr) +344 stdcall SheGetCurDrive() 345 stdcall SheGetDirA(long long) -346 stub SheGetDirExW +346 stdcall SheGetDirExW(wstr ptr wstr) 347 stdcall SheGetDirW(long long) -348 stub SheGetPathOffsetW -349 stub SheRemoveQuotesA -350 stub SheRemoveQuotesW -351 stub SheSetCurDrive -352 stub SheShortenPathA -353 stub SheShortenPathW +348 stdcall SheGetPathOffsetW(wstr) +349 stdcall SheRemoveQuotesA(str) +350 stdcall SheRemoveQuotesW(wstr) +351 stdcall SheSetCurDrive(long) +352 stdcall SheShortenPathA(str long) +353 stdcall SheShortenPathW(wstr long) 354 stdcall ShellAboutA(long str str long) 355 stdcall ShellAboutW(long wstr wstr long) -356 stub ShellExec_RunDLL -357 stub ShellExec_RunDLLA -358 stub ShellExec_RunDLLW +356 stdcall ShellExec_RunDLL(ptr ptr wstr long) +357 stdcall ShellExec_RunDLLA(ptr ptr str long) +358 stdcall ShellExec_RunDLLW(ptr ptr wstr long) 359 stdcall ShellExecuteA(long str str str str long) 360 stdcall ShellExecuteEx(long) ShellExecuteExA 361 stdcall ShellExecuteExA (long) diff --git a/reactos/dll/win32/shell32/stubs.c b/reactos/dll/win32/shell32/stubs.c index 4a708642381..154b13dc9bf 100644 --- a/reactos/dll/win32/shell32/stubs.c +++ b/reactos/dll/win32/shell32/stubs.c @@ -344,8 +344,8 @@ VOID WINAPI CDefFolderMenu_MergeMenu(HINSTANCE hInstance, UINT uMainMerge, - UINT uPopupMerge, - LPQCMINFO lpQcmInfo) + UINT uPopupMerge, + LPQCMINFO lpQcmInfo) { FIXME("CDefFolderMenu_MergeMenu() stub\n"); } @@ -358,11 +358,11 @@ WINAPI CDefFolderMenu_Create(PCIDLIST_ABSOLUTE pidlFolder, HWND hwnd, UINT uidl, - PCUITEMID_CHILD_ARRAY *apidl, + PCUITEMID_CHILD_ARRAY *apidl, IShellFolder *psf, LPFNDFMCALLBACK lpfn, HKEY hProgID, - HKEY hBaseProgID, + HKEY hBaseProgID, IContextMenu **ppcm) { FIXME("CDefFolderMenu_Create() stub\n"); @@ -458,5 +458,399 @@ WINAPI ShellHookProc(INT iCode, WPARAM wParam, LPARAM lParam) { /* Unimplemented in WinXP SP3 */ + TRACE("ShellHookProc() stub\n"); return 0; } + +/* + * Unimplemented + */ +VOID +WINAPI +ShellExec_RunDLL(HWND hwnd, HINSTANCE hInstance, LPWSTR pszCmdLine, int nCmdShow) +{ + FIXME("ShellExec_RunDLL() stub\n"); +} + +/* + * Unimplemented + */ +VOID +WINAPI +ShellExec_RunDLLA(HWND hwnd, HINSTANCE hInstance, LPSTR pszCmdLine, int nCmdShow) +{ + FIXME("ShellExec_RunDLLA() stub\n"); +} + +/* + * Unimplemented + */ +VOID +WINAPI +ShellExec_RunDLLW(HWND hwnd, HINSTANCE hInstance, LPWSTR pszCmdLine, int nCmdShow) +{ + FIXME("ShellExec_RunDLLW() stub\n"); +} + +/* + * Unimplemented + */ +BOOL +WINAPI +SheShortenPathW(LPWSTR lpPath, BOOL bShorten) +{ + FIXME("SheShortenPathW() stub\n"); + return FALSE; +} + +/* + * Unimplemented + */ +BOOL +WINAPI +SheShortenPathA(LPSTR lpPath, BOOL bShorten) +{ + FIXME("SheShortenPathA() stub\n"); + return FALSE; +} + +/* + * Unimplemented + */ +INT +WINAPI +SheSetCurDrive(INT iIndex) +{ + FIXME("SheSetCurDrive() stub\n"); + return 1; +} + +/* + * Unimplemented + */ +LPWSTR +WINAPI +SheRemoveQuotesW(LPWSTR lpInput) +{ + FIXME("SheRemoveQuotesW() stub\n"); + return NULL; +} + +/* + * Unimplemented + */ +LPSTR +WINAPI +SheRemoveQuotesA(LPSTR lpInput) +{ + FIXME("SheRemoveQuotesA() stub\n"); + return NULL; +} + +/* + * Unimplemented + */ +INT +WINAPI +SheGetPathOffsetW(LPWSTR lpPath) +{ + FIXME("SheGetPathOffsetW() stub\n"); + return 0; +} + +/* + * Unimplemented + */ +BOOL +WINAPI +SheGetDirExW(LPWSTR lpDrive, + LPDWORD lpCurDirLen, + LPWSTR lpCurDir) +{ + FIXME("SheGetDirExW() stub\n"); + return FALSE; +} + +/* + * Unimplemented + */ +INT +WINAPI +SheGetCurDrive(VOID) +{ + FIXME("SheGetCurDrive() stub\n"); + return 1; +} + +/* + * Unimplemented + */ +INT +WINAPI +SheFullPathW(LPWSTR lpFullName, DWORD dwPathSize, LPWSTR lpBuffer) +{ + FIXME("SheFullPathW() stub\n"); + return 0; +} + +/* + * Unimplemented + */ +INT +WINAPI +SheFullPathA(LPSTR lpFullName, DWORD dwPathSize, LPSTR lpBuffer) +{ + FIXME("SheFullPathA() stub\n"); + return 0; +} + +/* + * Unimplemented + */ +BOOL +WINAPI +SheConvertPathW(LPWSTR lpCmd, LPWSTR lpFileName, UINT uCmdLen) +{ + FIXME("SheConvertPathW() stub\n"); + return FALSE; +} + +/* + * Unimplemented + */ +INT +WINAPI +SheChangeDirExW(LPWSTR lpDir) +{ + FIXME("SheChangeDirExW() stub\n"); + return 0; +} + +/* + * Unimplemented + */ +INT +WINAPI +SheChangeDirExA(LPSTR lpDir) +{ + FIXME("SheChangeDirExA() stub\n"); + return 0; +} + +/* + * Unimplemented + */ +BOOL +WINAPI +SHInvokePrinterCommandW(HWND hwnd, + UINT uAction, + LPCWSTR lpBuf1, + LPCWSTR lpBuf2, + BOOL fModal) +{ + FIXME("SHInvokePrinterCommandW() stub\n"); + return FALSE; +} + +/* + * Unimplemented + */ +BOOL +WINAPI +SHInvokePrinterCommandA(HWND hwnd, + UINT uAction, + LPCSTR lpBuf1, + LPCSTR lpBuf2, + BOOL fModal) +{ + FIXME("SHInvokePrinterCommandA() stub\n"); + return FALSE; +} + +/* + * Unimplemented + */ +HRESULT +WINAPI +SHCreateQueryCancelAutoPlayMoniker(IMoniker **ppmoniker) +{ + FIXME("SHCreateQueryCancelAutoPlayMoniker() stub\n"); + return E_FAIL; +} + +/* + * Unimplemented + */ +BOOL +WINAPI +SHCreateProcessAsUserW(PSHCREATEPROCESSINFOW pscpi) +{ + FIXME("SHCreateProcessAsUserW() stub\n"); + return FALSE; +} + +/* + * Unimplemented + */ +BOOL +WINAPI +SHChangeNotifySuspendResume(BOOL bSuspend, + LPITEMIDLIST pidl, + BOOL bRecursive, + DWORD dwReserved) +{ + FIXME("SHChangeNotifySuspendResume() stub\n"); + return FALSE; +} + +/* + * Unimplemented + */ +BOOL +WINAPI +RegenerateUserEnvironment(LPVOID *lpUnknown, BOOL bUnknown) +{ + FIXME("RegenerateUserEnvironment() stub\n"); + return FALSE; +} + +/* + * Unimplemented + */ +HINSTANCE +WINAPI +RealShellExecuteExA(HWND hwnd, + LPCSTR lpOperation, + LPCSTR lpFile, + LPCSTR lpParameters, + LPCSTR lpDirectory, + LPSTR lpReturn, + LPCSTR lpTitle, + LPSTR lpReserved, + WORD nShowCmd, + HANDLE *lpProcess, + DWORD dwFlags) +{ + FIXME("RealShellExecuteExA() stub\n"); + return NULL; +} + +/* + * Unimplemented + */ +HINSTANCE +WINAPI +RealShellExecuteExW(HWND hwnd, + LPCWSTR lpOperation, + LPCWSTR lpFile, + LPCWSTR lpParameters, + LPCWSTR lpDirectory, + LPWSTR lpReturn, + LPCWSTR lpTitle, + LPWSTR lpReserved, + WORD nShowCmd, + HANDLE *lpProcess, + DWORD dwFlags) +{ + FIXME("RealShellExecuteExW() stub\n"); + return NULL; +} + +/* + * Implemented + */ +HINSTANCE +WINAPI +RealShellExecuteA(HWND hwnd, + LPCSTR lpOperation, + LPCSTR lpFile, + LPCSTR lpParameters, + LPCSTR lpDirectory, + LPSTR lpReturn, + LPCSTR lpTitle, + LPSTR lpReserved, + WORD nShowCmd, + HANDLE *lpProcess) +{ + return RealShellExecuteExA(hwnd, + lpOperation, + lpFile, + lpParameters, + lpDirectory, + lpReturn, + lpTitle, + lpReserved, + nShowCmd, + lpProcess, + 0); +} + +/* + * Implemented + */ +HINSTANCE +WINAPI +RealShellExecuteW(HWND hwnd, + LPCWSTR lpOperation, + LPCWSTR lpFile, + LPCWSTR lpParameters, + LPCWSTR lpDirectory, + LPWSTR lpReturn, + LPCWSTR lpTitle, + LPWSTR lpReserved, + WORD nShowCmd, + HANDLE *lpProcess) +{ + return RealShellExecuteExW(hwnd, + lpOperation, + lpFile, + lpParameters, + lpDirectory, + lpReturn, + lpTitle, + lpReserved, + nShowCmd, + lpProcess, + 0); +} + +/* + * Unimplemented + */ +VOID +WINAPI +PrintersGetCommand_RunDLL(HWND hwnd, HINSTANCE hInstance, LPWSTR pszCmdLine, int nCmdShow) +{ + FIXME("PrintersGetCommand_RunDLL() stub\n"); +} + +/* + * Unimplemented + */ +VOID +WINAPI +PrintersGetCommand_RunDLLA(HWND hwnd, HINSTANCE hInstance, LPSTR pszCmdLine, int nCmdShow) +{ + FIXME("PrintersGetCommand_RunDLLA() stub\n"); +} + +/* + * Unimplemented + */ +VOID +WINAPI +PrintersGetCommand_RunDLLW(HWND hwnd, HINSTANCE hInstance, LPWSTR pszCmdLine, int nCmdShow) +{ + FIXME("PrintersGetCommand_RunDLLW() stub\n"); +} + +/* + * Unimplemented + */ +IShellFolderViewCB* +WINAPI +SHGetShellFolderViewCB(HWND hwnd) +{ + FIXME("SHGetShellFolderViewCB() stub\n"); + return NULL; +} diff --git a/reactos/include/psdk/shellapi.h b/reactos/include/psdk/shellapi.h index 61524f03491..d6ad0d5476b 100644 --- a/reactos/include/psdk/shellapi.h +++ b/reactos/include/psdk/shellapi.h @@ -124,6 +124,23 @@ extern "C" { #define SHGFI_PIDL 8 #define SHGFI_USEFILEATTRIBUTES 16 +typedef struct _SHCREATEPROCESSINFOW +{ + DWORD cbSize; + ULONG fMask; + HWND hwnd; + LPCWSTR pszFile; + LPCWSTR pszParameters; + LPCWSTR pszCurrentDirectory; + IN HANDLE hUserToken; + IN LPSECURITY_ATTRIBUTES lpProcessAttributes; + IN LPSECURITY_ATTRIBUTES lpThreadAttributes; + IN BOOL bInheritHandles; + IN DWORD dwCreationFlags; + IN LPSTARTUPINFOW lpStartupInfo; + OUT LPPROCESS_INFORMATION lpProcessInformation; +} SHCREATEPROCESSINFOW, *PSHCREATEPROCESSINFOW; + typedef WORD FILEOP_FLAGS; typedef WORD PRINTEROP_FLAGS; #include @@ -336,6 +353,7 @@ HRESULT WINAPI SHQueryRecycleBinA(LPCSTR, LPSHQUERYRBINFO); HRESULT WINAPI SHQueryRecycleBinW(LPCWSTR, LPSHQUERYRBINFO); HRESULT WINAPI SHEmptyRecycleBinA(HWND,LPCSTR,DWORD); HRESULT WINAPI SHEmptyRecycleBinW(HWND,LPCWSTR,DWORD); +BOOL WINAPI SHCreateProcessAsUserW(PSHCREATEPROCESSINFOW); #ifdef UNICODE #define NOTIFYICONDATA_V1_SIZE NOTIFYICONDATAW_V1_SIZE