mirror of
https://github.com/reactos/reactos.git
synced 2025-04-05 13:11:22 +00:00
[SHELL32][SHELL32_WINETEST] Connect CDefViewDual to CDefView to fix crashes in the shelldispatch test ROSTESTS-209
- CDefViewDual::get_Application now returns a new CDefView to fix the winetest. - Update CFolder, CFolderItem(s), CFolderItemVerb(s), CShell to use the new IDispatchImpl - Enable the last two skipped testcases (test_ShellFolderViewDual, test_ShellWindows) svn path=/trunk/; revision=71144
This commit is contained in:
parent
1591074c3f
commit
57c45625a3
11 changed files with 118 additions and 236 deletions
|
@ -46,9 +46,8 @@ class CDefViewDual :
|
|||
virtual HRESULT STDMETHODCALLTYPE get_Application(IDispatch **app) override
|
||||
{
|
||||
if (!app) return E_INVALIDARG;
|
||||
*app = NULL;
|
||||
FIXME("CDefViewDual::get_Application is UNIMPLEMENTED (%p, %p)\n", this, app);
|
||||
return E_NOTIMPL;
|
||||
|
||||
return CShell_Constructor(IID_IDispatch, (LPVOID*)app);
|
||||
}
|
||||
|
||||
virtual HRESULT STDMETHODCALLTYPE get_Parent(IDispatch **parent) override
|
||||
|
|
|
@ -36,38 +36,30 @@ void CFolder::Init(LPITEMIDLIST idlist)
|
|||
m_idlist.Attach(idlist);
|
||||
}
|
||||
|
||||
// *** IDispatch methods ***
|
||||
HRESULT STDMETHODCALLTYPE CFolder::GetTypeInfoCount(UINT *pctinfo)
|
||||
HRESULT CFolder::GetShellFolder(CComPtr<IShellFolder>& psfCurrent)
|
||||
{
|
||||
TRACE("(%p, %p)\n", this, pctinfo);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
CComPtr<IShellFolder> psfDesktop;
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CFolder::GetTypeInfo(UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo)
|
||||
{
|
||||
TRACE("(%p, %lu, %lu, %p)\n", this, iTInfo, lcid, ppTInfo);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
HRESULT hr = SHGetDesktopFolder(&psfDesktop);
|
||||
if (FAILED_UNEXPECTEDLY(hr))
|
||||
return hr;
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CFolder::GetIDsOfNames(REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId)
|
||||
{
|
||||
TRACE("(%p, %s, %p, %lu, %lu, %p)\n", this, wine_dbgstr_guid(&riid), rgszNames, cNames, lcid, rgDispId);
|
||||
return E_NOTIMPL;
|
||||
return psfDesktop->BindToObject(m_idlist, NULL, IID_PPV_ARG(IShellFolder, &psfCurrent));
|
||||
}
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CFolder::Invoke(DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
|
||||
{
|
||||
TRACE("(%p, %lu, %s, %lu, %lu, %p, %p, %p, %p)\n", this, dispIdMember, wine_dbgstr_guid(&riid), lcid, (DWORD)wFlags,
|
||||
pDispParams, pVarResult, pExcepInfo, puArgErr);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
|
||||
// *** Folder methods ***
|
||||
HRESULT STDMETHODCALLTYPE CFolder::get_Title(BSTR *pbs)
|
||||
{
|
||||
TRACE("(%p, %p)\n", this, pbs);
|
||||
return E_NOTIMPL;
|
||||
if (!pbs)
|
||||
return E_POINTER;
|
||||
|
||||
WCHAR path[MAX_PATH+2] = {0};
|
||||
HRESULT hr = ILGetDisplayNameExW(NULL, m_idlist, path, ILGDN_INFOLDER);
|
||||
if (FAILED_UNEXPECTEDLY(hr))
|
||||
return hr;
|
||||
|
||||
*pbs = SysAllocString(path);
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CFolder::get_Application(IDispatch **ppid)
|
||||
|
@ -97,15 +89,12 @@ HRESULT STDMETHODCALLTYPE CFolder::Items(FolderItems **ppid)
|
|||
HRESULT STDMETHODCALLTYPE CFolder::ParseName(BSTR bName, FolderItem **ppid)
|
||||
{
|
||||
TRACE("(%p, %s, %p)\n", this, wine_dbgstr_w(bName), ppid);
|
||||
|
||||
CComPtr<IShellFolder> psfDesktop;
|
||||
|
||||
HRESULT hr = SHGetDesktopFolder(&psfDesktop);
|
||||
if (FAILED_UNEXPECTEDLY(hr))
|
||||
return hr;
|
||||
if (!ppid)
|
||||
return E_POINTER;
|
||||
*ppid = NULL;
|
||||
|
||||
CComPtr<IShellFolder> psfCurrent;
|
||||
hr = psfDesktop->BindToObject(m_idlist, NULL, IID_PPV_ARG(IShellFolder, &psfCurrent));
|
||||
HRESULT hr = GetShellFolder(psfCurrent);
|
||||
if (FAILED_UNEXPECTEDLY(hr))
|
||||
return hr;
|
||||
|
||||
|
|
|
@ -25,9 +25,11 @@
|
|||
class CFolder:
|
||||
public CComCoClass<CFolder>,
|
||||
public CComObjectRootEx<CComMultiThreadModelNoCS>,
|
||||
public Folder2
|
||||
public IDispatchImpl<Folder2, &IID_Folder2>
|
||||
{
|
||||
private:
|
||||
HRESULT GetShellFolder(CComPtr<IShellFolder>& psfCurrent);
|
||||
|
||||
CComHeapPtr<ITEMIDLIST> m_idlist;
|
||||
|
||||
public:
|
||||
|
@ -36,13 +38,6 @@ public:
|
|||
|
||||
void Init(LPITEMIDLIST idlist);
|
||||
|
||||
// *** IDispatch methods ***
|
||||
virtual HRESULT STDMETHODCALLTYPE GetTypeInfoCount(UINT *pctinfo);
|
||||
virtual HRESULT STDMETHODCALLTYPE GetTypeInfo(UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo);
|
||||
virtual HRESULT STDMETHODCALLTYPE GetIDsOfNames(REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId);
|
||||
virtual HRESULT STDMETHODCALLTYPE Invoke(DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr);
|
||||
|
||||
|
||||
// *** Folder methods ***
|
||||
virtual HRESULT STDMETHODCALLTYPE get_Title(BSTR *pbs);
|
||||
virtual HRESULT STDMETHODCALLTYPE get_Application(IDispatch **ppid);
|
||||
|
|
|
@ -31,35 +31,10 @@ CFolderItemVerb::~CFolderItemVerb()
|
|||
{
|
||||
}
|
||||
|
||||
//void CFolderItemVerb::Init(LPITEMIDLIST idlist)
|
||||
//{
|
||||
// m_idlist.Attach(idlist);
|
||||
//}
|
||||
|
||||
// *** IDispatch methods ***
|
||||
HRESULT STDMETHODCALLTYPE CFolderItemVerb::GetTypeInfoCount(UINT *pctinfo)
|
||||
void CFolderItemVerb::Init(IContextMenu* menu, BSTR name)
|
||||
{
|
||||
TRACE("(%p, %p)\n", this, pctinfo);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CFolderItemVerb::GetTypeInfo(UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo)
|
||||
{
|
||||
TRACE("(%p, %lu, %lu, %p)\n", this, iTInfo, lcid, ppTInfo);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CFolderItemVerb::GetIDsOfNames(REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId)
|
||||
{
|
||||
TRACE("(%p, %s, %p, %lu, %lu, %p)\n", this, wine_dbgstr_guid(&riid), rgszNames, cNames, lcid, rgDispId);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CFolderItemVerb::Invoke(DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
|
||||
{
|
||||
TRACE("(%p, %lu, %s, %lu, %lu, %p, %p, %p, %p)\n", this, dispIdMember, wine_dbgstr_guid(&riid), lcid, (DWORD)wFlags,
|
||||
pDispParams, pVarResult, pExcepInfo, puArgErr);
|
||||
return E_NOTIMPL;
|
||||
m_contextmenu = menu;
|
||||
m_name.m_str = name;
|
||||
}
|
||||
|
||||
// *** FolderItemVerb methods ***
|
||||
|
@ -78,12 +53,10 @@ HRESULT STDMETHODCALLTYPE CFolderItemVerb::get_Parent(IDispatch **ppid)
|
|||
|
||||
HRESULT STDMETHODCALLTYPE CFolderItemVerb::get_Name(BSTR *pbs)
|
||||
{
|
||||
TRACE("(%p, %p)\n", this, pbs);
|
||||
if (!pbs)
|
||||
return E_POINTER;
|
||||
// Terminating item:
|
||||
*pbs = SysAllocString(L"");
|
||||
return E_NOTIMPL;
|
||||
*pbs = SysAllocString(m_name);
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CFolderItemVerb::DoIt()
|
||||
|
@ -98,52 +71,45 @@ HRESULT STDMETHODCALLTYPE CFolderItemVerb::DoIt()
|
|||
|
||||
|
||||
CFolderItemVerbs::CFolderItemVerbs()
|
||||
:m_menu(NULL)
|
||||
,m_count(0)
|
||||
{
|
||||
}
|
||||
|
||||
CFolderItemVerbs::~CFolderItemVerbs()
|
||||
{
|
||||
DestroyMenu(m_menu);
|
||||
}
|
||||
|
||||
//void CFolderItemVerbs::Init(LPITEMIDLIST idlist)
|
||||
//{
|
||||
// m_idlist.Attach(idlist);
|
||||
//}
|
||||
|
||||
// *** IDispatch methods ***
|
||||
HRESULT STDMETHODCALLTYPE CFolderItemVerbs::GetTypeInfoCount(UINT *pctinfo)
|
||||
HRESULT CFolderItemVerbs::Init(LPITEMIDLIST idlist)
|
||||
{
|
||||
TRACE("(%p, %p)\n", this, pctinfo);
|
||||
return E_NOTIMPL;
|
||||
CComPtr<IShellFolder> folder;
|
||||
LPCITEMIDLIST child;
|
||||
HRESULT hr = SHBindToParent(idlist, IID_PPV_ARG(IShellFolder, &folder), &child);
|
||||
if (FAILED_UNEXPECTEDLY(hr))
|
||||
return hr;
|
||||
|
||||
hr = folder->GetUIObjectOf(NULL, 1, &child, IID_IContextMenu, NULL, (PVOID*)&m_contextmenu);
|
||||
if (FAILED_UNEXPECTEDLY(hr))
|
||||
return hr;
|
||||
|
||||
m_menu = CreatePopupMenu();
|
||||
hr = m_contextmenu->QueryContextMenu(m_menu, 0, FCIDM_SHVIEWFIRST, FCIDM_SHVIEWLAST, CMF_NORMAL);
|
||||
if (!SUCCEEDED(hr))
|
||||
return hr;
|
||||
|
||||
m_count = GetMenuItemCount(m_menu);
|
||||
return hr;
|
||||
}
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CFolderItemVerbs::GetTypeInfo(UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo)
|
||||
{
|
||||
TRACE("(%p, %lu, %lu, %p)\n", this, iTInfo, lcid, ppTInfo);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CFolderItemVerbs::GetIDsOfNames(REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId)
|
||||
{
|
||||
TRACE("(%p, %s, %p, %lu, %lu, %p)\n", this, wine_dbgstr_guid(&riid), rgszNames, cNames, lcid, rgDispId);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CFolderItemVerbs::Invoke(DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
|
||||
{
|
||||
TRACE("(%p, %lu, %s, %lu, %lu, %p, %p, %p, %p)\n", this, dispIdMember, wine_dbgstr_guid(&riid), lcid, (DWORD)wFlags,
|
||||
pDispParams, pVarResult, pExcepInfo, puArgErr);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
// *** FolderItemVerbs methods ***
|
||||
HRESULT STDMETHODCALLTYPE CFolderItemVerbs::get_Count(LONG *plCount)
|
||||
{
|
||||
TRACE("(%p, %p)\n", this, plCount);
|
||||
if (!plCount)
|
||||
return E_POINTER;
|
||||
*plCount = 0;
|
||||
return E_NOTIMPL;
|
||||
*plCount = m_count;
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CFolderItemVerbs::get_Application(IDispatch **ppid)
|
||||
|
@ -158,18 +124,51 @@ HRESULT STDMETHODCALLTYPE CFolderItemVerbs::get_Parent(IDispatch **ppid)
|
|||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CFolderItemVerbs::Item(VARIANT index, FolderItemVerb **ppid)
|
||||
HRESULT STDMETHODCALLTYPE CFolderItemVerbs::Item(VARIANT indexVar, FolderItemVerb **ppid)
|
||||
{
|
||||
TRACE("(%p, %s, %p)\n", this, wine_dbgstr_variant(&index), ppid);
|
||||
if (!ppid)
|
||||
return E_POINTER;
|
||||
|
||||
/* FIXME! */
|
||||
CComVariant var;
|
||||
VariantCopyInd(&var, &indexVar);
|
||||
|
||||
HRESULT hr = VariantChangeType(&var, &var, 0, VT_I4);
|
||||
if (FAILED_UNEXPECTEDLY(hr))
|
||||
return E_INVALIDARG;
|
||||
|
||||
int index = V_I4(&var);
|
||||
|
||||
if (index > m_count)
|
||||
return S_OK;
|
||||
|
||||
BSTR name = NULL;
|
||||
|
||||
if(index == m_count)
|
||||
name = SysAllocStringLen(NULL, 0);
|
||||
else
|
||||
{
|
||||
MENUITEMINFOW info = { sizeof(info), 0 };
|
||||
info.fMask = MIIM_STRING;
|
||||
if (!GetMenuItemInfoW(m_menu, index, TRUE, &info))
|
||||
return E_FAIL;
|
||||
name = SysAllocStringLen(NULL, info.cch);
|
||||
if (name)
|
||||
{
|
||||
info.dwTypeData = name;
|
||||
info.cch++;
|
||||
GetMenuItemInfoW(m_menu, index, TRUE, &info);
|
||||
}
|
||||
}
|
||||
|
||||
if (!name)
|
||||
return E_OUTOFMEMORY;
|
||||
|
||||
CFolderItemVerb* verb = new CComObject<CFolderItemVerb>();
|
||||
verb->Init(m_contextmenu, name);
|
||||
verb->AddRef();
|
||||
*ppid = verb;
|
||||
|
||||
return E_NOTIMPL;
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CFolderItemVerbs::_NewEnum(IUnknown **ppunk)
|
||||
|
|
|
@ -24,22 +24,17 @@
|
|||
class CFolderItemVerb:
|
||||
public CComCoClass<CFolderItemVerb>,
|
||||
public CComObjectRootEx<CComMultiThreadModelNoCS>,
|
||||
public FolderItemVerb
|
||||
public IDispatchImpl<FolderItemVerb, &IID_FolderItemVerb>
|
||||
{
|
||||
private:
|
||||
CComPtr<IContextMenu> m_contextmenu;
|
||||
CComBSTR m_name;
|
||||
|
||||
public:
|
||||
CFolderItemVerb();
|
||||
~CFolderItemVerb();
|
||||
|
||||
//void Init(LPITEMIDLIST idlist);
|
||||
|
||||
|
||||
// *** IDispatch methods ***
|
||||
virtual HRESULT STDMETHODCALLTYPE GetTypeInfoCount(UINT *pctinfo);
|
||||
virtual HRESULT STDMETHODCALLTYPE GetTypeInfo(UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo);
|
||||
virtual HRESULT STDMETHODCALLTYPE GetIDsOfNames(REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId);
|
||||
virtual HRESULT STDMETHODCALLTYPE Invoke(DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr);
|
||||
void Init(IContextMenu* menu, BSTR name);
|
||||
|
||||
// *** FolderItemVerb methods ***
|
||||
virtual HRESULT STDMETHODCALLTYPE get_Application(IDispatch **ppid);
|
||||
|
@ -61,22 +56,18 @@ END_COM_MAP()
|
|||
class CFolderItemVerbs:
|
||||
public CComCoClass<CFolderItemVerbs>,
|
||||
public CComObjectRootEx<CComMultiThreadModelNoCS>,
|
||||
public FolderItemVerbs
|
||||
public IDispatchImpl<FolderItemVerbs, &IID_FolderItemVerbs>
|
||||
{
|
||||
private:
|
||||
CComPtr<IContextMenu> m_contextmenu;
|
||||
HMENU m_menu;
|
||||
int m_count;
|
||||
|
||||
public:
|
||||
CFolderItemVerbs();
|
||||
~CFolderItemVerbs();
|
||||
virtual ~CFolderItemVerbs();
|
||||
|
||||
//void Init(LPITEMIDLIST idlist);
|
||||
|
||||
|
||||
// *** IDispatch methods ***
|
||||
virtual HRESULT STDMETHODCALLTYPE GetTypeInfoCount(UINT *pctinfo);
|
||||
virtual HRESULT STDMETHODCALLTYPE GetTypeInfo(UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo);
|
||||
virtual HRESULT STDMETHODCALLTYPE GetIDsOfNames(REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId);
|
||||
virtual HRESULT STDMETHODCALLTYPE Invoke(DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr);
|
||||
HRESULT Init(LPITEMIDLIST idlist);
|
||||
|
||||
// *** FolderItemVerbs methods ***
|
||||
virtual HRESULT STDMETHODCALLTYPE get_Count(LONG *plCount);
|
||||
|
|
|
@ -36,32 +36,6 @@ void CFolderItem::Init(LPITEMIDLIST idlist)
|
|||
m_idlist.Attach(idlist);
|
||||
}
|
||||
|
||||
// *** IDispatch methods ***
|
||||
HRESULT STDMETHODCALLTYPE CFolderItem::GetTypeInfoCount(UINT *pctinfo)
|
||||
{
|
||||
TRACE("(%p, %p)\n", this, pctinfo);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CFolderItem::GetTypeInfo(UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo)
|
||||
{
|
||||
TRACE("(%p, %lu, %lu, %p)\n", this, iTInfo, lcid, ppTInfo);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CFolderItem::GetIDsOfNames(REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId)
|
||||
{
|
||||
TRACE("(%p, %s, %p, %lu, %lu, %p)\n", this, wine_dbgstr_guid(&riid), rgszNames, cNames, lcid, rgDispId);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CFolderItem::Invoke(DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
|
||||
{
|
||||
TRACE("(%p, %lu, %s, %lu, %lu, %p, %p, %p, %p)\n", this, dispIdMember, wine_dbgstr_guid(&riid), lcid, (DWORD)wFlags,
|
||||
pDispParams, pVarResult, pExcepInfo, puArgErr);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
// *** FolderItem methods ***
|
||||
HRESULT STDMETHODCALLTYPE CFolderItem::get_Application(IDispatch **ppid)
|
||||
{
|
||||
|
@ -165,9 +139,15 @@ HRESULT STDMETHODCALLTYPE CFolderItem::get_Type(BSTR *pbs)
|
|||
|
||||
HRESULT STDMETHODCALLTYPE CFolderItem::Verbs(FolderItemVerbs **ppfic)
|
||||
{
|
||||
if(!ppfic)
|
||||
if (!ppfic)
|
||||
return E_POINTER;
|
||||
CFolderItemVerbs* verbs = new CComObject<CFolderItemVerbs>();
|
||||
HRESULT hr = verbs->Init(m_idlist);
|
||||
if (FAILED_UNEXPECTEDLY(hr))
|
||||
{
|
||||
delete verbs;
|
||||
return hr;
|
||||
}
|
||||
verbs->AddRef();
|
||||
*ppfic = verbs;
|
||||
return S_OK;
|
||||
|
@ -181,8 +161,6 @@ HRESULT STDMETHODCALLTYPE CFolderItem::InvokeVerb(VARIANT vVerb)
|
|||
|
||||
|
||||
|
||||
|
||||
|
||||
CFolderItems::CFolderItems()
|
||||
{
|
||||
}
|
||||
|
@ -191,32 +169,6 @@ CFolderItems::~CFolderItems()
|
|||
{
|
||||
}
|
||||
|
||||
// *** IDispatch methods ***
|
||||
HRESULT STDMETHODCALLTYPE CFolderItems::GetTypeInfoCount(UINT *pctinfo)
|
||||
{
|
||||
TRACE("(%p, %p)\n", this, pctinfo);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CFolderItems::GetTypeInfo(UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo)
|
||||
{
|
||||
TRACE("(%p, %lu, %lu, %p)\n", this, iTInfo, lcid, ppTInfo);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CFolderItems::GetIDsOfNames(REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId)
|
||||
{
|
||||
TRACE("(%p, %s, %p, %lu, %lu, %p)\n", this, wine_dbgstr_guid(&riid), rgszNames, cNames, lcid, rgDispId);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CFolderItems::Invoke(DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
|
||||
{
|
||||
TRACE("(%p, %lu, %s, %lu, %lu, %p, %p, %p, %p)\n", this, dispIdMember, wine_dbgstr_guid(&riid), lcid, (DWORD)wFlags,
|
||||
pDispParams, pVarResult, pExcepInfo, puArgErr);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
// *** FolderItems methods ***
|
||||
HRESULT STDMETHODCALLTYPE CFolderItems::get_Count(long *plCount)
|
||||
{
|
||||
|
|
|
@ -25,7 +25,7 @@
|
|||
class CFolderItem:
|
||||
public CComCoClass<CFolderItem>,
|
||||
public CComObjectRootEx<CComMultiThreadModelNoCS>,
|
||||
public FolderItem
|
||||
public IDispatchImpl<FolderItem, &IID_FolderItem>
|
||||
{
|
||||
private:
|
||||
CComHeapPtr<ITEMIDLIST> m_idlist;
|
||||
|
@ -37,12 +37,6 @@ public:
|
|||
void Init(LPITEMIDLIST idlist);
|
||||
|
||||
|
||||
// *** IDispatch methods ***
|
||||
virtual HRESULT STDMETHODCALLTYPE GetTypeInfoCount(UINT *pctinfo);
|
||||
virtual HRESULT STDMETHODCALLTYPE GetTypeInfo(UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo);
|
||||
virtual HRESULT STDMETHODCALLTYPE GetIDsOfNames(REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId);
|
||||
virtual HRESULT STDMETHODCALLTYPE Invoke(DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr);
|
||||
|
||||
// *** FolderItem methods ***
|
||||
virtual HRESULT STDMETHODCALLTYPE get_Application(IDispatch **ppid);
|
||||
virtual HRESULT STDMETHODCALLTYPE get_Parent(IDispatch **ppid);
|
||||
|
@ -75,7 +69,7 @@ END_COM_MAP()
|
|||
class CFolderItems:
|
||||
public CComCoClass<CFolderItems>,
|
||||
public CComObjectRootEx<CComMultiThreadModelNoCS>,
|
||||
public FolderItems
|
||||
public IDispatchImpl<FolderItems, &IID_FolderItems>
|
||||
{
|
||||
private:
|
||||
|
||||
|
@ -83,12 +77,6 @@ public:
|
|||
CFolderItems();
|
||||
~CFolderItems();
|
||||
|
||||
// *** IDispatch methods ***
|
||||
virtual HRESULT STDMETHODCALLTYPE GetTypeInfoCount(UINT *pctinfo);
|
||||
virtual HRESULT STDMETHODCALLTYPE GetTypeInfo(UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo);
|
||||
virtual HRESULT STDMETHODCALLTYPE GetIDsOfNames(REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId);
|
||||
virtual HRESULT STDMETHODCALLTYPE Invoke(DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr);
|
||||
|
||||
// *** FolderItems methods ***
|
||||
virtual HRESULT STDMETHODCALLTYPE get_Count(long *plCount);
|
||||
virtual HRESULT STDMETHODCALLTYPE get_Application(IDispatch **ppid);
|
||||
|
|
|
@ -31,34 +31,11 @@ CShell::~CShell()
|
|||
{
|
||||
}
|
||||
|
||||
|
||||
// *** IDispatch methods ***
|
||||
HRESULT STDMETHODCALLTYPE CShell::GetTypeInfoCount(UINT *pctinfo)
|
||||
HRESULT CShell::Initialize()
|
||||
{
|
||||
TRACE("(%p, %p)\n", this, pctinfo);
|
||||
return E_NOTIMPL;
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CShell::GetTypeInfo(UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo)
|
||||
{
|
||||
TRACE("(%p, %lu, %lu, %p)\n", this, iTInfo, lcid, ppTInfo);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CShell::GetIDsOfNames(REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId)
|
||||
{
|
||||
TRACE("(%p, %s, %p, %lu, %lu, %p)\n", this, wine_dbgstr_guid(&riid), rgszNames, cNames, lcid, rgDispId);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
HRESULT STDMETHODCALLTYPE CShell::Invoke(DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
|
||||
{
|
||||
TRACE("(%p, %lu, %s, %lu, %lu, %p, %p, %p, %p)\n", this, dispIdMember, wine_dbgstr_guid(&riid), lcid, (DWORD)wFlags,
|
||||
pDispParams, pVarResult, pExcepInfo, puArgErr);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
|
||||
// *** IShellDispatch methods ***
|
||||
HRESULT STDMETHODCALLTYPE CShell::get_Application(IDispatch **ppid)
|
||||
{
|
||||
|
@ -341,4 +318,8 @@ HRESULT STDMETHODCALLTYPE CShell::GetSite(REFIID riid, PVOID *ppvSite)
|
|||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
HRESULT WINAPI CShell_Constructor(REFIID riid, LPVOID * ppvOut)
|
||||
{
|
||||
return ShellObjectCreatorInit<CShell>(riid, ppvOut);
|
||||
}
|
||||
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
class CShell:
|
||||
public CComCoClass<CShell, &CLSID_Shell>,
|
||||
public CComObjectRootEx<CComMultiThreadModelNoCS>,
|
||||
public IShellDispatch4,
|
||||
public IDispatchImpl<IShellDispatch4, &IID_IShellDispatch4>,
|
||||
public IObjectSafety,
|
||||
public IObjectWithSite
|
||||
{
|
||||
|
@ -36,11 +36,7 @@ public:
|
|||
CShell();
|
||||
~CShell();
|
||||
|
||||
// *** IDispatch methods ***
|
||||
virtual HRESULT STDMETHODCALLTYPE GetTypeInfoCount(UINT *pctinfo);
|
||||
virtual HRESULT STDMETHODCALLTYPE GetTypeInfo(UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo);
|
||||
virtual HRESULT STDMETHODCALLTYPE GetIDsOfNames(REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId);
|
||||
virtual HRESULT STDMETHODCALLTYPE Invoke(DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr);
|
||||
HRESULT Initialize();
|
||||
|
||||
// *** IShellDispatch methods ***
|
||||
virtual HRESULT STDMETHODCALLTYPE get_Application(IDispatch **ppid);
|
||||
|
|
|
@ -72,6 +72,7 @@ IContextMenu2 * ISvBgCm_Constructor(LPSHELLFOLDER pSFParent, BOOL bDesktop);
|
|||
HRESULT WINAPI IShellView_Constructor(IShellFolder *pFolder, IShellView **newView);
|
||||
HRESULT WINAPI CDefView_Constructor(IShellFolder *pFolder, REFIID riid, LPVOID * ppvOut);
|
||||
HRESULT WINAPI CDefViewDual_Constructor(REFIID riid, LPVOID * ppvOut);
|
||||
HRESULT WINAPI CShell_Constructor(REFIID riid, LPVOID * ppvOut);
|
||||
|
||||
HRESULT WINAPI IShellLink_ConstructFromFile(IUnknown * pUnkOuter, REFIID riid, LPCITEMIDLIST pidl, LPVOID * ppv);
|
||||
HRESULT WINAPI IFileSystemBindData_Constructor(const WIN32_FIND_DATAW *pfd, LPBC *ppV);
|
||||
|
|
|
@ -880,17 +880,8 @@ START_TEST(shelldispatch)
|
|||
init_function_pointers();
|
||||
test_namespace();
|
||||
test_service();
|
||||
#ifdef __REACTOS__
|
||||
if (!winetest_interactive)
|
||||
skip("ROSTESTS-209: Skipping test_ShellFolderViewDual() and test_ShellWindows().\n");
|
||||
else
|
||||
{
|
||||
#endif
|
||||
test_ShellFolderViewDual();
|
||||
test_ShellWindows();
|
||||
#ifdef __REACTOS__
|
||||
}
|
||||
#endif
|
||||
test_ParseName();
|
||||
test_Verbs();
|
||||
|
||||
|
|
Loading…
Reference in a new issue