mshtml: Added IHTMLDocument4::hasFocus implementation.

Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Jacek Caban 2016-01-06 15:05:42 +01:00 committed by Alexandre Julliard
parent 62c367d12d
commit 67014b7cf9
1 changed files with 15 additions and 2 deletions

View File

@ -2549,8 +2549,21 @@ static HRESULT WINAPI HTMLDocument4_focus(IHTMLDocument4 *iface)
static HRESULT WINAPI HTMLDocument4_hasFocus(IHTMLDocument4 *iface, VARIANT_BOOL *pfFocus)
{
HTMLDocument *This = impl_from_IHTMLDocument4(iface);
FIXME("(%p)->(%p)\n", This, pfFocus);
return E_NOTIMPL;
cpp_bool has_focus;
nsresult nsres;
TRACE("(%p)->(%p)\n", This, pfFocus);
if(!This->doc_node->nsdoc) {
FIXME("Unimplemented for fragments.\n");
return E_NOTIMPL;
}
nsres = nsIDOMHTMLDocument_HasFocus(This->doc_node->nsdoc, &has_focus);
assert(nsres == NS_OK);
*pfFocus = has_focus ? VARIANT_TRUE : VARIANT_FALSE;
return S_OK;
}
static HRESULT WINAPI HTMLDocument4_put_onselectionchange(IHTMLDocument4 *iface, VARIANT v)