setupapi: Add stubs for SetupOpenLog, SetupCloseLog, and SetupLogError.
[wine/wine64.git] / dlls / mshtml / htmltextcont.c
blob2634ac8e4a6ab840d09df388ca476d8a26b344ff
1 /*
2 * Copyright 2006 Jacek Caban for CodeWeavers
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
19 #include "config.h"
21 #include <stdarg.h>
22 #include <stdio.h>
24 #define COBJMACROS
26 #include "windef.h"
27 #include "winbase.h"
28 #include "winuser.h"
29 #include "ole2.h"
31 #include "wine/debug.h"
33 #include "mshtml_private.h"
35 WINE_DEFAULT_DEBUG_CHANNEL(mshtml);
37 #define HTMLTEXTCONT_THIS(iface) DEFINE_THIS(HTMLTextContainer, HTMLTextContainer, iface)
39 static HRESULT WINAPI HTMLTextContainer_QueryInterface(IHTMLTextContainer *iface,
40 REFIID riid, void **ppv)
42 HTMLTextContainer *This = HTMLTEXTCONT_THIS(iface);
43 return IHTMLElement_QueryInterface(HTMLELEM(This->element), riid, ppv);
46 static ULONG WINAPI HTMLTextContainer_AddRef(IHTMLTextContainer *iface)
48 HTMLTextContainer *This = HTMLTEXTCONT_THIS(iface);
49 return IHTMLElement_AddRef(HTMLELEM(This->element));
52 static ULONG WINAPI HTMLTextContainer_Release(IHTMLTextContainer *iface)
54 HTMLTextContainer *This = HTMLTEXTCONT_THIS(iface);
55 return IHTMLElement_Release(HTMLELEM(This->element));
58 static HRESULT WINAPI HTMLTextContainer_GetTypeInfoCount(IHTMLTextContainer *iface, UINT *pctinfo)
60 HTMLTextContainer *This = HTMLTEXTCONT_THIS(iface);
61 FIXME("(%p)->(%p)\n", This, pctinfo);
62 return E_NOTIMPL;
65 static HRESULT WINAPI HTMLTextContainer_GetTypeInfo(IHTMLTextContainer *iface, UINT iTInfo,
66 LCID lcid, ITypeInfo **ppTInfo)
68 HTMLTextContainer *This = HTMLTEXTCONT_THIS(iface);
69 FIXME("(%p)->(%u %lu %p)\n", This, iTInfo, lcid, ppTInfo);
70 return E_NOTIMPL;
73 static HRESULT WINAPI HTMLTextContainer_GetIDsOfNames(IHTMLTextContainer *iface, REFIID riid,
74 LPOLESTR *rgszNames, UINT cNames,
75 LCID lcid, DISPID *rgDispId)
77 HTMLTextContainer *This = HTMLTEXTCONT_THIS(iface);
78 FIXME("(%p)->(%s %p %u %lu %p)\n", This, debugstr_guid(riid), rgszNames, cNames,
79 lcid, rgDispId);
80 return E_NOTIMPL;
83 static HRESULT WINAPI HTMLTextContainer_Invoke(IHTMLTextContainer *iface, DISPID dispIdMember,
84 REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams,
85 VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
87 HTMLTextContainer *This = HTMLTEXTCONT_THIS(iface);
88 FIXME("(%p)->(%ld %s %ld %d %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid),
89 lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
90 return E_NOTIMPL;
93 static HRESULT WINAPI HTMLTextContainer_createControlRange(IHTMLTextContainer *iface,
94 IDispatch **range)
96 HTMLTextContainer *This = HTMLTEXTCONT_THIS(iface);
97 FIXME("(%p)->(%p)\n", This, range);
98 return E_NOTIMPL;
101 static HRESULT WINAPI HTMLTextContainer_get_scrollHeight(IHTMLTextContainer *iface, long *p)
103 HTMLTextContainer *This = HTMLTEXTCONT_THIS(iface);
104 FIXME("(%p)->(%p)\n", This, p);
105 return E_NOTIMPL;
108 static HRESULT WINAPI HTMLTextContainer_get_scrollWidth(IHTMLTextContainer *iface, long *p)
110 HTMLTextContainer *This = HTMLTEXTCONT_THIS(iface);
111 FIXME("(%p)->(%p)\n", This, p);
112 return E_NOTIMPL;
115 static HRESULT WINAPI HTMLTextContainer_put_scrollTop(IHTMLTextContainer *iface, long v)
117 HTMLTextContainer *This = HTMLTEXTCONT_THIS(iface);
118 nsIDOMNSHTMLElement *nselem;
119 nsresult nsres;
121 TRACE("(%p)->(%ld)\n", This, v);
123 nsres = nsIDOMHTMLElement_QueryInterface(This->element->nselem, &IID_nsIDOMNSHTMLElement,
124 (void**)&nselem);
125 if(NS_SUCCEEDED(nsres)) {
126 nsIDOMNSHTMLElement_SetScrollTop(nselem, v);
127 nsIDOMNSHTMLElement_Release(nselem);
128 }else {
129 ERR("Could not get nsIDOMNSHTMLElement interface: %08lx\n", nsres);
132 return S_OK;
135 static HRESULT WINAPI HTMLTextContainer_get_scrollTop(IHTMLTextContainer *iface, long *p)
137 HTMLTextContainer *This = HTMLTEXTCONT_THIS(iface);
138 FIXME("(%p)->(%p)\n", This, p);
139 return E_NOTIMPL;
142 static HRESULT WINAPI HTMLTextContainer_put_scrollLeft(IHTMLTextContainer *iface, long v)
144 HTMLTextContainer *This = HTMLTEXTCONT_THIS(iface);
145 nsIDOMNSHTMLElement *nselem;
146 nsresult nsres;
148 TRACE("(%p)->(%ld)\n", This, v);
150 nsres = nsIDOMHTMLElement_QueryInterface(This->element->nselem, &IID_nsIDOMNSHTMLElement,
151 (void**)&nselem);
152 if(NS_SUCCEEDED(nsres)) {
153 nsIDOMNSHTMLElement_SetScrollLeft(nselem, v);
154 nsIDOMNSHTMLElement_Release(nselem);
155 }else {
156 ERR("Could not get nsIDOMNSHTMLElement interface: %08lx\n", nsres);
159 return S_OK;
162 static HRESULT WINAPI HTMLTextContainer_get_scrollLeft(IHTMLTextContainer *iface, long *p)
164 HTMLTextContainer *This = HTMLTEXTCONT_THIS(iface);
165 FIXME("(%p)->(%p)\n", This, p);
166 return E_NOTIMPL;
169 static HRESULT WINAPI HTMLTextContainer_put_onscroll(IHTMLTextContainer *iface, VARIANT v)
171 HTMLTextContainer *This = HTMLTEXTCONT_THIS(iface);
172 FIXME("(%p)->()\n", This);
173 return E_NOTIMPL;
176 static HRESULT WINAPI HTMLTextContainer_get_onscroll(IHTMLTextContainer *iface, VARIANT *p)
178 HTMLTextContainer *This = HTMLTEXTCONT_THIS(iface);
179 FIXME("(%p)->(%p)\n", This, p);
180 return E_NOTIMPL;
183 #undef HTMLTEXTCONT_THIS
185 static const IHTMLTextContainerVtbl HTMLTextContainerVtbl = {
186 HTMLTextContainer_QueryInterface,
187 HTMLTextContainer_AddRef,
188 HTMLTextContainer_Release,
189 HTMLTextContainer_GetTypeInfoCount,
190 HTMLTextContainer_GetTypeInfo,
191 HTMLTextContainer_GetIDsOfNames,
192 HTMLTextContainer_Invoke,
193 HTMLTextContainer_createControlRange,
194 HTMLTextContainer_get_scrollHeight,
195 HTMLTextContainer_get_scrollWidth,
196 HTMLTextContainer_put_scrollTop,
197 HTMLTextContainer_get_scrollTop,
198 HTMLTextContainer_put_scrollLeft,
199 HTMLTextContainer_get_scrollLeft,
200 HTMLTextContainer_put_onscroll,
201 HTMLTextContainer_get_onscroll
204 void HTMLTextContainer_Init(HTMLTextContainer *This, HTMLElement *elem)
206 This->lpHTMLTextContainerVtbl = &HTMLTextContainerVtbl;
207 This->element = elem;