Michael Stefaniuc : msxml3: Use an iface instead of a vtbl pointer in domcomment.
Alexandre Julliard
julliard at winehq.org
Fri Dec 17 11:30:43 CST 2010
Module: wine
Branch: master
Commit: 45f1825e7209e74e711c80d8216de30ab1fa5ba6
URL: http://source.winehq.org/git/wine.git/?a=commit;h=45f1825e7209e74e711c80d8216de30ab1fa5ba6
Author: Michael Stefaniuc <mstefani at redhat.de>
Date: Thu Dec 16 01:04:07 2010 +0100
msxml3: Use an iface instead of a vtbl pointer in domcomment.
---
dlls/msxml3/comment.c | 14 +++++++-------
1 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/dlls/msxml3/comment.c b/dlls/msxml3/comment.c
index 6ea3e71..8513ef0 100644
--- a/dlls/msxml3/comment.c
+++ b/dlls/msxml3/comment.c
@@ -40,13 +40,13 @@ WINE_DEFAULT_DEBUG_CHANNEL(msxml);
typedef struct _domcomment
{
xmlnode node;
- const struct IXMLDOMCommentVtbl *lpVtbl;
+ IXMLDOMComment IXMLDOMComment_iface;
LONG ref;
} domcomment;
static inline domcomment *impl_from_IXMLDOMComment( IXMLDOMComment *iface )
{
- return (domcomment *)((char*)iface - FIELD_OFFSET(domcomment, lpVtbl));
+ return CONTAINING_RECORD(iface, domcomment, IXMLDOMComment_iface);
}
static HRESULT WINAPI domcomment_QueryInterface(
@@ -171,8 +171,8 @@ static HRESULT WINAPI domcomment_Invoke(
hr = get_typeinfo(IXMLDOMComment_tid, &typeinfo);
if(SUCCEEDED(hr))
{
- hr = ITypeInfo_Invoke(typeinfo, &(This->lpVtbl), dispIdMember, wFlags, pDispParams,
- pVarResult, pExcepInfo, puArgErr);
+ hr = ITypeInfo_Invoke(typeinfo, &This->IXMLDOMComment_iface, dispIdMember, wFlags,
+ pDispParams, pVarResult, pExcepInfo, puArgErr);
ITypeInfo_Release(typeinfo);
}
@@ -837,12 +837,12 @@ IUnknown* create_comment( xmlNodePtr comment )
if ( !This )
return NULL;
- This->lpVtbl = &domcomment_vtbl;
+ This->IXMLDOMComment_iface.lpVtbl = &domcomment_vtbl;
This->ref = 1;
- init_xmlnode(&This->node, comment, (IXMLDOMNode*)&This->lpVtbl, NULL);
+ init_xmlnode(&This->node, comment, (IXMLDOMNode*)&This->IXMLDOMComment_iface, NULL);
- return (IUnknown*) &This->lpVtbl;
+ return (IUnknown*)&This->IXMLDOMComment_iface;
}
#endif
More information about the wine-cvs
mailing list