Added patch for shell32 IDragSourceHelper stub interface.

This commit is contained in:
Sebastian Lackner 2015-08-15 18:22:30 +02:00
parent 671aa4f38e
commit 2c35b17c61
6 changed files with 369 additions and 1 deletions

View File

@ -39,8 +39,9 @@ Wine. All those differences are also documented on the
Included bug fixes and improvements
-----------------------------------
**Bug fixes and features included in the next upcoming release [6]:**
**Bug fixes and features included in the next upcoming release [7]:**
* Add IDragSourceHelper stub interface ([Wine Bug #24699](https://bugs.winehq.org/show_bug.cgi?id=24699))
* Catch invalid memory accesses in imagehlp.CheckSumMappedFile
* Fix implementation of ntdll.MapViewOfSection
* Implement enumeration of sound devices and basic properties to dxdiagn ([Wine Bug #32613](https://bugs.winehq.org/show_bug.cgi?id=32613))

1
debian/changelog vendored
View File

@ -6,6 +6,7 @@ wine-staging (1.7.50) UNRELEASED; urgency=low
to dxdiagn.
* Added patch to implement special handling for calling GetChildContainer with
an empty string.
* Added patch for shell32 IDragSourceHelper stub interface.
* Removed patch to move security cookie initialization from memory management
to loader.
-- Sebastian Lackner <sebastian@fds-team.de> Tue, 11 Aug 2015 06:12:14 +0200

View File

@ -225,6 +225,7 @@ patch_enable_all ()
enable_shdocvw_ParseURLFromOutsideSource_Tests="$1"
enable_shell32_Default_Path="$1"
enable_shell32_File_Property_Dialog="$1"
enable_shell32_IDragSourceHelper="$1"
enable_shell32_Icons="$1"
enable_shell32_Placeholder_Icons="$1"
enable_shell32_Progress_Dialog="$1"
@ -761,6 +762,9 @@ patch_enable ()
shell32-File_Property_Dialog)
enable_shell32_File_Property_Dialog="$2"
;;
shell32-IDragSourceHelper)
enable_shell32_IDragSourceHelper="$2"
;;
shell32-Icons)
enable_shell32_Icons="$2"
;;
@ -4647,6 +4651,23 @@ if test "$enable_shell32_File_Property_Dialog" -eq 1; then
) >> "$patchlist"
fi
# Patchset shell32-IDragSourceHelper
# |
# | This patchset fixes the following Wine bugs:
# | * [#24699] Add IDragSourceHelper stub interface
# |
# | Modified files:
# | * dlls/shell32/dragdrophelper.c
# |
if test "$enable_shell32_IDragSourceHelper" -eq 1; then
patch_apply shell32-IDragSourceHelper/0001-shell32-Cleanup-IDropTargetHelper-and-preparation-fo.patch
patch_apply shell32-IDragSourceHelper/0002-shell32-Add-IDragSourceHelper-stub-interface.patch
(
echo '+ { "Michael Müller", "shell32: Cleanup IDropTargetHelper and preparation for IDragSourceHelper.", 1 },';
echo '+ { "Michael Müller", "shell32: Add IDragSourceHelper stub interface.", 1 },';
) >> "$patchlist"
fi
# Patchset shell32-Icons
# |
# | This patchset fixes the following Wine bugs:

View File

