shell32: Use FIELD_OFFSET instead of hand coding its functionality.
This commit is contained in:
parent
311bef2a5c
commit
3591663cca
|
@ -66,8 +66,8 @@ static const IShellFolder2Vtbl vt_ShellFolder2;
|
|||
static const IPersistFolder2Vtbl vt_NP_PersistFolder2;
|
||||
|
||||
|
||||
#define _IPersistFolder2_Offset ((int)(&(((IGenericSFImpl*)0)->lpVtblPersistFolder2)))
|
||||
#define _ICOM_THIS_From_IPersistFolder2(class, name) class* This = (class*)(((char*)name)-_IPersistFolder2_Offset);
|
||||
#define _ICOM_THIS_From_IPersistFolder2(class, name) class* This = \
|
||||
(class*)(((char*)name) - FIELD_OFFSET(IGenericSFImpl, lpVtblPersistFolder2))
|
||||
|
||||
#define _IUnknown_(This) (IUnknown*)&(This->lpVtbl)
|
||||
#define _IShellFolder_(This) (IShellFolder*)&(This->lpVtbl)
|
||||
|
|
Loading…
Reference in New Issue