Commit e8bc1034 authored by Michael Müller's avatar Michael Müller Committed by Vitaly Lipatov

shell32: Implement NewMenu with new folder item.

v2: Added and Correct tests Use IContextMenu3 for all IContextMenu* interfaces. Use heap_alloc/free functions v3: Correct header issue when compiling i386 (var_arg)
parent 782d47f4
......@@ -28,6 +28,7 @@ C_SRCS = \
shelldispatch.c \
shellitem.c \
shelllink.c \
shellnew.c \
shellole.c \
shellord.c \
shellpath.c \
......
......@@ -88,6 +88,11 @@ coclass KnownFolderManager { interface IKnownFolderManager; }
[
threading(apartment),
uuid(d969a300-e7ff-11d0-a93b-00a0c90f2719)
] coclass NewMenu { interface IShellExtInit; }
[
threading(apartment),
uuid(00bb2763-6a77-11d0-a535-00c04fd7d062)
] coclass AutoComplete { interface IAutoComplete2; }
......
......@@ -101,6 +101,7 @@ HRESULT WINAPI RecycleBin_Constructor(IUnknown * pUnkOuter, REFIID riif, LPVOID
HRESULT WINAPI QueryAssociations_Constructor(IUnknown *pUnkOuter, REFIID riid, LPVOID *ppOutput) DECLSPEC_HIDDEN;
HRESULT WINAPI ExplorerBrowser_Constructor(IUnknown *pUnkOuter, REFIID riid, LPVOID *ppv) DECLSPEC_HIDDEN;
HRESULT WINAPI KnownFolderManager_Constructor(IUnknown *pUnkOuter, REFIID riid, LPVOID *ppv) DECLSPEC_HIDDEN;
HRESULT WINAPI NewMenu_Constructor(IUnknown *outer, REFIID riid, LPVOID *ppv) DECLSPEC_HIDDEN;
HRESULT WINAPI IFileOperation_Constructor(IUnknown *outer, REFIID riid, void **out) DECLSPEC_HIDDEN;
extern HRESULT CPanel_GetIconLocationW(LPCITEMIDLIST, LPWSTR, UINT, int*) DECLSPEC_HIDDEN;
HRESULT WINAPI CPanel_ExtractIconA(LPITEMIDLIST pidl, LPCSTR pszFile, UINT nIconIndex, HICON *phiconLarge, HICON *phiconSmall, UINT nIconSize) DECLSPEC_HIDDEN;
......
......@@ -72,6 +72,7 @@ static const struct {
{&CLSID_MyComputer, ISF_MyComputer_Constructor},
{&CLSID_MyDocuments, MyDocuments_Constructor},
{&CLSID_NetworkPlaces, ISF_NetworkPlaces_Constructor},
{&CLSID_NewMenu, NewMenu_Constructor},
{&CLSID_Printers, Printers_Constructor},
{&CLSID_QueryAssociations, QueryAssociations_Constructor},
{&CLSID_RecycleBin, RecycleBin_Constructor},
......
......@@ -1478,7 +1478,6 @@ static void test_newmenu(void)
HRESULT hr;
hr = CoCreateInstance(&CLSID_NewMenu, NULL, CLSCTX_INPROC_SERVER, &IID_IUnknown, (void **)&unk);
todo_wine
ok(hr == S_OK, "Failed to create NewMenu object, hr %#lx.\n", hr);
if (hr != S_OK)
{
......@@ -1490,6 +1489,14 @@ static void test_newmenu(void)
ok(hr == S_OK, "Failed to get IShellExtInit, hr %#lx.\n", hr);
IUnknown_Release(unk2);
hr = IUnknown_QueryInterface(unk, &IID_IContextMenu, (void **)&unk2);
ok(hr == S_OK, "Failed to get IContextMenu, hr %#lx.\n", hr);
IUnknown_Release(unk2);
hr = IUnknown_QueryInterface(unk, &IID_IContextMenu2, (void **)&unk2);
ok(hr == S_OK, "Failed to get IContextMenu2, hr %#lx.\n", hr);
IUnknown_Release(unk2);
hr = IUnknown_QueryInterface(unk, &IID_IContextMenu3, (void **)&unk2);
ok(hr == S_OK, "Failed to get IContextMenu3, hr %#lx.\n", hr);
IUnknown_Release(unk2);
......
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