[1166] | 1 | /**
|
---|
| 2 | * This file is part of the mingw-w64 runtime package.
|
---|
| 3 | * No warranty is given; refer to the file DISCLAIMER within this package.
|
---|
| 4 | */
|
---|
| 5 | #include <winapifamily.h>
|
---|
| 6 |
|
---|
| 7 | #ifndef _OLE2_H_
|
---|
| 8 | #define _OLE2_H_
|
---|
| 9 |
|
---|
| 10 | #include <pshpack8.h>
|
---|
| 11 |
|
---|
| 12 | #ifndef WIN32
|
---|
| 13 | #define WIN32 100
|
---|
| 14 | #endif
|
---|
| 15 |
|
---|
| 16 | #include <winerror.h>
|
---|
| 17 | #include <objbase.h>
|
---|
| 18 | #include <oleauto.h>
|
---|
| 19 |
|
---|
| 20 | #define E_DRAW VIEW_E_DRAW
|
---|
| 21 | #define DATA_E_FORMATETC DV_E_FORMATETC
|
---|
| 22 |
|
---|
| 23 | #define OLEIVERB_PRIMARY (__MSABI_LONG(0))
|
---|
| 24 | #define OLEIVERB_SHOW (-__MSABI_LONG(1))
|
---|
| 25 | #define OLEIVERB_OPEN (-__MSABI_LONG(2))
|
---|
| 26 | #define OLEIVERB_HIDE (-__MSABI_LONG(3))
|
---|
| 27 | #define OLEIVERB_UIACTIVATE (-__MSABI_LONG(4))
|
---|
| 28 | #define OLEIVERB_INPLACEACTIVATE (-__MSABI_LONG(5))
|
---|
| 29 | #define OLEIVERB_DISCARDUNDOSTATE (-__MSABI_LONG(6))
|
---|
| 30 |
|
---|
| 31 | #define EMBDHLP_INPROC_HANDLER __MSABI_LONG(0x0000)
|
---|
| 32 | #define EMBDHLP_INPROC_SERVER __MSABI_LONG(0x0001)
|
---|
| 33 | #define EMBDHLP_CREATENOW __MSABI_LONG(0x00000000)
|
---|
| 34 | #define EMBDHLP_DELAYCREATE __MSABI_LONG(0x00010000)
|
---|
| 35 |
|
---|
| 36 | #define OLECREATE_LEAVERUNNING 0x1
|
---|
| 37 |
|
---|
| 38 | #include <oleidl.h>
|
---|
| 39 |
|
---|
| 40 | #if WINAPI_FAMILY_PARTITION (WINAPI_PARTITION_DESKTOP)
|
---|
| 41 | WINOLEAPI_ (DWORD) OleBuildVersion (VOID);
|
---|
| 42 | #if !defined (ISOLATION_AWARE_ENABLED) || !ISOLATION_AWARE_ENABLED || !defined (_OBJBASE_H_) || !defined (CreateDataAdviseHolder)
|
---|
| 43 | WINOLEAPI CreateDataAdviseHolder (LPDATAADVISEHOLDER *ppDAHolder);
|
---|
| 44 | #endif
|
---|
| 45 | #endif
|
---|
| 46 |
|
---|
| 47 | #if WINAPI_FAMILY_PARTITION (WINAPI_PARTITION_APP)
|
---|
| 48 | WINOLEAPI ReadClassStg (LPSTORAGE pStg, CLSID *pclsid);
|
---|
| 49 | WINOLEAPI WriteClassStg (LPSTORAGE pStg, REFCLSID rclsid);
|
---|
| 50 | WINOLEAPI ReadClassStm (LPSTREAM pStm, CLSID *pclsid);
|
---|
| 51 | WINOLEAPI WriteClassStm (LPSTREAM pStm, REFCLSID rclsid);
|
---|
| 52 | #endif
|
---|
| 53 |
|
---|
| 54 | #if WINAPI_FAMILY_PARTITION (WINAPI_PARTITION_DESKTOP)
|
---|
| 55 | WINOLEAPI WriteFmtUserTypeStg (LPSTORAGE pstg, CLIPFORMAT cf, LPOLESTR lpszUserType);
|
---|
| 56 | WINOLEAPI ReadFmtUserTypeStg (LPSTORAGE pstg, CLIPFORMAT *pcf, LPOLESTR *lplpszUserType);
|
---|
| 57 | WINOLEAPI OleInitialize (LPVOID pvReserved);
|
---|
| 58 | WINOLEAPI_ (void) OleUninitialize (void);
|
---|
| 59 | WINOLEAPI OleQueryLinkFromData (LPDATAOBJECT pSrcDataObject);
|
---|
| 60 | WINOLEAPI OleQueryCreateFromData (LPDATAOBJECT pSrcDataObject);
|
---|
| 61 | WINOLEAPI OleCreate (REFCLSID rclsid, REFIID riid, DWORD renderopt, LPFORMATETC pFormatEtc, LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID *ppvObj);
|
---|
| 62 | WINOLEAPI OleCreateEx (REFCLSID rclsid, REFIID riid, DWORD dwFlags, DWORD renderopt, ULONG cFormats, DWORD *rgAdvf, LPFORMATETC rgFormatEtc, IAdviseSink *lpAdviseSink, DWORD *rgdwConnection, LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID *ppvObj);
|
---|
| 63 | WINOLEAPI OleCreateFromData (LPDATAOBJECT pSrcDataObj, REFIID riid, DWORD renderopt, LPFORMATETC pFormatEtc, LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID *ppvObj);
|
---|
| 64 | WINOLEAPI OleCreateFromDataEx (LPDATAOBJECT pSrcDataObj, REFIID riid, DWORD dwFlags, DWORD renderopt, ULONG cFormats, DWORD *rgAdvf, LPFORMATETC rgFormatEtc, IAdviseSink *lpAdviseSink, DWORD *rgdwConnection, LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID *ppvObj);
|
---|
| 65 | WINOLEAPI OleCreateLinkFromData (LPDATAOBJECT pSrcDataObj, REFIID riid, DWORD renderopt, LPFORMATETC pFormatEtc, LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID *ppvObj);
|
---|
| 66 | WINOLEAPI OleCreateLinkFromDataEx (LPDATAOBJECT pSrcDataObj, REFIID riid, DWORD dwFlags, DWORD renderopt, ULONG cFormats, DWORD *rgAdvf, LPFORMATETC rgFormatEtc, IAdviseSink *lpAdviseSink, DWORD *rgdwConnection, LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID *ppvObj);
|
---|
| 67 | WINOLEAPI OleCreateStaticFromData (LPDATAOBJECT pSrcDataObj, REFIID iid, DWORD renderopt, LPFORMATETC pFormatEtc, LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID *ppvObj);
|
---|
| 68 | WINOLEAPI OleCreateLink (LPMONIKER pmkLinkSrc, REFIID riid, DWORD renderopt, LPFORMATETC lpFormatEtc, LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID *ppvObj);
|
---|
| 69 | WINOLEAPI OleCreateLinkEx (LPMONIKER pmkLinkSrc, REFIID riid, DWORD dwFlags, DWORD renderopt, ULONG cFormats, DWORD *rgAdvf, LPFORMATETC rgFormatEtc, IAdviseSink *lpAdviseSink, DWORD *rgdwConnection, LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID *ppvObj);
|
---|
| 70 | WINOLEAPI OleCreateLinkToFile (LPCOLESTR lpszFileName, REFIID riid, DWORD renderopt, LPFORMATETC lpFormatEtc, LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID *ppvObj);
|
---|
| 71 | WINOLEAPI OleCreateLinkToFileEx (LPCOLESTR lpszFileName, REFIID riid, DWORD dwFlags, DWORD renderopt, ULONG cFormats, DWORD *rgAdvf, LPFORMATETC rgFormatEtc, IAdviseSink *lpAdviseSink, DWORD *rgdwConnection, LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID *ppvObj);
|
---|
| 72 | WINOLEAPI OleCreateFromFile (REFCLSID rclsid, LPCOLESTR lpszFileName, REFIID riid, DWORD renderopt, LPFORMATETC lpFormatEtc, LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID *ppvObj);
|
---|
| 73 | WINOLEAPI OleCreateFromFileEx (REFCLSID rclsid, LPCOLESTR lpszFileName, REFIID riid, DWORD dwFlags, DWORD renderopt, ULONG cFormats, DWORD *rgAdvf, LPFORMATETC rgFormatEtc, IAdviseSink *lpAdviseSink, DWORD *rgdwConnection, LPOLECLIENTSITE pClientSite, LPSTORAGE pStg, LPVOID *ppvObj);
|
---|
| 74 | WINOLEAPI OleLoad (LPSTORAGE pStg, REFIID riid, LPOLECLIENTSITE pClientSite, LPVOID *ppvObj);
|
---|
| 75 | WINOLEAPI OleSave (LPPERSISTSTORAGE pPS, LPSTORAGE pStg, WINBOOL fSameAsLoad);
|
---|
| 76 | WINOLEAPI OleLoadFromStream (LPSTREAM pStm, REFIID iidInterface, LPVOID *ppvObj);
|
---|
| 77 | WINOLEAPI OleSaveToStream (LPPERSISTSTREAM pPStm, LPSTREAM pStm);
|
---|
| 78 | WINOLEAPI OleSetContainedObject (LPUNKNOWN pUnknown, WINBOOL fContained);
|
---|
| 79 | WINOLEAPI OleNoteObjectVisible (LPUNKNOWN pUnknown, WINBOOL fVisible);
|
---|
| 80 | WINOLEAPI RegisterDragDrop (HWND hwnd, LPDROPTARGET pDropTarget);
|
---|
| 81 | WINOLEAPI RevokeDragDrop (HWND hwnd);
|
---|
| 82 | WINOLEAPI DoDragDrop (LPDATAOBJECT pDataObj, LPDROPSOURCE pDropSource, DWORD dwOKEffects, LPDWORD pdwEffect);
|
---|
| 83 | WINOLEAPI OleSetClipboard (LPDATAOBJECT pDataObj);
|
---|
| 84 | WINOLEAPI OleGetClipboard (LPDATAOBJECT *ppDataObj);
|
---|
| 85 | WINOLEAPI OleFlushClipboard (void);
|
---|
| 86 | WINOLEAPI OleIsCurrentClipboard (LPDATAOBJECT pDataObj);
|
---|
| 87 | WINOLEAPI_ (HOLEMENU) OleCreateMenuDescriptor (HMENU hmenuCombined, LPOLEMENUGROUPWIDTHS lpMenuWidths);
|
---|
| 88 | WINOLEAPI OleSetMenuDescriptor (HOLEMENU holemenu, HWND hwndFrame, HWND hwndActiveObject, LPOLEINPLACEFRAME lpFrame, LPOLEINPLACEACTIVEOBJECT lpActiveObj);
|
---|
| 89 | WINOLEAPI OleDestroyMenuDescriptor (HOLEMENU holemenu);
|
---|
| 90 | WINOLEAPI OleTranslateAccelerator (LPOLEINPLACEFRAME lpFrame, LPOLEINPLACEFRAMEINFO lpFrameInfo, LPMSG lpmsg);
|
---|
| 91 | WINOLEAPI_ (HANDLE) OleDuplicateData (HANDLE hSrc, CLIPFORMAT cfFormat, UINT uiFlags);
|
---|
| 92 | WINOLEAPI OleDraw (LPUNKNOWN pUnknown, DWORD dwAspect, HDC hdcDraw, LPCRECT lprcBounds);
|
---|
| 93 | WINOLEAPI OleRun (LPUNKNOWN pUnknown);
|
---|
| 94 | WINOLEAPI_ (WINBOOL) OleIsRunning (LPOLEOBJECT pObject);
|
---|
| 95 | WINOLEAPI OleLockRunning (LPUNKNOWN pUnknown, WINBOOL fLock, WINBOOL fLastUnlockCloses);
|
---|
| 96 | WINOLEAPI_ (void) ReleaseStgMedium (LPSTGMEDIUM);
|
---|
| 97 | WINOLEAPI CreateOleAdviseHolder (LPOLEADVISEHOLDER *ppOAHolder);
|
---|
| 98 | WINOLEAPI OleCreateDefaultHandler (REFCLSID clsid, LPUNKNOWN pUnkOuter, REFIID riid, LPVOID *lplpObj);
|
---|
| 99 | WINOLEAPI OleCreateEmbeddingHelper (REFCLSID clsid, LPUNKNOWN pUnkOuter, DWORD flags, LPCLASSFACTORY pCF, REFIID riid, LPVOID *lplpObj);
|
---|
| 100 | WINOLEAPI_ (WINBOOL) IsAccelerator (HACCEL hAccel, int cAccelEntries, LPMSG lpMsg, WORD *lpwCmd);
|
---|
| 101 | WINOLEAPI_ (HGLOBAL) OleGetIconOfFile (LPOLESTR lpszPath, WINBOOL fUseFileAsLabel);
|
---|
| 102 | WINOLEAPI_ (HGLOBAL) OleGetIconOfClass (REFCLSID rclsid, LPOLESTR lpszLabel, WINBOOL fUseTypeAsLabel);
|
---|
| 103 | WINOLEAPI_ (HGLOBAL) OleMetafilePictFromIconAndLabel (HICON hIcon, LPOLESTR lpszLabel, LPOLESTR lpszSourceFile, UINT iIconIndex);
|
---|
| 104 | WINOLEAPI OleRegGetUserType (REFCLSID clsid, DWORD dwFormOfType, LPOLESTR *pszUserType);
|
---|
| 105 | WINOLEAPI OleRegGetMiscStatus (REFCLSID clsid, DWORD dwAspect, DWORD *pdwStatus);
|
---|
| 106 | WINOLEAPI OleRegEnumFormatEtc (REFCLSID clsid, DWORD dwDirection, LPENUMFORMATETC *ppenum);
|
---|
| 107 | WINOLEAPI OleRegEnumVerbs (REFCLSID clsid, LPENUMOLEVERB *ppenum);
|
---|
| 108 |
|
---|
| 109 | typedef struct _OLESTREAM *LPOLESTREAM;
|
---|
| 110 |
|
---|
| 111 | typedef struct _OLESTREAMVTBL {
|
---|
| 112 | DWORD (CALLBACK *Get) (LPOLESTREAM, void *, DWORD);
|
---|
| 113 | DWORD (CALLBACK *Put) (LPOLESTREAM, const void *, DWORD);
|
---|
| 114 | } OLESTREAMVTBL;
|
---|
| 115 | typedef OLESTREAMVTBL *LPOLESTREAMVTBL;
|
---|
| 116 |
|
---|
| 117 | typedef struct _OLESTREAM {
|
---|
| 118 | LPOLESTREAMVTBL lpstbl;
|
---|
| 119 | } OLESTREAM;
|
---|
| 120 |
|
---|
| 121 | WINOLEAPI OleConvertOLESTREAMToIStorage (LPOLESTREAM lpolestream, LPSTORAGE pstg, const DVTARGETDEVICE *ptd);
|
---|
| 122 | WINOLEAPI OleConvertIStorageToOLESTREAM (LPSTORAGE pstg, LPOLESTREAM lpolestream);
|
---|
| 123 | #endif
|
---|
| 124 |
|
---|
| 125 | #if WINAPI_FAMILY_PARTITION (WINAPI_PARTITION_APP)
|
---|
| 126 | WINOLEAPI GetHGlobalFromILockBytes (LPLOCKBYTES plkbyt, HGLOBAL *phglobal);
|
---|
| 127 | WINOLEAPI CreateILockBytesOnHGlobal (HGLOBAL hGlobal, WINBOOL fDeleteOnRelease, LPLOCKBYTES *pplkbyt);
|
---|
| 128 | #endif
|
---|
| 129 |
|
---|
| 130 | #if WINAPI_FAMILY_PARTITION (WINAPI_PARTITION_DESKTOP)
|
---|
| 131 | WINOLEAPI OleDoAutoConvert (LPSTORAGE pStg, LPCLSID pClsidNew);
|
---|
| 132 | WINOLEAPI OleGetAutoConvert (REFCLSID clsidOld, LPCLSID pClsidNew);
|
---|
| 133 | WINOLEAPI OleSetAutoConvert (REFCLSID clsidOld, REFCLSID clsidNew);
|
---|
| 134 | #endif
|
---|
| 135 |
|
---|
| 136 | #if WINAPI_FAMILY_PARTITION (WINAPI_PARTITION_APP)
|
---|
| 137 | WINOLEAPI GetConvertStg (LPSTORAGE pStg);
|
---|
| 138 | #endif
|
---|
| 139 |
|
---|
| 140 | #if WINAPI_FAMILY_PARTITION (WINAPI_PARTITION_DESKTOP)
|
---|
| 141 | WINOLEAPI SetConvertStg (LPSTORAGE pStg, WINBOOL fConvert);
|
---|
| 142 | WINOLEAPI OleConvertIStorageToOLESTREAMEx (LPSTORAGE pstg, CLIPFORMAT cfFormat, LONG lWidth, LONG lHeight, DWORD dwSize, LPSTGMEDIUM pmedium, LPOLESTREAM polestm);
|
---|
| 143 | WINOLEAPI OleConvertOLESTREAMToIStorageEx (LPOLESTREAM polestm, LPSTORAGE pstg, CLIPFORMAT *pcfFormat, LONG *plwWidth, LONG *plHeight, DWORD *pdwSize, LPSTGMEDIUM pmedium);
|
---|
| 144 | #endif
|
---|
| 145 |
|
---|
| 146 | #include <poppack.h>
|
---|
| 147 | #endif
|
---|