nsiproxy.sys: Implement change notifications for NSI_IP_UNICAST_TABLE.
[wine.git] / include / ole2.h
blob1a07d5b4052f3db075a7007bf595e8fe6d70b693
1 /*
2 * Declarations for OLE2
4 * Copyright (C) the Wine project
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.
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.
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
21 #ifndef __WINE_OLE2_H
22 #define __WINE_OLE2_H
24 #include <winerror.h>
25 #include <objbase.h>
26 #include <oleauto.h>
27 #include <oleidl.h>
29 struct tagMSG;
31 #ifdef __cplusplus
32 extern "C" {
33 #endif /* defined(__cplusplus) */
35 #define E_DRAW VIEW_E_DRAW
36 #define DATA_E_FORMATETC DV_E_FORMATETC
38 #define OLEIVERB_PRIMARY (__MSABI_LONG(0))
39 #define OLEIVERB_SHOW (__MSABI_LONG(-1))
40 #define OLEIVERB_OPEN (__MSABI_LONG(-2))
41 #define OLEIVERB_HIDE (__MSABI_LONG(-3))
42 #define OLEIVERB_UIACTIVATE (__MSABI_LONG(-4))
43 #define OLEIVERB_INPLACEACTIVATE (__MSABI_LONG(-5))
44 #define OLEIVERB_DISCARDUNDOSTATE (__MSABI_LONG(-6))
45 #define OLEIVERB_PROPERTIES (__MSABI_LONG(-7))
47 #define EMBDHLP_INPROC_HANDLER 0x00000000
48 #define EMBDHLP_INPROC_SERVER 0x00000001
49 #define EMBDHLP_CREATENOW 0x00000000
50 #define EMBDHLP_DELAYCREATE 0x00010000
53 * API declarations
55 WINOLE32API HRESULT WINAPI RegisterDragDrop(HWND,LPDROPTARGET);
56 WINOLE32API HRESULT WINAPI RevokeDragDrop(HWND);
57 WINOLE32API HRESULT WINAPI DoDragDrop(LPDATAOBJECT,LPDROPSOURCE,DWORD,DWORD*);
58 WINOLE32API HRESULT WINAPI OleLoadFromStream(IStream *pStm,REFIID iidInterface,void** ppvObj);
59 WINOLE32API HRESULT WINAPI OleSaveToStream(IPersistStream *pPStm,IStream *pStm);
60 WINOLE32API HOLEMENU WINAPI OleCreateMenuDescriptor(HMENU hmenuCombined,LPOLEMENUGROUPWIDTHS lpMenuWidths);
61 WINOLE32API HRESULT WINAPI OleDestroyMenuDescriptor(HOLEMENU hmenuDescriptor);
62 WINOLE32API HRESULT WINAPI OleSetMenuDescriptor(HOLEMENU hmenuDescriptor,HWND hwndFrame,HWND hwndActiveObject,LPOLEINPLACEFRAME lpFrame,LPOLEINPLACEACTIVEOBJECT lpActiveObject);
64 WINOLE32API HRESULT WINAPI WriteClassStg(IStorage *pstg, REFCLSID rclsid);
65 WINOLE32API HRESULT WINAPI ReadClassStg(IStorage *pstg,CLSID *pclsid);
66 WINOLE32API HRESULT WINAPI WriteClassStm(IStream *pStm,REFCLSID rclsid);
67 WINOLE32API HRESULT WINAPI ReadClassStm(IStream *pStm,CLSID *pclsid);
70 WINOLE32API HRESULT WINAPI OleSave(LPPERSISTSTORAGE pPS, LPSTORAGE pStg, BOOL fSameAsLoad);
71 WINOLE32API HRESULT WINAPI OleRegGetUserType(REFCLSID clsid, DWORD dwFormOfType, LPOLESTR* pszUserType);
72 WINOLE32API HRESULT WINAPI OleRegGetMiscStatus (REFCLSID clsid, DWORD dwAspect, DWORD* pdwStatus);
73 WINOLE32API HRESULT WINAPI OleRegEnumFormatEtc (REFCLSID clsid, DWORD dwDirection, LPENUMFORMATETC* ppenumFormatetc);
74 WINOLE32API HRESULT WINAPI CreateStreamOnHGlobal (HGLOBAL hGlobal, BOOL fDeleteOnRelease, LPSTREAM* ppstm);
75 WINOLE32API HRESULT WINAPI GetHGlobalFromStream(LPSTREAM pstm, HGLOBAL* phglobal);
76 WINOLE32API HRESULT WINAPI OleRegEnumVerbs (REFCLSID clsid, LPENUMOLEVERB* ppenum);
77 WINOLE32API BOOL WINAPI OleIsRunning(LPOLEOBJECT pObject);
78 WINOLE32API HRESULT WINAPI OleCreateLinkFromData(LPDATAOBJECT pSrcDataObj, REFIID riid, DWORD renderopt, LPFORMATETC pFormatEtc, LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID* ppvObj);
79 WINOLE32API HRESULT WINAPI OleSetContainedObject(LPUNKNOWN pUnknown, BOOL fContained);
80 WINOLE32API HRESULT WINAPI OleNoteObjectVisible(LPUNKNOWN pUnknown, BOOL fVisible);
81 WINOLE32API HRESULT WINAPI OleQueryLinkFromData(IDataObject* pSrcDataObject);
82 WINOLE32API HRESULT WINAPI OleQueryCreateFromData(LPDATAOBJECT pSrcDataObject);
83 WINOLE32API HRESULT WINAPI OleRun(LPUNKNOWN pUnknown);
84 WINOLE32API HRESULT WINAPI OleDraw(LPUNKNOWN pUnknown, DWORD dwAspect, HDC hdcDraw, LPCRECT lprcBounds);
85 WINOLE32API VOID WINAPI ReleaseStgMedium(LPSTGMEDIUM);
86 WINOLE32API HRESULT WINAPI OleGetClipboard(IDataObject** ppDataObj);
87 WINOLE32API HRESULT WINAPI OleIsCurrentClipboard(LPDATAOBJECT);
88 WINOLE32API HRESULT WINAPI OleSetClipboard(LPDATAOBJECT);
89 WINOLE32API HRESULT WINAPI OleCreateStaticFromData(LPDATAOBJECT pSrcDataObj, REFIID iid, DWORD renderopt, LPFORMATETC pFormatEtc, LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID* ppvObj);
90 WINOLE32API HRESULT WINAPI ReadFmtUserTypeStg(LPSTORAGE pstg, CLIPFORMAT* pcf, LPOLESTR* lplpszUserType);
91 WINOLE32API HRESULT WINAPI OleLoad(LPSTORAGE pStg, REFIID riid, LPOLECLIENTSITE pClientSite, LPVOID* ppvObj);
92 WINOLE32API HRESULT WINAPI GetHGlobalFromILockBytes(LPLOCKBYTES plkbyt, HGLOBAL* phglobal);
93 WINOLE32API HRESULT WINAPI CreateILockBytesOnHGlobal(HGLOBAL hGlobal, BOOL fDeleteOnRelease, LPLOCKBYTES* pplkbyt);
94 WINOLE32API HRESULT WINAPI CreateDataAdviseHolder(LPDATAADVISEHOLDER* ppDAHolder);
95 WINOLE32API HGLOBAL WINAPI OleGetIconOfClass(REFCLSID rclsid, LPOLESTR lpszLabel, BOOL fUseTypeAsLabel);
96 WINOLE32API HGLOBAL WINAPI OleGetIconOfFile(LPOLESTR lpszPath, BOOL fUseFileAsLabel);
97 WINOLE32API HGLOBAL WINAPI OleMetafilePictFromIconAndLabel(HICON hIcon, LPOLESTR lpszLabel, LPOLESTR lpszSourceFile, UINT iIconIndex);
98 WINOLE32API HRESULT WINAPI OleLockRunning(LPUNKNOWN pUnknown, BOOL fLock, BOOL fLastUnlockCloses);
99 WINOLE32API HRESULT WINAPI OleCreateFromFile(REFCLSID rclsid, LPCOLESTR lpszFileName, REFIID riid,
100 DWORD renderopt, LPFORMATETC lpFormatEtc, LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID* ppvObj);
101 WINOLE32API HRESULT WINAPI OleCreateFromFileEx(REFCLSID clsid, LPCOLESTR filename, REFIID iid, DWORD flags,
102 DWORD renderopt, ULONG num_fmts, DWORD *adv_flags, LPFORMATETC fmts, IAdviseSink *sink,
103 DWORD *conns, LPOLECLIENTSITE client_site, LPSTORAGE storage, LPVOID* obj);
104 WINOLE32API HRESULT WINAPI OleCreateLink(LPMONIKER pmkLinkSrc, REFIID riid, DWORD renderopt, LPFORMATETC lpFormatEtc,LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID* ppvObj);
105 WINOLE32API HRESULT WINAPI OleCreate(REFCLSID rclsid, REFIID riid, DWORD renderopt, LPFORMATETC pFormatEtc, LPOLECLIENTSITE pClientSite,LPSTORAGE pStg, LPVOID* ppvObj);
106 WINOLE32API HRESULT WINAPI OleFlushClipboard(void);
107 WINOLE32API HRESULT WINAPI GetConvertStg(LPSTORAGE pStg);
108 WINOLE32API HRESULT WINAPI SetConvertStg(LPSTORAGE pStg, BOOL fConvert);
109 WINOLE32API BOOL WINAPI IsAccelerator(HACCEL hAccel, int cAccelEntries, struct tagMSG* lpMsg, WORD* lpwCmd);
110 WINOLE32API HRESULT WINAPI OleCreateLinkToFile(LPCOLESTR lpszFileName, REFIID riid, DWORD renderopt, LPFORMATETC lpFormatEtc,
111 LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID* ppvObj);
112 WINOLE32API HANDLE WINAPI OleDuplicateData(HANDLE hSrc, CLIPFORMAT cfFormat, UINT uiFlags);
113 WINOLE32API HRESULT WINAPI WriteFmtUserTypeStg(LPSTORAGE pstg, CLIPFORMAT cf, LPOLESTR lpszUserType);
114 WINOLE32API HRESULT WINAPI OleTranslateAccelerator (LPOLEINPLACEFRAME lpFrame, LPOLEINPLACEFRAMEINFO lpFrameInfo, struct tagMSG* lpmsg);
115 WINOLE32API HRESULT WINAPI OleCreateFromData(LPDATAOBJECT pSrcDataObj, REFIID riid, DWORD renderopt, LPFORMATETC pFormatEtc,
116 LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID* ppvObj);
117 WINOLE32API HRESULT WINAPI OleCreateFromDataEx(LPDATAOBJECT pSrcDataObj, REFIID riid, DWORD dwFlags, DWORD renderopt, ULONG num_formats,
118 DWORD *adv_flags, LPFORMATETC fmts, IAdviseSink *sink, DWORD *conns,
119 LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID* ppvObj);
120 WINOLE32API HRESULT WINAPI OleCreateDefaultHandler(REFCLSID clsid, LPUNKNOWN pUnkOuter, REFIID riid, LPVOID* ppvObj);
121 WINOLE32API HRESULT WINAPI OleCreateEmbeddingHelper(REFCLSID clsid, LPUNKNOWN pUnkOuter, DWORD flags, IClassFactory *pCF, REFIID riid, LPVOID* ppvObj);
122 WINOLE32API HRESULT WINAPI CreateOleAdviseHolder (LPOLEADVISEHOLDER *ppOAHolder);
123 WINOLE32API HRESULT WINAPI OleInitialize(LPVOID pvReserved);
124 WINOLE32API void WINAPI OleUninitialize(void);
125 WINOLE32API BOOL WINAPI IsValidInterface(LPUNKNOWN punk);
126 WINOLE32API DWORD WINAPI OleBuildVersion(VOID);
129 * OLE version conversion declarations
133 typedef struct _OLESTREAM* LPOLESTREAM;
134 typedef struct _OLESTREAMVTBL {
135 DWORD (CALLBACK *Get)(LPOLESTREAM,LPSTR,DWORD);
136 DWORD (CALLBACK *Put)(LPOLESTREAM,LPSTR,DWORD);
137 } OLESTREAMVTBL;
138 typedef OLESTREAMVTBL* LPOLESTREAMVTBL;
139 typedef struct _OLESTREAM {
140 LPOLESTREAMVTBL lpstbl;
141 } OLESTREAM;
143 WINOLE32API HRESULT WINAPI OleConvertOLESTREAMToIStorage( LPOLESTREAM lpolestream, LPSTORAGE pstg, const DVTARGETDEVICE* ptd);
144 WINOLE32API HRESULT WINAPI OleConvertIStorageToOLESTREAM( LPSTORAGE pstg, LPOLESTREAM lpolestream);
145 WINOLE32API HRESULT WINAPI OleConvertIStorageToOLESTREAMEx( LPSTORAGE stg, CLIPFORMAT cf, LONG width, LONG height,
146 DWORD size, LPSTGMEDIUM medium, LPOLESTREAM olestream );
147 WINOLE32API HRESULT WINAPI OleDoAutoConvert( LPSTORAGE pStg, LPCLSID pClsidNew );
148 WINOLE32API HRESULT WINAPI OleGetAutoConvert( REFCLSID clsidOld, LPCLSID pClsidNew );
149 WINOLE32API HRESULT WINAPI OleSetAutoConvert( REFCLSID clsidOld, REFCLSID clsidNew );
151 #ifdef __cplusplus
152 } /* extern "C" */
153 #endif /* defined(__cplusplus) */
155 #endif /* __WINE_OLE2_H */