mirror of
https://github.com/reactos/wine.git
synced 2024-12-03 09:20:56 +00:00
dhtmled.ocx: Add dll and stub DHTMLEdit object.
Signed-off-by: Alex Henrie <alexhenrie24@gmail.com> Signed-off-by: Jacek Caban <jacek@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
72f3fa9e2d
commit
6c788af6d1
2
configure
vendored
2
configure
vendored
@ -1180,6 +1180,7 @@ enable_ddraw
|
||||
enable_ddrawex
|
||||
enable_devenum
|
||||
enable_dhcpcsvc
|
||||
enable_dhtmled_ocx
|
||||
enable_difxapi
|
||||
enable_dinput
|
||||
enable_dinput8
|
||||
@ -18528,6 +18529,7 @@ wine_fn_config_test dlls/ddrawex/tests ddrawex_test
|
||||
wine_fn_config_dll devenum enable_devenum clean
|
||||
wine_fn_config_test dlls/devenum/tests devenum_test
|
||||
wine_fn_config_dll dhcpcsvc enable_dhcpcsvc
|
||||
wine_fn_config_dll dhtmled.ocx enable_dhtmled_ocx clean
|
||||
wine_fn_config_dll difxapi enable_difxapi
|
||||
wine_fn_config_dll dinput enable_dinput clean,implib,staticimplib
|
||||
wine_fn_config_test dlls/dinput/tests dinput_test
|
||||
|
@ -3118,6 +3118,7 @@ WINE_CONFIG_TEST(dlls/ddrawex/tests)
|
||||
WINE_CONFIG_DLL(devenum,,[clean])
|
||||
WINE_CONFIG_TEST(dlls/devenum/tests)
|
||||
WINE_CONFIG_DLL(dhcpcsvc)
|
||||
WINE_CONFIG_DLL(dhtmled.ocx,,[clean])
|
||||
WINE_CONFIG_DLL(difxapi)
|
||||
WINE_CONFIG_DLL(dinput,,[clean,implib,staticimplib])
|
||||
WINE_CONFIG_TEST(dlls/dinput/tests)
|
||||
|
8
dlls/dhtmled.ocx/Makefile.in
Normal file
8
dlls/dhtmled.ocx/Makefile.in
Normal file
@ -0,0 +1,8 @@
|
||||
MODULE = dhtmled.ocx
|
||||
IMPORTS = uuid
|
||||
|
||||
C_SRCS = \
|
||||
edit.c \
|
||||
main.c
|
||||
|
||||
IDL_SRCS = dhtmled_tlb.idl
|
4
dlls/dhtmled.ocx/dhtmled.ocx.spec
Normal file
4
dlls/dhtmled.ocx/dhtmled.ocx.spec
Normal file
@ -0,0 +1,4 @@
|
||||
@ stdcall -private DllCanUnloadNow()
|
||||
@ stdcall -private DllGetClassObject(ptr ptr ptr)
|
||||
@ stdcall -private DllRegisterServer()
|
||||
@ stdcall -private DllUnregisterServer()
|
19
dlls/dhtmled.ocx/dhtmled_private.h
Normal file
19
dlls/dhtmled.ocx/dhtmled_private.h
Normal file
@ -0,0 +1,19 @@
|
||||
/*
|
||||
* Copyright 2017 Alex Henrie
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
* version 2.1 of the License, or (at your option) any later version.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Lesser General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public
|
||||
* License along with this library; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
extern HRESULT dhtml_edit_create(REFIID iid, void **out);
|
22
dlls/dhtmled.ocx/dhtmled_tlb.idl
Normal file
22
dlls/dhtmled.ocx/dhtmled_tlb.idl
Normal file
@ -0,0 +1,22 @@
|
||||
/*
|
||||
* Copyright 2017 Alex Henrie
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
* version 2.1 of the License, or (at your option) any later version.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Lesser General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public
|
||||
* License along with this library; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
#pragma makedep register
|
||||
#pragma makedep regtypelib
|
||||
|
||||
#include "dhtmled.idl"
|
534
dlls/dhtmled.ocx/edit.c
Normal file
534
dlls/dhtmled.ocx/edit.c
Normal file
@ -0,0 +1,534 @@
|
||||
/*
|
||||
* Copyright 2017 Alex Henrie
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
* version 2.1 of the License, or (at your option) any later version.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Lesser General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public
|
||||
* License along with this library; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
#define COBJMACROS
|
||||
|
||||
#include "dhtmled.h"
|
||||
|
||||
#include "wine/debug.h"
|
||||
|
||||
WINE_DEFAULT_DEBUG_CHANNEL(dhtmled);
|
||||
|
||||
typedef struct
|
||||
{
|
||||
IDHTMLEdit IDHTMLEdit_iface;
|
||||
LONG ref;
|
||||
} DHTMLEditImpl;
|
||||
|
||||
static inline DHTMLEditImpl *impl_from_IDHTMLEdit(IDHTMLEdit *iface)
|
||||
{
|
||||
return CONTAINING_RECORD(iface, DHTMLEditImpl, IDHTMLEdit_iface);
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_QueryInterface(IDHTMLEdit *iface, REFIID iid, void **out)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
|
||||
TRACE("(%p)->(%s, %p)\n", This, debugstr_guid(iid), out);
|
||||
|
||||
if (IsEqualGUID(iid, &IID_IUnknown) ||
|
||||
IsEqualGUID(iid, &IID_IDispatch) ||
|
||||
IsEqualGUID(iid, &IID_IDHTMLSafe) ||
|
||||
IsEqualGUID(iid, &IID_IDHTMLEdit))
|
||||
{
|
||||
IUnknown_AddRef(iface);
|
||||
*out = iface;
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
*out = NULL;
|
||||
ERR("no interface for %s\n", debugstr_guid(iid));
|
||||
return E_NOINTERFACE;
|
||||
}
|
||||
|
||||
static ULONG WINAPI DHTMLEdit_AddRef(IDHTMLEdit *iface)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
LONG ref = InterlockedIncrement(&This->ref);
|
||||
|
||||
TRACE("(%p) ref=%d\n", This, ref);
|
||||
|
||||
return ref;
|
||||
}
|
||||
|
||||
static ULONG WINAPI DHTMLEdit_Release(IDHTMLEdit *iface)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
LONG ref = InterlockedDecrement(&This->ref);
|
||||
|
||||
TRACE("(%p) ref=%d\n", This, ref);
|
||||
|
||||
if (!ref)
|
||||
HeapFree(GetProcessHeap(), 0, This);
|
||||
|
||||
return ref;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_GetTypeInfoCount(IDHTMLEdit *iface, UINT *count)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, count);
|
||||
*count = 0;
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_GetTypeInfo(IDHTMLEdit *iface, UINT type_index, LCID lcid, ITypeInfo **type_info)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%u, %08x, %p) stub\n", This, type_index, lcid, type_info);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_GetIDsOfNames(IDHTMLEdit *iface, REFIID iid, OLECHAR **names, UINT name_count,
|
||||
LCID lcid, DISPID *disp_ids)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%s, %p, %u, %08x, %p) stub\n", This, debugstr_guid(iid), names, name_count, lcid, disp_ids);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_Invoke(IDHTMLEdit *iface, DISPID member, REFIID iid, LCID lcid, WORD flags,
|
||||
DISPPARAMS *params, VARIANT *ret, EXCEPINFO *exception_info, UINT *error_index)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%d, %s, %08x, 0x%x, %p, %p, %p, %p) stub\n",
|
||||
This, member, debugstr_guid(iid), lcid, flags, params, ret, exception_info, error_index);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_ExecCommand(IDHTMLEdit *iface, DHTMLEDITCMDID cmd_id, OLECMDEXECOPT options,
|
||||
VARIANT *code_in, VARIANT *code_out)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%u, %u, %s, %p) stub\n", This, cmd_id, options, debugstr_variant(code_in), code_out);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_QueryStatus(IDHTMLEdit *iface, DHTMLEDITCMDID cmd_id, DHTMLEDITCMDF *status)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%u, %p) stub\n", This, cmd_id, status);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_SetContextMenu(IDHTMLEdit *iface, VARIANT *strings, VARIANT *states)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p, %p) stub\n", This, strings, states);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_NewDocument(IDHTMLEdit *iface)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->() stub\n", This);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_LoadURL(IDHTMLEdit *iface, BSTR url)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%s)\n", This, debugstr_w(url));
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_FilterSourceCode(IDHTMLEdit *iface, BSTR in, BSTR *out)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%s, %p)\n", This, debugstr_w(in), out);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_Refresh(IDHTMLEdit *iface)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->() stub\n", This);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_DOM(IDHTMLEdit *iface, IHTMLDocument2 **value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_DocumentHTML(IDHTMLEdit *iface, BSTR *value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_put_DocumentHTML(IDHTMLEdit *iface, BSTR html)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%s) stub\n", This, debugstr_w(html));
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_ActivateApplets(IDHTMLEdit *iface, VARIANT_BOOL *value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_put_ActivateApplets(IDHTMLEdit *iface, VARIANT_BOOL value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%04x) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_ActivateActiveXControls(IDHTMLEdit *iface, VARIANT_BOOL *value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_put_ActivateActiveXControls(IDHTMLEdit *iface, VARIANT_BOOL value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%04x) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_ActivateDTCs(IDHTMLEdit *iface, VARIANT_BOOL *value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_put_ActivateDTCs(IDHTMLEdit *iface, VARIANT_BOOL value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%04x) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_ShowDetails(IDHTMLEdit *iface, VARIANT_BOOL *value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_put_ShowDetails(IDHTMLEdit *iface, VARIANT_BOOL value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%04x) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_ShowBorders(IDHTMLEdit *iface, VARIANT_BOOL *value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_put_ShowBorders(IDHTMLEdit *iface, VARIANT_BOOL value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%04x) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_Appearance(IDHTMLEdit *iface, DHTMLEDITAPPEARANCE *value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_put_Appearance(IDHTMLEdit *iface, DHTMLEDITAPPEARANCE value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%u) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_Scrollbars(IDHTMLEdit *iface, VARIANT_BOOL *value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_put_Scrollbars(IDHTMLEdit *iface, VARIANT_BOOL value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%04x) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_ScrollbarAppearance(IDHTMLEdit *iface, DHTMLEDITAPPEARANCE *value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_put_ScrollbarAppearance(IDHTMLEdit *iface, DHTMLEDITAPPEARANCE value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%u) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_SourceCodePreservation(IDHTMLEdit *iface, VARIANT_BOOL *value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_put_SourceCodePreservation(IDHTMLEdit *iface, VARIANT_BOOL value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%04x) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_AbsoluteDropMode(IDHTMLEdit *iface, VARIANT_BOOL *value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_put_AbsoluteDropMode(IDHTMLEdit *iface, VARIANT_BOOL value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%04x) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_SnapToGridX(IDHTMLEdit *iface, LONG *value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_put_SnapToGridX(IDHTMLEdit *iface, LONG value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%d) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_SnapToGridY(IDHTMLEdit *iface, LONG *value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_put_SnapToGridY(IDHTMLEdit *iface, LONG value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%d) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_SnapToGrid(IDHTMLEdit *iface, VARIANT_BOOL *value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_put_SnapToGrid(IDHTMLEdit *iface, VARIANT_BOOL value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%04x) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_IsDirty(IDHTMLEdit *iface, VARIANT_BOOL *value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_CurrentDocumentPath(IDHTMLEdit *iface, BSTR *value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_BaseURL(IDHTMLEdit *iface, BSTR *value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_put_BaseURL(IDHTMLEdit *iface, BSTR value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%s) stub\n", This, debugstr_w(value));
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_DocumentTitle(IDHTMLEdit *iface, BSTR *value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_UseDivOnCarriageReturn(IDHTMLEdit *iface, VARIANT_BOOL *value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_put_UseDivOnCarriageReturn(IDHTMLEdit *iface, VARIANT_BOOL value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%04x) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_Busy(IDHTMLEdit *iface, VARIANT_BOOL *value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_LoadDocument(IDHTMLEdit *iface, VARIANT *path, VARIANT *prompt)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%s, %s) stub\n", This, debugstr_variant(path), debugstr_variant(prompt));
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_SaveDocument(IDHTMLEdit *iface, VARIANT *path, VARIANT *prompt)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%s, %s) stub\n", This, debugstr_variant(path), debugstr_variant(prompt));
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_PrintDocument(IDHTMLEdit *iface, VARIANT *prompt)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%s) stub\n", This, debugstr_variant(prompt));
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_get_BrowseMode(IDHTMLEdit *iface, VARIANT_BOOL *value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%p) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI DHTMLEdit_put_BrowseMode(IDHTMLEdit *iface, VARIANT_BOOL value)
|
||||
{
|
||||
DHTMLEditImpl *This = impl_from_IDHTMLEdit(iface);
|
||||
FIXME("(%p)->(%04x) stub\n", This, value);
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
static const IDHTMLEditVtbl DHTMLEditVtbl = {
|
||||
DHTMLEdit_QueryInterface,
|
||||
DHTMLEdit_AddRef,
|
||||
DHTMLEdit_Release,
|
||||
DHTMLEdit_GetTypeInfoCount,
|
||||
DHTMLEdit_GetTypeInfo,
|
||||
DHTMLEdit_GetIDsOfNames,
|
||||
DHTMLEdit_Invoke,
|
||||
DHTMLEdit_ExecCommand,
|
||||
DHTMLEdit_QueryStatus,
|
||||
DHTMLEdit_SetContextMenu,
|
||||
DHTMLEdit_NewDocument,
|
||||
DHTMLEdit_LoadURL,
|
||||
DHTMLEdit_FilterSourceCode,
|
||||
DHTMLEdit_Refresh,
|
||||
DHTMLEdit_get_DOM,
|
||||
DHTMLEdit_get_DocumentHTML,
|
||||
DHTMLEdit_put_DocumentHTML,
|
||||
DHTMLEdit_get_ActivateApplets,
|
||||
DHTMLEdit_put_ActivateApplets,
|
||||
DHTMLEdit_get_ActivateActiveXControls,
|
||||
DHTMLEdit_put_ActivateActiveXControls,
|
||||
DHTMLEdit_get_ActivateDTCs,
|
||||
DHTMLEdit_put_ActivateDTCs,
|
||||
DHTMLEdit_get_ShowDetails,
|
||||
DHTMLEdit_put_ShowDetails,
|
||||
DHTMLEdit_get_ShowBorders,
|
||||
DHTMLEdit_put_ShowBorders,
|
||||
DHTMLEdit_get_Appearance,
|
||||
DHTMLEdit_put_Appearance,
|
||||
DHTMLEdit_get_Scrollbars,
|
||||
DHTMLEdit_put_Scrollbars,
|
||||
DHTMLEdit_get_ScrollbarAppearance,
|
||||
DHTMLEdit_put_ScrollbarAppearance,
|
||||
DHTMLEdit_get_SourceCodePreservation,
|
||||
DHTMLEdit_put_SourceCodePreservation,
|
||||
DHTMLEdit_get_AbsoluteDropMode,
|
||||
DHTMLEdit_put_AbsoluteDropMode,
|
||||
DHTMLEdit_get_SnapToGridX,
|
||||
DHTMLEdit_put_SnapToGridX,
|
||||
DHTMLEdit_get_SnapToGridY,
|
||||
DHTMLEdit_put_SnapToGridY,
|
||||
DHTMLEdit_get_SnapToGrid,
|
||||
DHTMLEdit_put_SnapToGrid,
|
||||
DHTMLEdit_get_IsDirty,
|
||||
DHTMLEdit_get_CurrentDocumentPath,
|
||||
DHTMLEdit_get_BaseURL,
|
||||
DHTMLEdit_put_BaseURL,
|
||||
DHTMLEdit_get_DocumentTitle,
|
||||
DHTMLEdit_get_UseDivOnCarriageReturn,
|
||||
DHTMLEdit_put_UseDivOnCarriageReturn,
|
||||
DHTMLEdit_get_Busy,
|
||||
DHTMLEdit_LoadDocument,
|
||||
DHTMLEdit_SaveDocument,
|
||||
DHTMLEdit_PrintDocument,
|
||||
DHTMLEdit_get_BrowseMode,
|
||||
DHTMLEdit_put_BrowseMode
|
||||
};
|
||||
|
||||
HRESULT dhtml_edit_create(REFIID iid, void **out)
|
||||
{
|
||||
DHTMLEditImpl *This;
|
||||
HRESULT ret;
|
||||
|
||||
TRACE("(%s, %p)\n", debugstr_guid(iid), out);
|
||||
|
||||
This = HeapAlloc(GetProcessHeap(), 0, sizeof(*This));
|
||||
if (!This)
|
||||
return E_OUTOFMEMORY;
|
||||
|
||||
This->IDHTMLEdit_iface.lpVtbl = &DHTMLEditVtbl;
|
||||
This->ref = 1;
|
||||
|
||||
ret = IDHTMLEdit_QueryInterface(&This->IDHTMLEdit_iface, iid, out);
|
||||
IDHTMLEdit_Release(&This->IDHTMLEdit_iface);
|
||||
return ret;
|
||||
}
|
156
dlls/dhtmled.ocx/main.c
Normal file
156
dlls/dhtmled.ocx/main.c
Normal file
@ -0,0 +1,156 @@
|
||||
/*
|
||||
* Dynamic HyperText Markup Language Editing Control
|
||||
*
|
||||
* Copyright 2017 Alex Henrie
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
* version 2.1 of the License, or (at your option) any later version.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Lesser General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public
|
||||
* License along with this library; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
#define COBJMACROS
|
||||
|
||||
#include "initguid.h"
|
||||
#include "dhtmled.h"
|
||||
#include "dhtmled_private.h"
|
||||
#include "rpcproxy.h"
|
||||
|
||||
#include "wine/debug.h"
|
||||
|
||||
WINE_DEFAULT_DEBUG_CHANNEL(dhtmled);
|
||||
|
||||
typedef struct
|
||||
{
|
||||
IClassFactory IClassFactory_iface;
|
||||
HRESULT (*create)(REFIID iid, void **out);
|
||||
} ClassFactoryImpl;
|
||||
|
||||
static inline ClassFactoryImpl *impl_from_IClassFactory(IClassFactory *iface)
|
||||
{
|
||||
return CONTAINING_RECORD(iface, ClassFactoryImpl, IClassFactory_iface);
|
||||
}
|
||||
|
||||
static HRESULT WINAPI ClassFactory_QueryInterface(IClassFactory *iface, REFIID iid, void **out)
|
||||
{
|
||||
TRACE("(%p)->(%s, %p)\n", iface, debugstr_guid(iid), out);
|
||||
|
||||
if (IsEqualGUID(&IID_IUnknown, iid) || IsEqualGUID(&IID_IClassFactory, iid))
|
||||
{
|
||||
*out = iface;
|
||||
IClassFactory_AddRef(iface);
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
*out = NULL;
|
||||
WARN("no interface for %s\n", debugstr_guid(iid));
|
||||
return E_NOINTERFACE;
|
||||
}
|
||||
|
||||
static ULONG WINAPI ClassFactory_AddRef(IClassFactory *iface)
|
||||
{
|
||||
return 2; /* non-heap based object */
|
||||
}
|
||||
|
||||
static ULONG WINAPI ClassFactory_Release(IClassFactory *iface)
|
||||
{
|
||||
return 1; /* non-heap based object */
|
||||
}
|
||||
|
||||
static HRESULT WINAPI ClassFactory_CreateInstance(IClassFactory *iface, IUnknown *outer, REFIID iid, void **out)
|
||||
{
|
||||
ClassFactoryImpl *This = impl_from_IClassFactory(iface);
|
||||
|
||||
TRACE("(%p)->(%p, %s, %p)\n", iface, outer, debugstr_guid(iid), out);
|
||||
|
||||
if (outer)
|
||||
return CLASS_E_NOAGGREGATION;
|
||||
|
||||
return This->create(iid, out);
|
||||
}
|
||||
|
||||
static HRESULT WINAPI ClassFactory_LockServer(IClassFactory *iface, BOOL lock)
|
||||
{
|
||||
TRACE("(%p)->(%x)\n", iface, lock);
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
static const IClassFactoryVtbl ClassFactoryVtbl = {
|
||||
ClassFactory_QueryInterface,
|
||||
ClassFactory_AddRef,
|
||||
ClassFactory_Release,
|
||||
ClassFactory_CreateInstance,
|
||||
ClassFactory_LockServer
|
||||
};
|
||||
|
||||
static HINSTANCE dhtmled_instance;
|
||||
|
||||
/******************************************************************
|
||||
* DllMain (dhtmled.ocx.@)
|
||||
*/
|
||||
BOOL WINAPI DllMain(HINSTANCE instance, DWORD reason, VOID *reserved)
|
||||
{
|
||||
TRACE("(%p, %u, %p)\n", instance, reason, reserved);
|
||||
|
||||
switch (reason)
|
||||
{
|
||||
case DLL_PROCESS_ATTACH:
|
||||
DisableThreadLibraryCalls(instance);
|
||||
dhtmled_instance = instance;
|
||||
break;
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* DllGetClassObject (dhtmled.ocx.@)
|
||||
*/
|
||||
HRESULT WINAPI DllGetClassObject(REFCLSID clsid, REFIID iid, LPVOID *out)
|
||||
{
|
||||
static ClassFactoryImpl dhtml_edit_cf = { {&ClassFactoryVtbl}, dhtml_edit_create };
|
||||
|
||||
TRACE("(%s, %s, %p)\n", debugstr_guid(clsid), debugstr_guid(iid), out);
|
||||
|
||||
if (IsEqualGUID(clsid, &CLSID_DHTMLEdit))
|
||||
return IClassFactory_QueryInterface(&dhtml_edit_cf.IClassFactory_iface, iid, out);
|
||||
|
||||
FIXME("no class for %s\n", debugstr_guid(clsid));
|
||||
return CLASS_E_CLASSNOTAVAILABLE;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* DllCanUnloadNow (dhtmled.ocx.@)
|
||||
*/
|
||||
HRESULT WINAPI DllCanUnloadNow(void)
|
||||
{
|
||||
TRACE("()\n");
|
||||
return S_FALSE;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* DllRegisterServer (dhtmled.ocx.@)
|
||||
*/
|
||||
HRESULT WINAPI DllRegisterServer(void)
|
||||
{
|
||||
TRACE("()\n");
|
||||
return __wine_register_resources(dhtmled_instance);
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* DllUnregisterServer (dhtmled.ocx.@)
|
||||
*/
|
||||
HRESULT WINAPI DllUnregisterServer(void)
|
||||
{
|
||||
TRACE("()\n");
|
||||
return __wine_unregister_resources(dhtmled_instance);
|
||||
}
|
Loading…
Reference in New Issue
Block a user