@ -0,0 +1,237 @@
From ece7ecf8bc9c4e6d9c44ffbf1f8a4a0b8c785a9b Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
Date: Sat, 15 Aug 2015 17:31:08 +0200
Subject: shell32: Cleanup IDropTargetHelper and preparation for
IDragSourceHelper.
---
dlls/shell32/dragdrophelper.c | 135 +++++++++++++++++++++---------------------
1 file changed, 68 insertions(+), 67 deletions(-)
diff --git a/dlls/shell32/dragdrophelper.c b/dlls/shell32/dragdrophelper.c
index cae8b8d..2705793 100644
--- a/dlls/shell32/dragdrophelper.c
+++ b/dlls/shell32/dragdrophelper.c
@@ -1,8 +1,9 @@
/*
* file system folder
*
- * Copyright 1997 Marcus Meissner
- * Copyright 1998, 1999, 2002 Juergen Schmied
+ * Copyright 1997 Marcus Meissner
+ * Copyright 1998, 1999, 2002 Juergen Schmied
+ * Copyright 2015 Michael Müller
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -47,45 +48,15 @@ WINE_DEFAULT_DEBUG_CHANNEL (shell);
* IDropTargetHelper implementation
*/
-typedef struct {
+typedef struct
+{
IDropTargetHelper IDropTargetHelper_iface;
LONG ref;
-} IDropTargetHelperImpl;
-
-static const IDropTargetHelperVtbl vt_IDropTargetHelper;
-
-static inline IDropTargetHelperImpl *impl_from_IDropTargetHelper(IDropTargetHelper *iface)
-{
- return CONTAINING_RECORD(iface, IDropTargetHelperImpl, IDropTargetHelper_iface);
-}
+} IDragHelperImpl;
-/**************************************************************************
-* IDropTargetHelper_Constructor
-*/
-HRESULT WINAPI IDropTargetHelper_Constructor (IUnknown * pUnkOuter, REFIID riid, LPVOID * ppv)
+static inline IDragHelperImpl *impl_from_IDropTargetHelper(IDropTargetHelper *iface)
{
- IDropTargetHelperImpl *dth;
-
- TRACE ("unkOut=%p %s\n", pUnkOuter, shdebugstr_guid (riid));
-
- if (!ppv)
- return E_POINTER;
- if (pUnkOuter)
- return CLASS_E_NOAGGREGATION;
-
- dth = LocalAlloc (LMEM_ZEROINIT, sizeof (IDropTargetHelperImpl));
- if (!dth) return E_OUTOFMEMORY;
-
- dth->ref = 0;
- dth->IDropTargetHelper_iface.lpVtbl = &vt_IDropTargetHelper;
-
- if (FAILED (IDropTargetHelper_QueryInterface (&dth->IDropTargetHelper_iface, riid, ppv))) {
- LocalFree(dth);
- return E_NOINTERFACE;
- }
-
- TRACE ("--(%p)\n", dth);
- return S_OK;
+ return CONTAINING_RECORD(iface, IDragHelperImpl, IDropTargetHelper_iface);
}
/**************************************************************************
@@ -93,28 +64,31 @@ HRESULT WINAPI IDropTargetHelper_Constructor (IUnknown * pUnkOuter, REFIID riid,
*/
static HRESULT WINAPI IDropTargetHelper_fnQueryInterface (IDropTargetHelper * iface, REFIID riid, LPVOID * ppvObj)
{
- IDropTargetHelperImpl *This = impl_from_IDropTargetHelper(iface);
+ IDragHelperImpl *This = impl_from_IDropTargetHelper(iface);
TRACE ("(%p)->(%s,%p)\n", This, shdebugstr_guid (riid), ppvObj);
*ppvObj = NULL;
- if (IsEqualIID (riid, &IID_IUnknown) || IsEqualIID (riid, &IID_IDropTargetHelper)) {
- *ppvObj = &This->IDropTargetHelper_iface;
+ if (IsEqualIID (riid, &IID_IUnknown) || IsEqualIID (riid, &IID_IDropTargetHelper))
+ {
+ *ppvObj = &This->IDropTargetHelper_iface;
}
- if (*ppvObj) {
- IUnknown_AddRef ((IUnknown *) (*ppvObj));
- TRACE ("-- Interface: (%p)->(%p)\n", ppvObj, *ppvObj);
- return S_OK;
+ if (*ppvObj)
+ {
+ IUnknown_AddRef ((IUnknown *) (*ppvObj));
+ TRACE ("-- Interface: (%p)->(%p)\n", ppvObj, *ppvObj);
+ return S_OK;
}
+
FIXME ("-- Interface: E_NOINTERFACE\n");
return E_NOINTERFACE;
}
static ULONG WINAPI IDropTargetHelper_fnAddRef (IDropTargetHelper * iface)
{
- IDropTargetHelperImpl *This = impl_from_IDropTargetHelper(iface);
+ IDragHelperImpl *This = impl_from_IDropTargetHelper(iface);
ULONG refCount = InterlockedIncrement(&This->ref);
TRACE ("(%p)->(count=%u)\n", This, refCount - 1);
@@ -124,67 +98,94 @@ static ULONG WINAPI IDropTargetHelper_fnAddRef (IDropTargetHelper * iface)
static ULONG WINAPI IDropTargetHelper_fnRelease (IDropTargetHelper * iface)
{
- IDropTargetHelperImpl *This = impl_from_IDropTargetHelper(iface);
+ IDragHelperImpl *This = impl_from_IDropTargetHelper(iface);
ULONG refCount = InterlockedDecrement(&This->ref);
TRACE ("(%p)->(count=%u)\n", This, refCount + 1);
- if (!refCount) {
+ if (!refCount)
+ {
TRACE ("-- destroying (%p)\n", This);
- LocalFree (This);
+ HeapFree(GetProcessHeap(), 0, This);
return 0;
}
return refCount;
}
-static HRESULT WINAPI IDropTargetHelper_fnDragEnter (
- IDropTargetHelper * iface,
- HWND hwndTarget,
- IDataObject* pDataObject,
- POINT* ppt,
- DWORD dwEffect)
+static HRESULT WINAPI IDropTargetHelper_fnDragEnter (IDropTargetHelper * iface, HWND hwndTarget,
+ IDataObject* pDataObject,POINT* ppt, DWORD dwEffect)
{
- IDropTargetHelperImpl *This = impl_from_IDropTargetHelper(iface);
+ IDragHelperImpl *This = impl_from_IDropTargetHelper(iface);
FIXME ("(%p)->(%p %p %p 0x%08x)\n", This,hwndTarget, pDataObject, ppt, dwEffect);
return E_NOTIMPL;
}
static HRESULT WINAPI IDropTargetHelper_fnDragLeave (IDropTargetHelper * iface)
{
- IDropTargetHelperImpl *This = impl_from_IDropTargetHelper(iface);
+ IDragHelperImpl *This = impl_from_IDropTargetHelper(iface);
FIXME ("(%p)->()\n", This);
return E_NOTIMPL;
}
static HRESULT WINAPI IDropTargetHelper_fnDragOver (IDropTargetHelper * iface, POINT* ppt, DWORD dwEffect)
{
- IDropTargetHelperImpl *This = impl_from_IDropTargetHelper(iface);
+ IDragHelperImpl *This = impl_from_IDropTargetHelper(iface);
FIXME ("(%p)->(%p 0x%08x)\n", This, ppt, dwEffect);
return E_NOTIMPL;
}
static HRESULT WINAPI IDropTargetHelper_fnDrop (IDropTargetHelper * iface, IDataObject* pDataObject, POINT* ppt, DWORD dwEffect)
{
- IDropTargetHelperImpl *This = impl_from_IDropTargetHelper(iface);
+ IDragHelperImpl *This = impl_from_IDropTargetHelper(iface);
FIXME ("(%p)->(%p %p 0x%08x)\n", This, pDataObject, ppt, dwEffect);
return E_NOTIMPL;
}
static HRESULT WINAPI IDropTargetHelper_fnShow (IDropTargetHelper * iface, BOOL fShow)
{
- IDropTargetHelperImpl *This = impl_from_IDropTargetHelper(iface);
+ IDragHelperImpl *This = impl_from_IDropTargetHelper(iface);
FIXME ("(%p)->(%u)\n", This, fShow);
return E_NOTIMPL;
}
static const IDropTargetHelperVtbl vt_IDropTargetHelper =
{
- IDropTargetHelper_fnQueryInterface,
- IDropTargetHelper_fnAddRef,
- IDropTargetHelper_fnRelease,
- IDropTargetHelper_fnDragEnter,
- IDropTargetHelper_fnDragLeave,
- IDropTargetHelper_fnDragOver,
- IDropTargetHelper_fnDrop,
- IDropTargetHelper_fnShow
+ IDropTargetHelper_fnQueryInterface,
+ IDropTargetHelper_fnAddRef,
+ IDropTargetHelper_fnRelease,
+ IDropTargetHelper_fnDragEnter,
+ IDropTargetHelper_fnDragLeave,
+ IDropTargetHelper_fnDragOver,
+ IDropTargetHelper_fnDrop,
+ IDropTargetHelper_fnShow
};
+
+/**************************************************************************
+* IDropTargetHelper_Constructor
+*/
+HRESULT WINAPI IDropTargetHelper_Constructor (IUnknown * pUnkOuter, REFIID riid, LPVOID * ppv)
+{
+ IDragHelperImpl *dth;
+
+ TRACE ("unkOut=%p %s\n", pUnkOuter, shdebugstr_guid (riid));
+
+ if (!ppv)
+ return E_POINTER;
+ if (pUnkOuter)
+ return CLASS_E_NOAGGREGATION;
+
+ dth = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof (IDragHelperImpl));
+ if (!dth) return E_OUTOFMEMORY;
+
+ dth->ref = 0;
+ dth->IDropTargetHelper_iface.lpVtbl = &vt_IDropTargetHelper;
+
+ if (FAILED(IDropTargetHelper_QueryInterface (&dth->IDropTargetHelper_iface, riid, ppv)))
+ {
+ HeapFree(GetProcessHeap(), 0, dth);
+ return E_NOINTERFACE;
+ }
+
+ TRACE ("--(%p)\n", dth);
+ return S_OK;
+}
--
2.5.0

View File

@ -0,0 +1,107 @@
From 02c2de6fb0417b118d575b38afadb9d893b364e9 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
Date: Sat, 15 Aug 2015 18:06:36 +0200
Subject: shell32: Add IDragSourceHelper stub interface.
---
dlls/shell32/dragdrophelper.c | 56 +++++++++++++++++++++++++++++++++++++++++++
1 file changed, 56 insertions(+)
diff --git a/dlls/shell32/dragdrophelper.c b/dlls/shell32/dragdrophelper.c
index 2705793..91dacc9 100644
--- a/dlls/shell32/dragdrophelper.c
+++ b/dlls/shell32/dragdrophelper.c
@@ -51,6 +51,7 @@ WINE_DEFAULT_DEBUG_CHANNEL (shell);
typedef struct
{
IDropTargetHelper IDropTargetHelper_iface;
+ IDragSourceHelper IDragSourceHelper_iface;
LONG ref;
} IDragHelperImpl;
@@ -59,6 +60,11 @@ static inline IDragHelperImpl *impl_from_IDropTargetHelper(IDropTargetHelper *if
return CONTAINING_RECORD(iface, IDragHelperImpl, IDropTargetHelper_iface);
}
+static inline IDragHelperImpl *impl_from_IDragSourceHelper(IDragSourceHelper *iface)
+{
+ return CONTAINING_RECORD(iface, IDragHelperImpl, IDragSourceHelper_iface);
+}
+
/**************************************************************************
* IDropTargetHelper_fnQueryInterface
*/
@@ -74,6 +80,10 @@ static HRESULT WINAPI IDropTargetHelper_fnQueryInterface (IDropTargetHelper * if
{
*ppvObj = &This->IDropTargetHelper_iface;
}
+ else if (IsEqualIID (riid, &IID_IDragSourceHelper))
+ {
+ *ppvObj = &This->IDragSourceHelper_iface;
+ }
if (*ppvObj)
{
@@ -160,6 +170,51 @@ static const IDropTargetHelperVtbl vt_IDropTargetHelper =
IDropTargetHelper_fnShow
};
+static HRESULT WINAPI IDragSourceHelper_fnQueryInterface (IDragSourceHelper * iface, REFIID riid, LPVOID * ppv)
+{
+ IDragHelperImpl *This = impl_from_IDragSourceHelper(iface);
+ return IDropTargetHelper_fnQueryInterface(&This->IDropTargetHelper_iface, riid, ppv);
+}
+
+static ULONG WINAPI IDragSourceHelper_fnAddRef (IDragSourceHelper * iface)
+{
+ IDragHelperImpl *This = impl_from_IDragSourceHelper(iface);
+ return IDropTargetHelper_fnAddRef(&This->IDropTargetHelper_iface);
+}
+
+static ULONG WINAPI IDragSourceHelper_fnRelease (IDragSourceHelper * iface)
+{
+ IDragHelperImpl *This = impl_from_IDragSourceHelper(iface);
+ return IDropTargetHelper_fnRelease(&This->IDropTargetHelper_iface);
+}
+
+static HRESULT WINAPI IDragSourceHelper_fnInitializeFromBitmap(IDragSourceHelper * iface, LPSHDRAGIMAGE pshdi,
+ IDataObject *object)
+{
+ IDragHelperImpl *This = impl_from_IDragSourceHelper(iface);
+
+ FIXME("(%p)->(%p, %p): stub\n", This, pshdi, object);
+ return S_OK;
+}
+
+static HRESULT WINAPI IDragSourceHelper_fnInitializeFromWindow(IDragSourceHelper * iface, HWND hwnd, POINT *ppt,
+ IDataObject *object)
+{
+ IDragHelperImpl *This = impl_from_IDragSourceHelper(iface);
+
+ FIXME("(%p)->(%p, %p, %p): stub\n", This, hwnd, ppt, object);
+ return S_OK;
+}
+
+static const IDragSourceHelperVtbl vt_IDragSourceHelper =
+{
+ IDragSourceHelper_fnQueryInterface,
+ IDragSourceHelper_fnAddRef,
+ IDragSourceHelper_fnRelease,
+ IDragSourceHelper_fnInitializeFromBitmap,
+ IDragSourceHelper_fnInitializeFromWindow
+};
+
/**************************************************************************
* IDropTargetHelper_Constructor
*/
@@ -179,6 +234,7 @@ HRESULT WINAPI IDropTargetHelper_Constructor (IUnknown * pUnkOuter, REFIID riid,
dth->ref = 0;
dth->IDropTargetHelper_iface.lpVtbl = &vt_IDropTargetHelper;
+ dth->IDragSourceHelper_iface.lpVtbl = &vt_IDragSourceHelper;
if (FAILED(IDropTargetHelper_QueryInterface (&dth->IDropTargetHelper_iface, riid, ppv)))
{
--
2.5.0

View File

@ -0,0 +1 @@
Fixes: [24699] Add IDragSourceHelper stub interface