1 | /*
|
---|
2 | * Declarations for OLE2
|
---|
3 | *
|
---|
4 | * Copyright (C) the Wine project
|
---|
5 | *
|
---|
6 | * This library is free software; you can redistribute it and/or
|
---|
7 | * modify it under the terms of the GNU Lesser General Public
|
---|
8 | * License as published by the Free Software Foundation; either
|
---|
9 | * version 2.1 of the License, or (at your option) any later version.
|
---|
10 | *
|
---|
11 | * This library is distributed in the hope that it will be useful,
|
---|
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
---|
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
---|
14 | * Lesser General Public License for more details.
|
---|
15 | *
|
---|
16 | * You should have received a copy of the GNU Lesser General Public
|
---|
17 | * License along with this library; if not, write to the Free Software
|
---|
18 | * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
---|
19 | */
|
---|
20 |
|
---|
21 | /*
|
---|
22 | * Sun LGPL Disclaimer: For the avoidance of doubt, except that if any license choice
|
---|
23 | * other than GPL or LGPL is available it will apply instead, Sun elects to use only
|
---|
24 | * the Lesser General Public License version 2.1 (LGPLv2) at this time for any software where
|
---|
25 | * a choice of LGPL license versions is made available with the language indicating
|
---|
26 | * that LGPLv2 or any later version may be used, or where a choice of which version
|
---|
27 | * of the LGPL is applied is otherwise unspecified.
|
---|
28 | */
|
---|
29 |
|
---|
30 | #ifndef __WINE_OLE2_H
|
---|
31 | #define __WINE_OLE2_H
|
---|
32 |
|
---|
33 | #include <winerror.h>
|
---|
34 | #include <objbase.h>
|
---|
35 | #include <oleauto.h>
|
---|
36 | #include <oleidl.h>
|
---|
37 |
|
---|
38 | struct tagMSG;
|
---|
39 |
|
---|
40 | #ifdef __cplusplus
|
---|
41 | extern "C" {
|
---|
42 | #endif /* defined(__cplusplus) */
|
---|
43 |
|
---|
44 | #define E_DRAW VIEW_E_DRAW
|
---|
45 | #define DATA_E_FORMATETC DV_E_FORMATETC
|
---|
46 |
|
---|
47 | #define OLEIVERB_PRIMARY (0L)
|
---|
48 | #define OLEIVERB_SHOW (-1L)
|
---|
49 | #define OLEIVERB_OPEN (-2L)
|
---|
50 | #define OLEIVERB_HIDE (-3L)
|
---|
51 | #define OLEIVERB_UIACTIVATE (-4L)
|
---|
52 | #define OLEIVERB_INPLACEACTIVATE (-5L)
|
---|
53 | #define OLEIVERB_DISCARDUNDOSTATE (-6L)
|
---|
54 | #define OLEIVERB_PROPERTIES (-7L)
|
---|
55 |
|
---|
56 | #define EMBDHLP_INPROC_HANDLER 0x00000000
|
---|
57 | #define EMBDHLP_INPROC_SERVER 0x00000001
|
---|
58 | #define EMBDHLP_CREATENOW 0x00000000
|
---|
59 | #define EMBDHLP_DELAYCREATE 0x00010000
|
---|
60 |
|
---|
61 | /*
|
---|
62 | * API declarations
|
---|
63 | */
|
---|
64 | HRESULT WINAPI RegisterDragDrop(HWND,LPDROPTARGET);
|
---|
65 | HRESULT WINAPI RevokeDragDrop(HWND);
|
---|
66 | HRESULT WINAPI DoDragDrop(LPDATAOBJECT,LPDROPSOURCE,DWORD,DWORD*);
|
---|
67 | HRESULT WINAPI OleLoadFromStream(IStream *pStm,REFIID iidInterface,void** ppvObj);
|
---|
68 | HRESULT WINAPI OleSaveToStream(IPersistStream *pPStm,IStream *pStm);
|
---|
69 | HOLEMENU WINAPI OleCreateMenuDescriptor(HMENU hmenuCombined,LPOLEMENUGROUPWIDTHS lpMenuWidths);
|
---|
70 | HRESULT WINAPI OleDestroyMenuDescriptor(HOLEMENU hmenuDescriptor);
|
---|
71 | HRESULT WINAPI OleSetMenuDescriptor(HOLEMENU hmenuDescriptor,HWND hwndFrame,HWND hwndActiveObject,LPOLEINPLACEFRAME lpFrame,LPOLEINPLACEACTIVEOBJECT lpActiveObject);
|
---|
72 |
|
---|
73 | HRESULT WINAPI WriteClassStg(IStorage *pstg, REFCLSID rclsid);
|
---|
74 | HRESULT WINAPI ReadClassStg(IStorage *pstg,CLSID *pclsid);
|
---|
75 | HRESULT WINAPI WriteClassStm(IStream *pStm,REFCLSID rclsid);
|
---|
76 | HRESULT WINAPI ReadClassStm(IStream *pStm,CLSID *pclsid);
|
---|
77 |
|
---|
78 |
|
---|
79 | HRESULT WINAPI OleSave(LPPERSISTSTORAGE pPS, LPSTORAGE pStg, BOOL fSameAsLoad);
|
---|
80 | HRESULT WINAPI OleRegGetUserType(REFCLSID clsid,
|
---|
81 | DWORD dwFormOfType,
|
---|
82 | LPOLESTR* pszUserType);
|
---|
83 | HRESULT WINAPI OleRegGetMiscStatus (REFCLSID clsid, DWORD dwAspect, DWORD* pdwStatus);
|
---|
84 | HRESULT WINAPI OleRegEnumFormatEtc (REFCLSID clsid,
|
---|
85 | DWORD dwDirection,
|
---|
86 | LPENUMFORMATETC* ppenumFormatetc);
|
---|
87 | HRESULT WINAPI CreateStreamOnHGlobal (HGLOBAL hGlobal, BOOL fDeleteOnRelease, LPSTREAM* ppstm);
|
---|
88 | HRESULT WINAPI GetHGlobalFromStream(LPSTREAM pstm, HGLOBAL* phglobal);
|
---|
89 | HRESULT WINAPI OleRegEnumVerbs (REFCLSID clsid, LPENUMOLEVERB* ppenum);
|
---|
90 | BOOL WINAPI OleIsRunning(LPOLEOBJECT pObject);
|
---|
91 | HRESULT WINAPI OleCreateLinkFromData(LPDATAOBJECT pSrcDataObj, REFIID riid,
|
---|
92 | DWORD renderopt, LPFORMATETC pFormatEtc,
|
---|
93 | LPOLECLIENTSITE pClientSite, LPSTORAGE pStg,
|
---|
94 | LPVOID* ppvObj);
|
---|
95 | HRESULT WINAPI OleSetContainedObject(LPUNKNOWN pUnknown, BOOL fContained);
|
---|
96 | HRESULT WINAPI OleNoteObjectVisible(LPUNKNOWN pUnknown, BOOL fVisible);
|
---|
97 | HRESULT WINAPI OleQueryLinkFromData(IDataObject* pSrcDataObject);
|
---|
98 | HRESULT WINAPI OleQueryCreateFromData(LPDATAOBJECT pSrcDataObject);
|
---|
99 | HRESULT WINAPI OleRun(LPUNKNOWN pUnknown);
|
---|
100 | HRESULT WINAPI OleDraw(LPUNKNOWN pUnknown, DWORD dwAspect, HDC hdcDraw, LPCRECT lprcBounds);
|
---|
101 | VOID WINAPI ReleaseStgMedium(LPSTGMEDIUM);
|
---|
102 | HRESULT WINAPI OleGetClipboard(IDataObject** ppDataObj);
|
---|
103 | HRESULT WINAPI OleIsCurrentClipboard(LPDATAOBJECT);
|
---|
104 | HRESULT WINAPI OleSetClipboard(LPDATAOBJECT);
|
---|
105 | HRESULT WINAPI OleCreateStaticFromData(LPDATAOBJECT pSrcDataObj, REFIID iid,
|
---|
106 | DWORD renderopt, LPFORMATETC pFormatEtc, LPOLECLIENTSITE pClientSite,
|
---|
107 | LPSTORAGE pStg, LPVOID* ppvObj);
|
---|
108 | HRESULT WINAPI ReadFmtUserTypeStg(LPSTORAGE pstg, CLIPFORMAT* pcf, LPOLESTR* lplpszUserType);
|
---|
109 | HRESULT WINAPI OleLoad(LPSTORAGE pStg, REFIID riid, LPOLECLIENTSITE pClientSite, LPVOID* ppvObj);
|
---|
110 | HRESULT WINAPI GetHGlobalFromILockBytes(LPLOCKBYTES plkbyt, HGLOBAL* phglobal);
|
---|
111 | HRESULT WINAPI CreateILockBytesOnHGlobal(HGLOBAL hGlobal, BOOL fDeleteOnRelease, LPLOCKBYTES* pplkbyt);
|
---|
112 | HRESULT WINAPI CreateDataAdviseHolder(LPDATAADVISEHOLDER* ppDAHolder);
|
---|
113 | HGLOBAL WINAPI OleGetIconOfClass(REFCLSID rclsid, LPOLESTR lpszLabel, BOOL fUseTypeAsLabel);
|
---|
114 | HGLOBAL WINAPI OleGetIconOfFile(LPOLESTR lpszPath, BOOL fUseFileAsLabel);
|
---|
115 | HGLOBAL WINAPI OleMetafilePictFromIconAndLabel(HICON hIcon, LPOLESTR lpszLabel, LPOLESTR lpszSourceFile, UINT iIconIndex);
|
---|
116 | HRESULT WINAPI OleLockRunning(LPUNKNOWN pUnknown, BOOL fLock, BOOL fLastUnlockCloses);
|
---|
117 | HRESULT WINAPI OleCreateFromFile(REFCLSID rclsid, LPCOLESTR lpszFileName, REFIID riid,
|
---|
118 | DWORD renderopt, LPFORMATETC lpFormatEtc, LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID* ppvObj);
|
---|
119 | HRESULT WINAPI OleCreateLink(LPMONIKER pmkLinkSrc, REFIID riid, DWORD renderopt, LPFORMATETC lpFormatEtc,
|
---|
120 | LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID* ppvObj);
|
---|
121 | HRESULT WINAPI OleCreate(REFCLSID rclsid, REFIID riid, DWORD renderopt, LPFORMATETC pFormatEtc, LPOLECLIENTSITE pClientSite,
|
---|
122 | LPSTORAGE pStg, LPVOID* ppvObj);
|
---|
123 | HRESULT WINAPI OleFlushClipboard(void);
|
---|
124 | HRESULT WINAPI GetConvertStg(LPSTORAGE pStg);
|
---|
125 | HRESULT WINAPI SetConvertStg(LPSTORAGE pStg, BOOL fConvert);
|
---|
126 | BOOL WINAPI IsAccelerator(HACCEL hAccel, int cAccelEntries, struct tagMSG* lpMsg, WORD* lpwCmd);
|
---|
127 | HRESULT WINAPI OleCreateLinkToFile(LPCOLESTR lpszFileName, REFIID riid, DWORD renderopt, LPFORMATETC lpFormatEtc,
|
---|
128 | LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID* ppvObj);
|
---|
129 | HANDLE WINAPI OleDuplicateData(HANDLE hSrc, CLIPFORMAT cfFormat, UINT uiFlags);
|
---|
130 | HRESULT WINAPI WriteFmtUserTypeStg(LPSTORAGE pstg, CLIPFORMAT cf, LPOLESTR lpszUserType);
|
---|
131 | HRESULT WINAPI OleTranslateAccelerator (LPOLEINPLACEFRAME lpFrame, LPOLEINPLACEFRAMEINFO lpFrameInfo, struct tagMSG* lpmsg);
|
---|
132 | HRESULT WINAPI OleCreateFromData(LPDATAOBJECT pSrcDataObj, REFIID riid, DWORD renderopt, LPFORMATETC pFormatEtc,
|
---|
133 | LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID* ppvObj);
|
---|
134 | HRESULT WINAPI OleCreateFromDataEx(LPDATAOBJECT pSrcDataObj, REFIID riid, DWORD dwFlags, DWORD renderopt, ULONG num_formats,
|
---|
135 | DWORD *adv_flags, LPFORMATETC fmts, IAdviseSink *sink, DWORD *conns,
|
---|
136 | LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID* ppvObj);
|
---|
137 | HRESULT WINAPI OleCreateDefaultHandler(REFCLSID clsid,
|
---|
138 | LPUNKNOWN pUnkOuter,
|
---|
139 | REFIID riid,
|
---|
140 | LPVOID* ppvObj);
|
---|
141 | HRESULT WINAPI OleCreateEmbeddingHelper(REFCLSID clsid,
|
---|
142 | LPUNKNOWN pUnkOuter,
|
---|
143 | DWORD flags,
|
---|
144 | IClassFactory *pCF,
|
---|
145 | REFIID riid,
|
---|
146 | LPVOID* ppvObj);
|
---|
147 | HRESULT WINAPI CreateOleAdviseHolder (LPOLEADVISEHOLDER *ppOAHolder);
|
---|
148 | HRESULT WINAPI OleInitialize(LPVOID pvReserved);
|
---|
149 | void WINAPI OleUninitialize(void);
|
---|
150 | BOOL WINAPI IsValidInterface(LPUNKNOWN punk);
|
---|
151 | DWORD WINAPI OleBuildVersion(VOID);
|
---|
152 |
|
---|
153 | /*
|
---|
154 | * OLE version conversion declarations
|
---|
155 | */
|
---|
156 |
|
---|
157 |
|
---|
158 | typedef struct _OLESTREAM* LPOLESTREAM;
|
---|
159 | typedef struct _OLESTREAMVTBL {
|
---|
160 | DWORD (CALLBACK *Get)(LPOLESTREAM,LPSTR,DWORD);
|
---|
161 | DWORD (CALLBACK *Put)(LPOLESTREAM,LPSTR,DWORD);
|
---|
162 | } OLESTREAMVTBL;
|
---|
163 | typedef OLESTREAMVTBL* LPOLESTREAMVTBL;
|
---|
164 | typedef struct _OLESTREAM {
|
---|
165 | LPOLESTREAMVTBL lpstbl;
|
---|
166 | } OLESTREAM;
|
---|
167 |
|
---|
168 | HRESULT WINAPI OleConvertOLESTREAMToIStorage( LPOLESTREAM lpolestream, LPSTORAGE pstg, const DVTARGETDEVICE* ptd);
|
---|
169 | HRESULT WINAPI OleConvertIStorageToOLESTREAM( LPSTORAGE pstg, LPOLESTREAM lpolestream);
|
---|
170 |
|
---|
171 | HRESULT WINAPI OleDoAutoConvert( LPSTORAGE pStg, LPCLSID pClsidNew );
|
---|
172 | HRESULT WINAPI OleGetAutoConvert( REFCLSID clsidOld, LPCLSID pClsidNew );
|
---|
173 | HRESULT WINAPI OleSetAutoConvert( REFCLSID clsidOld, REFCLSID clsidNew );
|
---|
174 |
|
---|
175 | #ifdef __cplusplus
|
---|
176 | } /* extern "C" */
|
---|
177 | #endif /* defined(__cplusplus) */
|
---|
178 |
|
---|
179 | #endif /* __WINE_OLE2_H */
|
---|