shdocvw: Add support for setting the statusbar text in IE.
diff --git a/dlls/shdocvw/ie.c b/dlls/shdocvw/ie.c
index a484de5..43afd31 100644
--- a/dlls/shdocvw/ie.c
+++ b/dlls/shdocvw/ie.c
@@ -396,8 +396,10 @@
static HRESULT WINAPI InternetExplorer_put_StatusText(IWebBrowser2 *iface, BSTR StatusText)
{
InternetExplorer *This = WEBBROWSER_THIS(iface);
- FIXME("(%p)->(%s)\n", This, debugstr_w(StatusText));
- return E_NOTIMPL;
+
+ TRACE("(%p)->(%s)\n", This, debugstr_w(StatusText));
+
+ return update_ie_statustext(This, StatusText);
}
static HRESULT WINAPI InternetExplorer_get_ToolBar(IWebBrowser2 *iface, int *Value)
diff --git a/dlls/shdocvw/iexplore.c b/dlls/shdocvw/iexplore.c
index 52cde1b..2f15987 100644
--- a/dlls/shdocvw/iexplore.c
+++ b/dlls/shdocvw/iexplore.c
@@ -41,12 +41,22 @@
#define IDI_APPICON 1
+#define DOCHOST_THIS(iface) DEFINE_THIS2(InternetExplorer,doc_host,iface)
+
static const WCHAR szIEWinFrame[] = { 'I','E','F','r','a','m','e',0 };
/* Windows uses "Microsoft Internet Explorer" */
static const WCHAR wszWineInternetExplorer[] =
{'W','i','n','e',' ','I','n','t','e','r','n','e','t',' ','E','x','p','l','o','r','e','r',0};
+HRESULT update_ie_statustext(InternetExplorer* This, LPCWSTR text)
+{
+ if(!SendMessageW(This->status_hwnd, SB_SETTEXTW, MAKEWORD(SB_SIMPLEID, 0), (LPARAM)text))
+ return E_FAIL;
+
+ return S_OK;
+}
+
void adjust_ie_docobj_rect(HWND frame, RECT* rc)
{
HWND hwndRebar = GetDlgItem(frame, IDC_BROWSE_REBAR);
@@ -378,9 +388,8 @@
static HRESULT WINAPI DocHostContainer_SetStatusText(DocHost* This, LPCWSTR text)
{
- FIXME("(%p)->(%s)\n", This, debugstr_w(text));
-
- return E_NOTIMPL;
+ InternetExplorer* ie = DOCHOST_THIS(This);
+ return update_ie_statustext(ie, text);
}
static void WINAPI DocHostContainer_SetURL(DocHost* This, LPCWSTR url)
diff --git a/dlls/shdocvw/shdocvw.h b/dlls/shdocvw/shdocvw.h
index 151b48b..d20e834 100644
--- a/dlls/shdocvw/shdocvw.h
+++ b/dlls/shdocvw/shdocvw.h
@@ -270,7 +270,8 @@
HRESULT TaskbarList_Create(IUnknown*,REFIID,void**);
-#define DEFINE_THIS(cls,ifc,iface) ((cls*)((BYTE*)(iface)-offsetof(cls,lp ## ifc ## Vtbl)))
+#define DEFINE_THIS2(cls,ifc,iface) ((cls*)((BYTE*)(iface)-offsetof(cls,ifc)))
+#define DEFINE_THIS(cls,ifc,iface) DEFINE_THIS2(cls,lp ## ifc ## Vtbl,iface)
/**********************************************************************
* Dll lifetime tracking declaration for shdocvw.dll
@@ -283,6 +284,7 @@
extern void register_iewindow_class(void);
extern void unregister_iewindow_class(void);
extern void adjust_ie_docobj_rect(HWND, RECT*);
+extern HRESULT update_ie_statustext(InternetExplorer*, LPCWSTR);
HRESULT register_class_object(BOOL);
HRESULT get_typeinfo(ITypeInfo**);