Commit 3ec3fa5e authored by Nikolay Sivov's avatar Nikolay Sivov Committed by Alexandre Julliard

explorer: Return desktop shellview interface.

parent 7ce1813f
...@@ -631,6 +631,10 @@ if (hr == S_OK) ...@@ -631,6 +631,10 @@ if (hr == S_OK)
hr = IShellBrowser_QueryInterface(sb, &IID_IDispatch, (void**)&unk); hr = IShellBrowser_QueryInterface(sb, &IID_IDispatch, (void**)&unk);
ok(hr == E_NOINTERFACE, "got 0x%08x\n", hr); ok(hr == E_NOINTERFACE, "got 0x%08x\n", hr);
hr = IShellBrowser_QueryActiveShellView(sb, &sv);
ok(hr == S_OK, "got 0x%08x\n", hr);
IShellView_Release(sv);
IShellBrowser_Release(sb2); IShellBrowser_Release(sb2);
IShellBrowser_Release(sb); IShellBrowser_Release(sb);
......
...@@ -141,6 +141,7 @@ struct shellbrowserwindow ...@@ -141,6 +141,7 @@ struct shellbrowserwindow
IWebBrowser2 IWebBrowser2_iface; IWebBrowser2 IWebBrowser2_iface;
IServiceProvider IServiceProvider_iface; IServiceProvider IServiceProvider_iface;
IShellBrowser IShellBrowser_iface; IShellBrowser IShellBrowser_iface;
IShellView *view;
}; };
static struct shellwindows shellwindows; static struct shellwindows shellwindows;
...@@ -2103,8 +2104,11 @@ static HRESULT WINAPI shellbrowser_SendControlMsg(IShellBrowser *iface, UINT id, ...@@ -2103,8 +2104,11 @@ static HRESULT WINAPI shellbrowser_SendControlMsg(IShellBrowser *iface, UINT id,
static HRESULT WINAPI shellbrowser_QueryActiveShellView(IShellBrowser *iface, IShellView **view) static HRESULT WINAPI shellbrowser_QueryActiveShellView(IShellBrowser *iface, IShellView **view)
{ {
FIXME("%p\n", view); TRACE("%p\n", view);
return E_NOTIMPL;
*view = desktopshellbrowserwindow.view;
IShellView_AddRef(*view);
return S_OK;
} }
static HRESULT WINAPI shellbrowser_OnViewWindowActive(IShellBrowser *iface, IShellView *view) static HRESULT WINAPI shellbrowser_OnViewWindowActive(IShellBrowser *iface, IShellView *view)
...@@ -2143,9 +2147,16 @@ static const IShellBrowserVtbl shellbrowservtbl = { ...@@ -2143,9 +2147,16 @@ static const IShellBrowserVtbl shellbrowservtbl = {
static void desktopshellbrowserwindow_init(void) static void desktopshellbrowserwindow_init(void)
{ {
IShellFolder *folder;
desktopshellbrowserwindow.IWebBrowser2_iface.lpVtbl = &webbrowser2vtbl; desktopshellbrowserwindow.IWebBrowser2_iface.lpVtbl = &webbrowser2vtbl;
desktopshellbrowserwindow.IServiceProvider_iface.lpVtbl = &serviceprovidervtbl; desktopshellbrowserwindow.IServiceProvider_iface.lpVtbl = &serviceprovidervtbl;
desktopshellbrowserwindow.IShellBrowser_iface.lpVtbl = &shellbrowservtbl; desktopshellbrowserwindow.IShellBrowser_iface.lpVtbl = &shellbrowservtbl;
if (FAILED(SHGetDesktopFolder(&folder)))
return;
IShellFolder_CreateViewObject(folder, NULL, &IID_IShellView, (void**)&desktopshellbrowserwindow.view);
} }
static void shellwindows_init(void) static void shellwindows_init(void)
......
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