/*
 * Implementation of miscellaneous interfaces for IE Web Browser control:
 *
 *  - IQuickActivate
 *
 * 2001 John R. Sheets (for CodeWeavers)
 *
 * Copyright (c) 2003 TransGaming Technologies
 * david@transgaming.com
 */

#include "wine/debug.h"
#include "shdocvw.h"

WINE_DEFAULT_DEBUG_CHANNEL(shdocvw);

/**********************************************************************
 * Implement the IQuickActivate interface
 */

static HRESULT WINAPI WBQA_QueryInterface(LPQUICKACTIVATE iface,
                                          REFIID riid, LPVOID *ppobj)
{
    ICOM_THIS_MULTI(IWebBrowserImpl, lpVtbl_QA, iface);

    TRACE("(%p)->(%s, %p)\n", iface, debugstr_guid(riid), ppobj);
    return IWebBrowser_QueryInterface((LPWEBBROWSER) This, riid, ppobj);
}

static ULONG WINAPI WBQA_AddRef(LPQUICKACTIVATE iface)
{
    ICOM_THIS_MULTI(IWebBrowserImpl, lpVtbl_QA, iface);
    TRACE("(%p)->()\n", iface);
    return IWebBrowser_AddRef((LPWEBBROWSER) This);
}

static ULONG WINAPI WBQA_Release(LPQUICKACTIVATE iface)
{
    ICOM_THIS_MULTI(IWebBrowserImpl, lpVtbl_QA, iface);
    TRACE("(%p)->()\n", iface);
    return IWebBrowser_Release((LPWEBBROWSER) This);
}

/* Alternative interface for quicker, easier activation of a control. */
static HRESULT WINAPI WBQA_QuickActivate(LPQUICKACTIVATE iface,
                                         QACONTAINER *pQaContainer,
                                         QACONTROL *pQaControl)
{
    /*ICOM_THIS_MULTI(IWebBrowserImpl, lpVtbl_QA, iface);*/
    FIXME("(%p)->(...): stub\n", iface);
    return S_OK;
}

static HRESULT WINAPI WBQA_SetContentExtent(LPQUICKACTIVATE iface, LPSIZEL pSizel)
{
    /*ICOM_THIS_MULTI(IWebBrowserImpl, lpVtbl_QA, iface);*/
    FIXME("(%p)->(...): stub\n", iface);
    return S_OK;
}

static HRESULT WINAPI WBQA_GetContentExtent(LPQUICKACTIVATE iface, LPSIZEL pSizel)
{
    /*ICOM_THIS_MULTI(IWebBrowserImpl, lpVtbl_QA, iface);*/
    FIXME("(%p)->(...): stub\n", iface);
    return S_OK;
}

/**********************************************************************
 * IQuickActivate virtual function table for WebBrowser class
 */

ICOM_VTABLE(IQuickActivate) WBQA_Vtbl =
{
    ICOM_MSVTABLE_COMPAT_DummyRTTIVALUE
    WBQA_QueryInterface,
    WBQA_AddRef,
    WBQA_Release,
    WBQA_QuickActivate,
    WBQA_SetContentExtent,
    WBQA_GetContentExtent
};

