diff --git a/dlls/shell.dll16/shell.c b/dlls/shell.dll16/shell.c index 9964b60c2d8..b33d3cc1b12 100644 --- a/dlls/shell.dll16/shell.c +++ b/dlls/shell.dll16/shell.c @@ -612,3 +612,28 @@ HINSTANCE16 WINAPI ShellExecute16( HWND16 hWnd, LPCSTR lpOperation, return HINSTANCE_16( WOWShellExecute( HWND_32(hWnd), lpOperation, lpFile, lpParameters, lpDirectory, iShowCmd, SHELL_Execute16 )); } + + +/************************************************************************* + * RunDLL_CallEntry16 + * + * Only exported from shell32 on Windows, probably imported + * from shell through the 16/32 thunks. + */ +void WINAPI RunDLL_CallEntry16( DWORD proc, HWND hwnd, HINSTANCE inst, LPCSTR cmdline, INT cmdshow ) +{ + WORD args[5]; + SEGPTR cmdline_seg; + + TRACE( "proc %x hwnd %p inst %p cmdline %s cmdshow %d\n", + proc, hwnd, inst, debugstr_a(cmdline), cmdshow ); + + cmdline_seg = MapLS( cmdline ); + args[4] = HWND_16(hwnd); + args[3] = MapHModuleLS(inst); + args[2] = SELECTOROF(cmdline_seg); + args[1] = OFFSETOF(cmdline_seg); + args[0] = cmdshow; + WOWCallback16Ex( proc, WCB16_PASCAL, sizeof(args), args, NULL ); + UnMapLS( cmdline_seg ); +} diff --git a/dlls/shell.dll16/shell.dll16.spec b/dlls/shell.dll16/shell.dll16.spec index ac36ec7737e..df03aceacbc 100644 --- a/dlls/shell.dll16/shell.dll16.spec +++ b/dlls/shell.dll16/shell.dll16.spec @@ -43,3 +43,7 @@ # 402 _RUNDLLCHECKDRIVE #32 WCI + +################################################################ +# Wine extensions: functions needed by shell32 +@ stdcall -arch=win32 RunDLL_CallEntry16(long long ptr str long) diff --git a/dlls/shell32/control.c b/dlls/shell32/control.c index cfea201d3e5..730f8a6dc98 100644 --- a/dlls/shell32/control.c +++ b/dlls/shell32/control.c @@ -29,8 +29,6 @@ #include "wingdi.h" #include "winuser.h" #include "winreg.h" -#include "wine/winbase16.h" -#include "wownt32.h" #include "wine/debug.h" #include "cpl.h" #include "wine/unicode.h" @@ -878,32 +876,6 @@ HRESULT WINAPI Control_FillCache_RunDLLA(HWND hWnd, HANDLE hModule, DWORD w, DWO return Control_FillCache_RunDLLW(hWnd, hModule, w, x); } - -/************************************************************************* - * RunDLL_CallEntry16 [SHELL32.122] - * the name is probably wrong - */ -void WINAPI RunDLL_CallEntry16( DWORD proc, HWND hwnd, HINSTANCE inst, - LPCSTR cmdline, INT cmdshow ) -{ -#ifdef __i386__ - WORD args[5]; - SEGPTR cmdline_seg; - - TRACE( "proc %x hwnd %p inst %p cmdline %s cmdshow %d\n", - proc, hwnd, inst, debugstr_a(cmdline), cmdshow ); - - cmdline_seg = MapLS( cmdline ); - args[4] = HWND_16(hwnd); - args[3] = MapHModuleLS(inst); - args[2] = SELECTOROF(cmdline_seg); - args[1] = OFFSETOF(cmdline_seg); - args[0] = cmdshow; - WOWCallback16Ex( proc, WCB16_PASCAL, sizeof(args), args, NULL ); - UnMapLS( cmdline_seg ); -#endif -} - /************************************************************************* * CallCPLEntry16 [SHELL32.166] * diff --git a/dlls/shell32/shell32.spec b/dlls/shell32/shell32.spec index f95690ca185..fc1347ed810 100644 --- a/dlls/shell32/shell32.spec +++ b/dlls/shell32/shell32.spec @@ -114,7 +114,7 @@ 119 stdcall -noname IsLFNDrive(ptr) IsLFNDriveAW 120 stdcall -noname FileMenu_AbortInitMenu() 121 stdcall -noname SHFlushClipboard() - 122 stdcall -noname RunDLL_CallEntry16(long long long str long) #name wrong? + 122 stdcall -private @(long long long str long) shell.dll16.RunDLL_CallEntry16 123 stdcall -noname SHFreeUnusedLibraries() 124 stdcall -noname FileMenu_AppendFilesForPidl(long ptr long) 125 stdcall -noname FileMenu_AddFilesForPidl(long long long ptr long long ptr)