Commit 5e7cf798 authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

mshtml: Don't crash in UIActivate if hostui is NULL.

parent 8db98e9e
......@@ -605,11 +605,13 @@ static HRESULT WINAPI OleDocumentView_UIActivate(IOleDocumentView *iface, BOOL f
return hres;
}
hres = IDocHostUIHandler_ShowUI(This->hostui,
This->usermode == EDITMODE ? DOCHOSTUITYPE_AUTHOR : DOCHOSTUITYPE_BROWSE,
ACTOBJ(This), CMDTARGET(This), This->frame, This->ip_window);
if(FAILED(hres))
IDocHostUIHandler_HideUI(This->hostui);
if(This->hostui) {
hres = IDocHostUIHandler_ShowUI(This->hostui,
This->usermode == EDITMODE ? DOCHOSTUITYPE_AUTHOR : DOCHOSTUITYPE_BROWSE,
ACTOBJ(This), CMDTARGET(This), This->frame, This->ip_window);
if(FAILED(hres))
IDocHostUIHandler_HideUI(This->hostui);
}
if(This->ip_window)
call_set_active_object(This->ip_window, ACTOBJ(This));
......
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