Avoid excessive heap memory reallocation when generating EMF
[wine] / dlls / ole32 / ifs.h
1 /*
2  * Copyright 1997 Marcus Meissner
3  *
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.
8  *
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.
13  *
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., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
17  */
18
19 #ifndef __WINE_OLE_IFS_H
20 #define __WINE_OLE_IFS_H
21
22 #include <stdarg.h>
23
24 #include "windef.h"
25 #include "winbase.h"
26 #include "objbase.h"
27
28 /***********************************************************************
29  * IMalloc16 interface
30  */
31
32 typedef struct IMalloc16 IMalloc16, *LPMALLOC16;
33
34 #define INTERFACE IMalloc16
35 #define IMalloc16_METHODS \
36     IUnknown_METHODS \
37     STDMETHOD_(LPVOID,Alloc)(THIS_ DWORD   cb) PURE; \
38     STDMETHOD_(LPVOID,Realloc)(THIS_ LPVOID  pv, DWORD  cb) PURE; \
39     STDMETHOD_(void,Free)(THIS_ LPVOID  pv) PURE; \
40     STDMETHOD_(DWORD,GetSize)(THIS_ LPVOID  pv) PURE; \
41     STDMETHOD_(INT16,DidAlloc)(THIS_ LPVOID  pv) PURE; \
42     STDMETHOD_(LPVOID,HeapMinimize)(THIS) PURE;
43 ICOM_DEFINE(IMalloc16,IUnknown)
44 #undef INTERFACE
45
46 /**********************************************************************/
47
48 extern LPMALLOC16 IMalloc16_Constructor();
49
50 /**********************************************************************/
51
52 typedef struct ILockBytes16 *LPLOCKBYTES16, ILockBytes16;
53
54 #define INTERFACE ILockBytes
55 #define ILockBytes16_METHODS \
56         IUnknown_METHODS \
57         STDMETHOD(ReadAt)(THIS_ ULARGE_INTEGER ulOffset, void *pv, ULONG  cb, ULONG *pcbRead) PURE; \
58         STDMETHOD(WriteAt)(THIS_ ULARGE_INTEGER ulOffset, const void *pv, ULONG cb, ULONG *pcbWritten) PURE; \
59         STDMETHOD(Flush)(THIS) PURE; \
60         STDMETHOD(SetSize)(THIS_ ULARGE_INTEGER cb) PURE; \
61         STDMETHOD(LockRegion)(THIS_ ULARGE_INTEGER libOffset, ULARGE_INTEGER  cb, DWORD dwLockType) PURE; \
62         STDMETHOD(UnlockRegion)(THIS_ ULARGE_INTEGER libOffset, ULARGE_INTEGER  cb, DWORD dwLockType) PURE; \
63         STDMETHOD(Stat)(THIS_ STATSTG *pstatstg, DWORD grfStatFlag) PURE;
64 ICOM_DEFINE(ILockBytes16,IUnknown)
65 #undef INTERFACE
66
67
68 #endif /* __WINE_OLE_IFS_H */