list(APPEND SOURCE
shdocvw_main.c
shlinstobj.c
- shdocvw.h
+ precomp.h
${CMAKE_CURRENT_BINARY_DIR}/shdocvw_stubs.c)
add_typelib(shdocvw_v1.idl)
add_delay_importlibs(shdocvw ole32 oleaut32 ieframe)
add_importlibs(shdocvw shlwapi advapi32 msvcrt kernel32 ntdll)
add_dependencies(shdocvw stdole2)
-add_pch(shdocvw shdocvw.h SOURCE)
+add_pch(shdocvw precomp.h SOURCE)
add_cd_file(TARGET shdocvw DESTINATION reactos/system32 FOR all)
--- /dev/null
+
+#ifndef _SHDOCVW_PRECOMP_H
+#define _SHDOCVW_PRECOMP_H
+
+#include <wine/config.h>
+
+#define WIN32_NO_STATUS
+#define _INC_WINDOWS
+#define COM_NO_WINDOWS_H
+
+#include "shdocvw.h"
+
+#include <winreg.h>
+
+#include <wine/debug.h>
+
+#endif /* !_SHDOCVW_PRECOMP_H */
#ifndef __WINE_SHDOCVW_H
#define __WINE_SHDOCVW_H
-#include <wine/config.h>
+#define COBJMACROS
#include <stdarg.h>
-#define WIN32_NO_STATUS
-#define _INC_WINDOWS
-#define COM_NO_WINDOWS_H
-
-#define COBJMACROS
+#include "windef.h"
+#include "winbase.h"
+#include "winuser.h"
-#include <windef.h>
-#include <winbase.h>
-#include <winnls.h>
-#include <winreg.h>
-#include <shlobj.h>
+#include "ole2.h"
+#include "shlobj.h"
+#include "exdisp.h"
-#include <wine/debug.h>
-WINE_DEFAULT_DEBUG_CHANNEL(shdocvw);
+#include "wine/unicode.h"
+#include "wine/heap.h"
+#include "wine/list.h"
/**********************************************************************
* Shell Instance Objects
static inline void SHDOCVW_LockModule(void) { InterlockedIncrement( &SHDOCVW_refCount ); }
static inline void SHDOCVW_UnlockModule(void) { InterlockedDecrement( &SHDOCVW_refCount ); }
-
-/* memory allocation functions */
-
-static inline void* __WINE_ALLOC_SIZE(1) heap_alloc(size_t len)
-{
- return HeapAlloc(GetProcessHeap(), 0, len);
-}
-
-static inline BOOL heap_free(void *mem)
-{
- return HeapFree(GetProcessHeap(), 0, mem);
-}
-
#endif /* __WINE_SHDOCVW_H */
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
-#include <windef.h>
+#include "windef.h"
1 WINE_REGISTRY "shdocvw_v1.rgs"
#define WINE_PRODUCTVERSION_STR "6.0.2900.2180"
#define WINE_EXTRAVALUES VALUE "OLESelfRegister",""
-#include <wine/wine_common_ver.rc>
+#include "wine/wine_common_ver.rc"
129 stub DoFileDownloadEx
130 stdcall -noname RunInstallUninstallStubs2(long)
131 stub -noname SHCreateSplashScreen
-132 stub DoOrganizeFavDlg
-133 stub DoOrganizeFavDlgW
+132 stdcall DoOrganizeFavDlg(long str)
+133 stdcall DoOrganizeFavDlgW(long wstr)
134 stub DoPrivacyDlg
135 stub -noname IsFileUrl
136 stub -noname IsFileUrlW
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
+#include "config.h"
+
+#include <stdarg.h>
+#include <stdio.h>
+
+#include "wine/unicode.h"
+#include "wine/debug.h"
+
#include "shdocvw.h"
-#include <shlwapi.h>
-#include <wininet.h>
+#include "winreg.h"
+#include "shlwapi.h"
+#include "wininet.h"
+#include "isguids.h"
+
+#include "initguid.h"
+
+WINE_DEFAULT_DEBUG_CHANNEL(shdocvw);
LONG SHDOCVW_refCount = 0;
HRESULT hr;
DWORD needed;
DWORD len;
- DWORD res = 0;
-
+ DWORD res;
TRACE("(%s, %p, %p, %p) len: %d, unknown: 0x%x\n", debugstr_w(url), out, plen, unknown,
plen ? *plen : 0, unknown ? *unknown : 0);
needed = lstrlenW(buffer_out)+1;
TRACE("got 0x%x with %s (need %d)\n", hr, debugstr_w(buffer_out), needed);
+ res = 0;
if (*plen >= needed) {
if (out != NULL) {
lstrcpyW(out, buffer_out);
- res++;
+ /* On success, 1 is returned for unicode version */
+ res = 1;
}
needed--;
}
if (*plen >= needed) {
if (out != NULL) {
WideCharToMultiByte(CP_ACP, 0, buffer, -1, out, *plen, NULL, NULL);
+ /* On success, string size including terminating 0 is returned for ansi version */
res = needed;
}
needed--;
FIXME("(%s) stub\n", debugstr_w(filename));
return FALSE;
}
+
+/******************************************************************
+ * DoOrganizeFavDlgW (SHDOCVW.@)
+ */
+BOOL WINAPI DoOrganizeFavDlgW(HWND hwnd, LPCWSTR initDir)
+{
+ FIXME("(%p %s) stub\n", hwnd, debugstr_w(initDir));
+ return FALSE;
+}
+
+/******************************************************************
+ * DoOrganizeFavDlg (SHDOCVW.@)
+ */
+BOOL WINAPI DoOrganizeFavDlg(HWND hwnd, LPCSTR initDir)
+{
+ LPWSTR initDirW = NULL;
+ BOOL res;
+
+ TRACE("(%p %s)\n", hwnd, debugstr_a(initDir));
+
+ if (initDir) {
+ DWORD len = MultiByteToWideChar(CP_ACP, 0, initDir, -1, NULL, 0);
+ initDirW = heap_alloc(len * sizeof(WCHAR));
+ MultiByteToWideChar(CP_ACP, 0, initDir, -1, initDirW, len);
+ }
+ res = DoOrganizeFavDlgW(hwnd, initDirW);
+ heap_free(initDirW);
+ return res;
+}
* some registry entries. This feature was introduced with win2k. Please
* search for 'Shell Instance Objects' on MSDN to get more information. */
+#include <stdarg.h>
+
+#define COBJMACROS
+
+#include "windef.h"
+#include "winbase.h"
+#include "winreg.h"
+#include "objbase.h"
+#include "oleauto.h"
+
#include "shdocvw.h"
+#include "wine/unicode.h"
+#include "wine/debug.h"
+
+WINE_DEFAULT_DEBUG_CHANNEL(shdocvw);
+
#define CHARS_IN_GUID 39
/******************************************************************************
reactos/dll/win32/sensapi # Synced to WineStaging-3.3
reactos/dll/win32/setupapi # Forked at Wine-20050524
reactos/dll/win32/shdoclc # Synced to WineStaging-3.3
-reactos/dll/win32/shdocvw # Synced to Wine-3.0
+reactos/dll/win32/shdocvw # Synced to WineStaging-3.3
reactos/dll/win32/shell32 # Forked at Wine-20071011
reactos/dll/win32/shfolder # Synced to WineStaging-2.9
reactos/dll/win32/shlwapi # Synced to WineStaging-3.3