Annotation of mstools/ole20/h/olestd.h, revision 1.1

1.1     ! root        1: /*************************************************************************
        !             2: **
        !             3: **    OLE 2.0 Standard Utilities
        !             4: **
        !             5: **    olestd.h
        !             6: **
        !             7: **    This file contains file contains data structure defintions,
        !             8: **    function prototypes, constants, etc. for the common OLE 2.0
        !             9: **    utilities.
        !            10: **    These utilities include the following:
        !            11: **          Debuging Assert/Verify macros
        !            12: **          HIMETRIC conversion routines
        !            13: **          reference counting debug support
        !            14: **          OleStd API's for common compound-document app support
        !            15: **
        !            16: **    (c) Copyright Microsoft Corp. 1990 - 1992 All Rights Reserved
        !            17: **
        !            18: *************************************************************************/
        !            19: 
        !            20: #if !defined( _OLESTD_H_ )
        !            21: #define _OLESTD_H_
        !            22: 
        !            23: #ifndef RC_INVOKED
        !            24: #pragma message ("INCLUDING OLESTD.H from " __FILE__)
        !            25: #endif  /* RC_INVOKED */
        !            26: 
        !            27: #if defined( __TURBOC__ ) || defined( WIN32 )
        !            28: #define _based(a)
        !            29: #endif
        !            30: 
        !            31: #ifndef RC_INVOKED
        !            32: #include <dos.h>        // needed for filetime
        !            33: #endif  /* RC_INVOKED */
        !            34: 
        !            35: #include <commdlg.h>    // needed for LPPRINTDLG
        !            36: 
        !            37: // String table defines...
        !            38: #define  IDS_OLESTDNOCREATEFILE   700
        !            39: #define  IDS_OLESTDNOOPENFILE     701
        !            40: #define  IDS_OLESTDDISKFULL       702
        !            41: 
        !            42: 
        !            43: /*
        !            44:  * Some C interface declaration stuff
        !            45:  */
        !            46: 
        !            47: #if ! defined(__cplusplus)
        !            48: typedef struct tagINTERFACEIMPL {
        !            49:         IUnknownVtbl FAR*       lpVtbl;
        !            50:         LPVOID                  lpBack;
        !            51:         int                     cRef;   // interface specific ref count.
        !            52: } INTERFACEIMPL, FAR* LPINTERFACEIMPL;
        !            53: 
        !            54: #define INIT_INTERFACEIMPL(lpIFace, pVtbl, pBack)   \
        !            55:         ((lpIFace)->lpVtbl = pVtbl, \
        !            56:             ((LPINTERFACEIMPL)(lpIFace))->lpBack = (LPVOID)pBack,   \
        !            57:             ((LPINTERFACEIMPL)(lpIFace))->cRef = 0  \
        !            58:         )
        !            59: 
        !            60: #if defined( _DEBUG )
        !            61: #define OleDbgQueryInterfaceMethod(lpUnk)   \
        !            62:         ((lpUnk) != NULL ? ((LPINTERFACEIMPL)(lpUnk))->cRef++ : 0)
        !            63: #define OleDbgAddRefMethod(lpThis, iface)   \
        !            64:         ((LPINTERFACEIMPL)(lpThis))->cRef++
        !            65: 
        !            66: #if _DEBUGLEVEL >= 2
        !            67: #define OleDbgReleaseMethod(lpThis, iface) \
        !            68:         (--((LPINTERFACEIMPL)(lpThis))->cRef == 0 ? \
        !            69:             OleDbgOut("\t" iface "* RELEASED (cRef == 0)\r\n"),1 : \
        !            70:              (((LPINTERFACEIMPL)(lpThis))->cRef < 0) ? \
        !            71:                 ( \
        !            72:                     DebugBreak(), \
        !            73:                     OleDbgOut(  \
        !            74:                         "\tERROR: " iface "* RELEASED TOO MANY TIMES\r\n") \
        !            75:                 ),1 : \
        !            76:                 1)
        !            77: 
        !            78: #else       // if _DEBUGLEVEL < 2
        !            79: #define OleDbgReleaseMethod(lpThis, iface) \
        !            80:         (--((LPINTERFACEIMPL)(lpThis))->cRef == 0 ? \
        !            81:             1 : \
        !            82:              (((LPINTERFACEIMPL)(lpThis))->cRef < 0) ? \
        !            83:                 ( \
        !            84:                     OleDbgOut(  \
        !            85:                         "\tERROR: " iface "* RELEASED TOO MANY TIMES\r\n") \
        !            86:         ),1 : \
        !            87:                 1)
        !            88: 
        !            89: #endif      // if _DEBUGLEVEL < 2
        !            90: 
        !            91: #else       // ! defined (_DEBUG)
        !            92: 
        !            93: #define OleDbgQueryInterfaceMethod(lpUnk)
        !            94: #define OleDbgAddRefMethod(lpThis, iface)
        !            95: #define OleDbgReleaseMethod(lpThis, iface)
        !            96: 
        !            97: #endif      // if defined( _DEBUG )
        !            98: 
        !            99: #endif      // ! defined(__cplusplus)
        !           100: 
        !           101: /*
        !           102:  * Some docfiles stuff
        !           103:  */
        !           104: 
        !           105: #define STGM_DFRALL (STGM_READWRITE | STGM_TRANSACTED | STGM_SHARE_DENY_WRITE)
        !           106: #define STGM_DFALL (STGM_READWRITE | STGM_TRANSACTED | STGM_SHARE_EXCLUSIVE)
        !           107: #define STGM_SALL (STGM_READWRITE | STGM_SHARE_EXCLUSIVE)
        !           108: 
        !           109: /*
        !           110:  * Some moniker stuff
        !           111:  */
        !           112: 
        !           113: // Delimeter used to separate ItemMoniker pieces of a composite moniker
        !           114: #if defined( _MAC )
        !           115: #define OLESTDDELIM ":"
        !           116: #else
        !           117: #define OLESTDDELIM "\\"
        !           118: #endif
        !           119: 
        !           120: /*
        !           121:  * Some Concurrency stuff
        !           122:  */
        !           123: 
        !           124: /* standard Delay (in msec) to wait before retrying an LRPC call.
        !           125: **    this value is returned from IMessageFilter::RetryRejectedCall
        !           126: */
        !           127: #define OLESTDRETRYDELAY    (DWORD)5000
        !           128: 
        !           129: /* Cancel the pending outgoing LRPC call.
        !           130: **    this value is returned from IMessageFilter::RetryRejectedCall
        !           131: */
        !           132: #define OLESTDCANCELRETRY   (DWORD)-1
        !           133: 
        !           134: /*
        !           135:  * Some Clipboard Copy/Paste & Drag/Drop support stuff
        !           136:  */
        !           137: 
        !           138: //Macro to set all FormatEtc fields
        !           139: #define SETFORMATETC(fe, cf, asp, td, med, li)   \
        !           140:     ((fe).cfFormat=cf, \
        !           141:      (fe).dwAspect=asp, \
        !           142:      (fe).ptd=td, \
        !           143:      (fe).tymed=med, \
        !           144:      (fe).lindex=li)
        !           145: 
        !           146: //Macro to set interesting FormatEtc fields defaulting the others.
        !           147: #define SETDEFAULTFORMATETC(fe, cf, med)  \
        !           148:     ((fe).cfFormat=cf, \
        !           149:      (fe).dwAspect=DVASPECT_CONTENT, \
        !           150:      (fe).ptd=NULL, \
        !           151:      (fe).tymed=med, \
        !           152:      (fe).lindex=-1)
        !           153: 
        !           154: // Macro to test if two FormatEtc structures match
        !           155: #define IsEqualFORMATETC(fe1, fe2)  \
        !           156:     ((fe1).cfFormat == (fe2).cfFormat \
        !           157:      && ((fe1).tymed & (fe2).tymed) \
        !           158:      && (!(fe1).dwAspect||!(fe2).dwAspect||((fe1).dwAspect&(fe2).dwAspect)) \
        !           159:      && (fe1).ptd == (fe2).ptd)
        !           160: 
        !           161: // Clipboard format strings
        !           162: #define CF_EMBEDSOURCE      "Embed Source"
        !           163: #define CF_EMBEDDEDOBJECT   "Embedded Object"
        !           164: #define CF_LINKSOURCE       "Link Source"
        !           165: #define CF_OBJECTDESCRIPTOR "Object Descriptor"
        !           166: #define CF_LINKSRCDESCRIPTOR "Link Source Descriptor"
        !           167: #define CF_OWNERLINK        "OwnerLink"
        !           168: #define CF_FILENAME         "FileName"
        !           169: 
        !           170: /* The OLEUIPASTEFLAG enumeration is used by the OLEUIPASTEENTRY structure.
        !           171:  *
        !           172:  * OLEUIPASTE_ENABLEICON    If the container does not specify this flag for the entry in the
        !           173:  *   OLEUIPASTEENTRY array passed as input to OleUIPasteSpecial, the DisplayAsIcon button will be
        !           174:  *   unchecked and disabled when the the user selects the format that corresponds to the entry.
        !           175:  *
        !           176:  * OLEUIPASTE_PASTEONLY     Indicates that the entry in the OLEUIPASTEENTRY array is valid for pasting only.
        !           177:  * OLEUIPASTE_PASTE         Indicates that the entry in the OLEUIPASTEENTRY array is valid for pasting. It
        !           178:  *   may also be valid for linking if any of the following linking flags are specified.
        !           179:  *
        !           180:  * If the entry in the OLEUIPASTEENTRY array is valid for linking, the following flags indicate which link
        !           181:  * types are acceptable by OR'ing together the appropriate OLEUIPASTE_LINKTYPE<#> values.
        !           182:  * These values correspond as follows to the array of link types passed to OleUIPasteSpecial:
        !           183:  *   OLEUIPASTE_LINKTYPE1=arrLinkTypes[0]
        !           184:  *   OLEUIPASTE_LINKTYPE2=arrLinkTypes[1]
        !           185:  *   OLEUIPASTE_LINKTYPE3=arrLinkTypes[2]
        !           186:  *   OLEUIPASTE_LINKTYPE4=arrLinkTypes[3]
        !           187:  *   OLEUIPASTE_LINKTYPE5=arrLinkTypes[4]
        !           188:  *   OLEUIPASTE_LINKTYPE6=arrLinkTypes[5]
        !           189:  *   OLEUIPASTE_LINKTYPE7=arrLinkTypes[6]
        !           190:  *  OLEUIPASTE_LINKTYPE8=arrLinkTypes[7]
        !           191:  *
        !           192:  * where,
        !           193:  *   UINT arrLinkTypes[8] is an array of registered clipboard formats for linking. A maximium of 8 link
        !           194:  *   types are allowed.
        !           195:  */
        !           196: 
        !           197: typedef enum tagOLEUIPASTEFLAG
        !           198: {
        !           199:    OLEUIPASTE_ENABLEICON    = 2048,     // enable display as icon
        !           200:    OLEUIPASTE_PASTEONLY     = 0,
        !           201:    OLEUIPASTE_PASTE         = 512,
        !           202:    OLEUIPASTE_LINKANYTYPE   = 1024,
        !           203:    OLEUIPASTE_LINKTYPE1     = 1,
        !           204:    OLEUIPASTE_LINKTYPE2     = 2,
        !           205:    OLEUIPASTE_LINKTYPE3     = 4,
        !           206:    OLEUIPASTE_LINKTYPE4     = 8,
        !           207:    OLEUIPASTE_LINKTYPE5     = 16,
        !           208:    OLEUIPASTE_LINKTYPE6     = 32,
        !           209:    OLEUIPASTE_LINKTYPE7     = 64,
        !           210:    OLEUIPASTE_LINKTYPE8     = 128
        !           211: } OLEUIPASTEFLAG;
        !           212: 
        !           213: /*
        !           214:  * PasteEntry structure
        !           215:  * --------------------
        !           216:  * An array of OLEUIPASTEENTRY entries is specified for the PasteSpecial dialog
        !           217:  * box. Each entry includes a FORMATETC which specifies the formats that are
        !           218:  * acceptable, a string that is to represent the format in the  dialog's list
        !           219:  * box, a string to customize the result text of the dialog and a set of flags
        !           220:  * from the OLEUIPASTEFLAG enumeration.  The flags indicate if the entry is
        !           221:  * valid for pasting only, linking only or both pasting and linking. If the
        !           222:  * entry is valid for linking, the flags indicate which link types are
        !           223:  * acceptable by OR'ing together the appropriate OLEUIPASTE_LINKTYPE<#> values.
        !           224:  * These values correspond to the array of link types as follows:
        !           225:  *   OLEUIPASTE_LINKTYPE1=arrLinkTypes[0]
        !           226:  *   OLEUIPASTE_LINKTYPE2=arrLinkTypes[1]
        !           227:  *   OLEUIPASTE_LINKTYPE3=arrLinkTypes[2]
        !           228:  *   OLEUIPASTE_LINKTYPE4=arrLinkTypes[3]
        !           229:  *   OLEUIPASTE_LINKTYPE5=arrLinkTypes[4]
        !           230:  *   OLEUIPASTE_LINKTYPE6=arrLinkTypes[5]
        !           231:  *   OLEUIPASTE_LINKTYPE7=arrLinkTypes[6]
        !           232:  *   OLEUIPASTE_LINKTYPE8=arrLinkTypes[7]
        !           233:  *   UINT arrLinkTypes[8]; is an array of registered clipboard formats
        !           234:  *                        for linking. A maximium of 8 link types are allowed.
        !           235:  */
        !           236: 
        !           237: typedef struct tagOLEUIPASTEENTRY
        !           238: {
        !           239:    FORMATETC        fmtetc;            // Format that is acceptable. The paste
        !           240:                                        //   dialog checks if this format is
        !           241:                                        //   offered by the object on the
        !           242:                                        //   clipboard and if so offers it for
        !           243:                                        //   selection to the user.
        !           244:    LPCSTR           lpstrFormatName;   // String that represents the format to the user. Any %s
        !           245:                                        //   in this string is replaced by the FullUserTypeName
        !           246:                                        //   of the object on the clipboard and the resulting string
        !           247:                                        //   is placed in the list box of the dialog. Atmost
        !           248:                                        //   one %s is allowed. The presence or absence of %s indicates
        !           249:                                        //   if the result text is to indicate that data is
        !           250:                                        //   being pasted or that an object that can be activated by
        !           251:                                        //   an application is being pasted. If %s is
        !           252:                                        //   present, the result-text says that an object is being pasted.
        !           253:                                        //   Otherwise it says that data is being pasted.
        !           254:    LPCSTR           lpstrResultText;   // String to customize the result text of the dialog when
        !           255:                                        //  the user selects the format correspoding to this
        !           256:                                        //  entry. Any %s in this string is replaced by the the application
        !           257:                                        //  name or FullUserTypeName of the object on
        !           258:                                        //  the clipboard. Atmost one %s is allowed.
        !           259:    DWORD            dwFlags;           // Values from OLEUIPASTEFLAG enum
        !           260:    DWORD            dwScratchSpace;    // Scratch space available to be used
        !           261:                                        //   by routines which loop through an
        !           262:                                        //   IEnumFORMATETC* to mark if the
        !           263:                                        //   PasteEntry format is available.
        !           264:                                        //   this field CAN be left uninitialized.
        !           265: } OLEUIPASTEENTRY, *POLEUIPASTEENTRY, FAR *LPOLEUIPASTEENTRY;
        !           266: 
        !           267: #define OLESTDDROP_NONE         0
        !           268: #define OLESTDDROP_DEFAULT      1
        !           269: #define OLESTDDROP_NONDEFAULT   2
        !           270: 
        !           271: 
        !           272: /*
        !           273:  * Some misc stuff
        !           274:  */
        !           275: 
        !           276: #define EMBEDDINGFLAG "Embedding"     // Cmd line switch for launching a srvr
        !           277: 
        !           278: #define HIMETRIC_PER_INCH   2540      // number HIMETRIC units per inch
        !           279: #define PTS_PER_INCH        72        // number points (font size) per inch
        !           280: 
        !           281: #define MAP_PIX_TO_LOGHIM(x,ppli)   MulDiv(HIMETRIC_PER_INCH, (x), (ppli))
        !           282: #define MAP_LOGHIM_TO_PIX(x,ppli)   MulDiv((ppli), (x), HIMETRIC_PER_INCH)
        !           283: 
        !           284: 
        !           285: /****** DEBUG Stuff *****************************************************/
        !           286: 
        !           287: #ifdef _DEBUG
        !           288: 
        !           289: #if !defined( _DBGTRACE )
        !           290: #define _DEBUGLEVEL 2
        !           291: #else
        !           292: #define _DEBUGLEVEL _DBGTRACE
        !           293: #endif
        !           294: 
        !           295: #if defined( NOASSERT )
        !           296: 
        !           297: #define OLEDBGASSERTDATA
        !           298: #define OleDbgAssert(a)
        !           299: #define OleDbgAssertSz(a, b)
        !           300: #define OleDbgVerify(a)
        !           301: #define OleDbgVerifySz(a, b)
        !           302: 
        !           303: #else   // ! NOASSERT
        !           304: 
        !           305: #define OLEDBGASSERTDATA    \
        !           306:         static char _based(_segname("_CODE")) _szAssertFile[]= __FILE__;
        !           307: 
        !           308: #define OleDbgAssert(a) \
        !           309:         (!(a) ? FnAssert(#a, NULL, _szAssertFile, __LINE__) : (HRESULT)1)
        !           310: 
        !           311: #define OleDbgAssertSz(a, b)    \
        !           312:         (!(a) ? FnAssert(#a, b, _szAssertFile, __LINE__) : (HRESULT)1)
        !           313: 
        !           314: #define OleDbgVerify(a) \
        !           315:         OleDbgAssert(a)
        !           316: 
        !           317: #define OleDbgVerifySz(a, b)    \
        !           318:         OleDbgAssertSz(a, b)
        !           319: 
        !           320: #endif  // ! NOASSERT
        !           321: 
        !           322: 
        !           323: #define OLEDBGDATA_MAIN(szPrefix)   \
        !           324:         char near g_szDbgPrefix[] = szPrefix;    \
        !           325:         OLEDBGASSERTDATA
        !           326: 
        !           327: #define OLEDBGDATA  \
        !           328:         extern char near g_szDbgPrefix[];    \
        !           329:         OLEDBGASSERTDATA
        !           330: 
        !           331: #define OLEDBG_BEGIN(lpsz) \
        !           332:         OleDbgPrintAlways(g_szDbgPrefix,lpsz,1);
        !           333: 
        !           334: #define OLEDBG_END  \
        !           335:         OleDbgPrintAlways(g_szDbgPrefix,"End\r\n",-1);
        !           336: 
        !           337: #define OleDbgOut(lpsz) \
        !           338:         OleDbgPrintAlways(g_szDbgPrefix,lpsz,0)
        !           339: 
        !           340: #define OleDbgOutNoPrefix(lpsz) \
        !           341:         OleDbgPrint("",lpsz,0)
        !           342: 
        !           343: #define OleDbgOutRefCnt(lpsz,lpObj,refcnt)      \
        !           344:         OleDbgPrintRefCntAlways(g_szDbgPrefix,lpsz,lpObj,(ULONG)refcnt)
        !           345: 
        !           346: #define OleDbgOutRect(lpsz,lpRect)      \
        !           347:         OleDbgPrintRectAlways(g_szDbgPrefix,lpsz,lpRect)
        !           348: 
        !           349: #define OleDbgOutHResult(lpsz,hr)   \
        !           350:         OleDbgPrintScodeAlways(g_szDbgPrefix,lpsz,GetScode(hr))
        !           351: 
        !           352: #define OleDbgOutScode(lpsz,sc) \
        !           353:         OleDbgPrintScodeAlways(g_szDbgPrefix,lpsz,sc)
        !           354: 
        !           355: #define OleDbgOut1(lpsz)    \
        !           356:         OleDbgPrint(1,g_szDbgPrefix,lpsz,0)
        !           357: 
        !           358: #define OleDbgOutNoPrefix1(lpsz)    \
        !           359:         OleDbgPrint(1,"",lpsz,0)
        !           360: 
        !           361: #define OLEDBG_BEGIN1(lpsz)    \
        !           362:         OleDbgPrint(1,g_szDbgPrefix,lpsz,1);
        !           363: 
        !           364: #define OLEDBG_END1 \
        !           365:         OleDbgPrint(1,g_szDbgPrefix,"End\r\n",-1);
        !           366: 
        !           367: #define OleDbgOutRefCnt1(lpsz,lpObj,refcnt)     \
        !           368:         OleDbgPrintRefCnt(1,g_szDbgPrefix,lpsz,lpObj,(ULONG)refcnt)
        !           369: 
        !           370: #define OleDbgOutRect1(lpsz,lpRect)     \
        !           371:         OleDbgPrintRect(1,g_szDbgPrefix,lpsz,lpRect)
        !           372: 
        !           373: #define OleDbgOut2(lpsz)    \
        !           374:         OleDbgPrint(2,g_szDbgPrefix,lpsz,0)
        !           375: 
        !           376: #define OleDbgOutNoPrefix2(lpsz)    \
        !           377:         OleDbgPrint(2,"",lpsz,0)
        !           378: 
        !           379: #define OLEDBG_BEGIN2(lpsz)    \
        !           380:         OleDbgPrint(2,g_szDbgPrefix,lpsz,1);
        !           381: 
        !           382: #define OLEDBG_END2 \
        !           383:         OleDbgPrint(2,g_szDbgPrefix,"End\r\n",-1);
        !           384: 
        !           385: #define OleDbgOutRefCnt2(lpsz,lpObj,refcnt)     \
        !           386:         OleDbgPrintRefCnt(2,g_szDbgPrefix,lpsz,lpObj,(ULONG)refcnt)
        !           387: 
        !           388: #define OleDbgOutRect2(lpsz,lpRect)     \
        !           389:         OleDbgPrintRect(2,g_szDbgPrefix,lpsz,lpRect)
        !           390: 
        !           391: #define OleDbgOut3(lpsz)    \
        !           392:         OleDbgPrint(3,g_szDbgPrefix,lpsz,0)
        !           393: 
        !           394: #define OleDbgOutNoPrefix3(lpsz)    \
        !           395:         OleDbgPrint(3,"",lpsz,0)
        !           396: 
        !           397: #define OLEDBG_BEGIN3(lpsz)    \
        !           398:         OleDbgPrint(3,g_szDbgPrefix,lpsz,1);
        !           399: 
        !           400: #define OLEDBG_END3 \
        !           401:         OleDbgPrint(3,g_szDbgPrefix,"End\r\n",-1);
        !           402: 
        !           403: #define OleDbgOutRefCnt3(lpsz,lpObj,refcnt)     \
        !           404:         OleDbgPrintRefCnt(3,g_szDbgPrefix,lpsz,lpObj,(ULONG)refcnt)
        !           405: 
        !           406: #define OleDbgOutRect3(lpsz,lpRect)     \
        !           407:         OleDbgPrintRect(3,g_szDbgPrefix,lpsz,lpRect)
        !           408: 
        !           409: #define OleDbgOut4(lpsz)    \
        !           410:         OleDbgPrint(4,g_szDbgPrefix,lpsz,0)
        !           411: 
        !           412: #define OleDbgOutNoPrefix4(lpsz)    \
        !           413:         OleDbgPrint(4,"",lpsz,0)
        !           414: 
        !           415: #define OLEDBG_BEGIN4(lpsz)    \
        !           416:         OleDbgPrint(4,g_szDbgPrefix,lpsz,1);
        !           417: 
        !           418: #define OLEDBG_END4 \
        !           419:         OleDbgPrint(4,g_szDbgPrefix,"End\r\n",-1);
        !           420: 
        !           421: #define OleDbgOutRefCnt4(lpsz,lpObj,refcnt)     \
        !           422:         OleDbgPrintRefCnt(4,g_szDbgPrefix,lpsz,lpObj,(ULONG)refcnt)
        !           423: 
        !           424: #define OleDbgOutRect4(lpsz,lpRect)     \
        !           425:         OleDbgPrintRect(4,g_szDbgPrefix,lpsz,lpRect)
        !           426: 
        !           427: #else   //  !_DEBUG
        !           428: 
        !           429: #define OLEDBGDATA_MAIN(szPrefix)
        !           430: #define OLEDBGDATA
        !           431: #define OleDbgAssert(a)
        !           432: #define OleDbgAssertSz(a, b)
        !           433: #define OleDbgVerify(a)         (a)
        !           434: #define OleDbgVerifySz(a, b)    (a)
        !           435: #define OleDbgOutHResult(lpsz,hr)
        !           436: #define OleDbgOutScode(lpsz,sc)
        !           437: #define OLEDBG_BEGIN
        !           438: #define OLEDBG_END
        !           439: #define OleDbgOut(lpsz)
        !           440: #define OleDbgOut1(lpsz)
        !           441: #define OleDbgOut2(lpsz)
        !           442: #define OleDbgOut3(lpsz)
        !           443: #define OleDbgOut4(lpsz)
        !           444: #define OleDbgOutNoPrefix(lpsz)
        !           445: #define OleDbgOutNoPrefix1(lpsz)
        !           446: #define OleDbgOutNoPrefix2(lpsz)
        !           447: #define OleDbgOutNoPrefix3(lpsz)
        !           448: #define OleDbgOutNoPrefix4(lpsz)
        !           449: #define OLEDBG_BEGIN1(lpsz)
        !           450: #define OLEDBG_BEGIN2(lpsz)
        !           451: #define OLEDBG_BEGIN3(lpsz)
        !           452: #define OLEDBG_BEGIN4(lpsz)
        !           453: #define OLEDBG_END1
        !           454: #define OLEDBG_END2
        !           455: #define OLEDBG_END3
        !           456: #define OLEDBG_END4
        !           457: #define OleDbgOutRefCnt(lpsz,lpObj,refcnt)
        !           458: #define OleDbgOutRefCnt1(lpsz,lpObj,refcnt)
        !           459: #define OleDbgOutRefCnt2(lpsz,lpObj,refcnt)
        !           460: #define OleDbgOutRefCnt3(lpsz,lpObj,refcnt)
        !           461: #define OleDbgOutRefCnt4(lpsz,lpObj,refcnt)
        !           462: #define OleDbgOutRect(lpsz,lpRect)
        !           463: #define OleDbgOutRect1(lpsz,lpRect)
        !           464: #define OleDbgOutRect2(lpsz,lpRect)
        !           465: #define OleDbgOutRect3(lpsz,lpRect)
        !           466: #define OleDbgOutRect4(lpsz,lpRect)
        !           467: 
        !           468: #endif  //  _DEBUG
        !           469: 
        !           470: 
        !           471: //Function prototypes
        !           472: 
        !           473: //OLESTD.C
        !           474: STDAPI_(int) SetDCToAnisotropic(HDC hDC, LPRECT lprcPhysical, LPRECT lprcLogical, LPRECT lprcWindowOld, LPRECT lprcViewportOld);
        !           475: STDAPI_(int) SetDCToDrawInHimetricRect(HDC, LPRECT, LPRECT, LPRECT, LPRECT);
        !           476: STDAPI_(int) ResetOrigDC(HDC, int, LPRECT, LPRECT);
        !           477: 
        !           478: STDAPI_(void) XformRectInPixelsToHimetric(HDC, LPRECT, LPRECT);
        !           479: STDAPI_(void) XformRectInHimetricToPixels(HDC, LPRECT, LPRECT);
        !           480: STDAPI_(void) XformSizeInPixelsToHimetric(HDC, LPSIZEL, LPSIZEL);
        !           481: STDAPI_(void) XformSizeInHimetricToPixels(HDC, LPSIZEL, LPSIZEL);
        !           482: STDAPI_(int) XformWidthInHimetricToPixels(HDC, int);
        !           483: STDAPI_(int) XformWidthInPixelsToHimetric(HDC, int);
        !           484: STDAPI_(int) XformHeightInHimetricToPixels(HDC, int);
        !           485: STDAPI_(int) XformHeightInPixelsToHimetric(HDC, int);
        !           486: STDAPI_(BOOL) AreRectsEqual(LPRECT lprc1, LPRECT lprc2);
        !           487: 
        !           488: 
        !           489: STDAPI_(void) ParseCmdLine(LPSTR, BOOL FAR *, LPSTR);
        !           490: 
        !           491: STDAPI_(BOOL) OleStdIsOleLink(LPUNKNOWN lpUnk);
        !           492: STDAPI_(LPUNKNOWN) OleStdQueryInterface(LPUNKNOWN lpUnk, REFIID riid);
        !           493: STDAPI_(LPSTORAGE) OleStdCreateRootStorage(LPSTR lpszStgName, DWORD grfMode);
        !           494: STDAPI_(LPSTORAGE) OleStdOpenRootStorage(LPSTR lpszStgName, DWORD grfMode);
        !           495: STDAPI_(LPSTORAGE) OleStdOpenOrCreateRootStorage(LPSTR lpszStgName, DWORD grfMode);
        !           496: STDAPI_(LPSTORAGE) OleStdCreateChildStorage(LPSTORAGE lpStg, LPSTR lpszStgName);
        !           497: STDAPI_(LPSTORAGE) OleStdOpenChildStorage(LPSTORAGE lpStg, LPSTR lpszStgName, DWORD grfMode);
        !           498: STDAPI_(BOOL) OleStdCommitStorage(LPSTORAGE lpStg);
        !           499: 
        !           500: STDAPI_(LPSTORAGE) OleStdCreateStorageOnHGlobal(
        !           501:         HANDLE hGlobal,
        !           502:         BOOL fDeleteOnRelease,
        !           503:         DWORD dwgrfMode
        !           504: );
        !           505: STDAPI_(LPSTORAGE) OleStdCreateTempStorage(BOOL fUseMemory, DWORD grfMode);
        !           506: STDAPI OleStdDoConvert(LPSTORAGE lpStg, REFCLSID rClsidNew);
        !           507: STDAPI_(BOOL) OleStdGetTreatAsFmtUserType(
        !           508:         REFCLSID        rClsidApp,
        !           509:         LPSTORAGE       lpStg,
        !           510:         CLSID FAR*      lpclsid,
        !           511:         CLIPFORMAT FAR* lpcfFmt,
        !           512:         LPSTR FAR*      lplpszType
        !           513: );
        !           514: STDAPI OleStdDoTreatAsClass(LPSTR lpszUserType, REFCLSID rclsid, REFCLSID rclsidNew);
        !           515: STDAPI_(BOOL) OleStdSetupAdvises(LPOLEOBJECT lpOleObject, DWORD dwDrawAspect,
        !           516:                     LPSTR lpszContainerApp, LPSTR lpszContainerObj,
        !           517:                     LPADVISESINK lpAdviseSink);
        !           518: STDAPI OleStdSwitchDisplayAspect(
        !           519:         LPOLEOBJECT             lpOleObj,
        !           520:         LPDWORD                 lpdwCurAspect,
        !           521:         DWORD                   dwNewAspect,
        !           522:         HGLOBAL                 hMetaPict,
        !           523:         BOOL                    fDeleteOldAspect,
        !           524:         BOOL                    fSetupViewAdvise,
        !           525:         LPADVISESINK            lpAdviseSink,
        !           526:         BOOL FAR*               lpfMustUpdate
        !           527: );
        !           528: STDAPI OleStdSetIconInCache(LPOLEOBJECT lpOleObj, HGLOBAL hMetaPict);
        !           529: STDAPI_(HGLOBAL) OleStdGetData(
        !           530:         LPDATAOBJECT        lpDataObj,
        !           531:         CLIPFORMAT          cfFormat,
        !           532:         DVTARGETDEVICE FAR* lpTargetDevice,
        !           533:         DWORD               dwAspect,
        !           534:         LPSTGMEDIUM         lpMedium
        !           535: );
        !           536: STDAPI_(void) OleStdMarkPasteEntryList(
        !           537:         LPDATAOBJECT        lpSrcDataObj,
        !           538:         LPOLEUIPASTEENTRY   lpPriorityList,
        !           539:         int                 cEntries
        !           540: );
        !           541: STDAPI_(int) OleStdGetPriorityClipboardFormat(
        !           542:         LPDATAOBJECT        lpSrcDataObj,
        !           543:         LPOLEUIPASTEENTRY   lpPriorityList,
        !           544:         int                 cEntries
        !           545: );
        !           546: STDAPI_(BOOL) OleStdIsDuplicateFormat(
        !           547:         LPFORMATETC         lpFmtEtc,
        !           548:         LPFORMATETC         arrFmtEtc,
        !           549:         int                 nFmtEtc
        !           550: );
        !           551: STDAPI_(void) OleStdRegisterAsRunning(LPUNKNOWN lpUnk, LPMONIKER lpmkFull, DWORD FAR* lpdwRegister);
        !           552: STDAPI_(void) OleStdRevokeAsRunning(DWORD FAR* lpdwRegister);
        !           553: STDAPI_(void) OleStdNoteFileChangeTime(LPSTR lpszFileName, DWORD dwRegister);
        !           554: STDAPI_(void) OleStdNoteObjectChangeTime(DWORD dwRegister);
        !           555: STDAPI OleStdGetOleObjectData(
        !           556:         LPPERSISTSTORAGE    lpPStg,
        !           557:         LPFORMATETC         lpformatetc,
        !           558:         LPSTGMEDIUM         lpMedium,
        !           559:         BOOL                fUseMemory
        !           560: );
        !           561: STDAPI OleStdGetLinkSourceData(
        !           562:         LPMONIKER           lpmk,
        !           563:         LPCLSID             lpClsID,
        !           564:         LPFORMATETC         lpformatetc,
        !           565:         LPSTGMEDIUM         lpMedium
        !           566: );
        !           567: STDAPI_(HGLOBAL) OleStdGetObjectDescriptorData(
        !           568:         CLSID               clsid,
        !           569:         DWORD               dwAspect,
        !           570:         SIZEL               sizel,
        !           571:         POINTL              pointl,
        !           572:         DWORD               dwStatus,
        !           573:         LPSTR               lpszFullUserTypeName,
        !           574:         LPSTR               lpszSrcOfCopy
        !           575: );
        !           576: STDAPI_(HGLOBAL) OleStdGetObjectDescriptorDataFromOleObject(
        !           577:         LPOLEOBJECT         lpOleObj,
        !           578:         LPSTR               lpszSrcOfCopy,
        !           579:         DWORD               dwAspect,
        !           580:         POINTL              pointl
        !           581: );
        !           582: STDAPI_(HGLOBAL) OleStdFillObjectDescriptorFromData(
        !           583:         LPDATAOBJECT       lpDataObject,
        !           584:         LPSTGMEDIUM        lpmedium,
        !           585:         CLIPFORMAT FAR*    lpcfFmt
        !           586: );
        !           587: STDAPI_(BOOL) OleStdCopyMetafilePict(HANDLE hpictin, HANDLE FAR* phpictout);
        !           588: STDAPI_(HANDLE) OleStdGetMetafilePictFromOleObject(
        !           589:         LPOLEOBJECT         lpOleObj,
        !           590:         DWORD               dwDrawAspect
        !           591: );
        !           592: STDAPI OleStdQueryOleObjectData(LPFORMATETC lpformatetc);
        !           593: STDAPI OleStdQueryLinkSourceData(LPFORMATETC lpformatetc);
        !           594: STDAPI OleStdQueryObjectDescriptorData(LPFORMATETC lpformatetc);
        !           595: STDAPI OleStdQueryFormatMedium(LPFORMATETC lpformatetc, TYMED tymed);
        !           596: STDAPI_(DWORD) OleStdGetDropEffect ( DWORD grfKeyState );
        !           597: STDAPI_(void) OleStdCreateTempFileMoniker(LPSTR lpszPrefixString, UINT FAR* lpuUnique, LPSTR lpszName, LPMONIKER FAR* lplpmk);
        !           598: STDAPI_(LPMONIKER) OleStdGetFirstMoniker(LPMONIKER lpmk);
        !           599: STDAPI_(ULONG) OleStdGetLenFilePrefixOfMoniker(LPMONIKER lpmk);
        !           600: STDAPI_(LPVOID) OleStdMalloc(ULONG ulSize);
        !           601: STDAPI_(LPVOID) OleStdRealloc(LPVOID pmem, ULONG ulSize);
        !           602: STDAPI_(void) OleStdFree(LPVOID pmem);
        !           603: STDAPI_(ULONG) OleStdGetSize(LPVOID pmem);
        !           604: STDAPI_(void) OleStdFreeString(LPSTR lpsz, LPMALLOC lpMalloc);
        !           605: STDAPI_(LPSTR) OleStdCopyString(LPSTR lpszSrc, LPMALLOC lpMalloc);
        !           606: STDAPI_(ULONG) OleStdGetItemToken(LPSTR lpszSrc, LPSTR lpszDst, int nMaxChars);
        !           607: 
        !           608: STDAPI_(void) OleStdInitVtbl(LPVOID lpVtbl, UINT nSizeOfVtbl);
        !           609: STDMETHODIMP OleStdNullMethod(LPUNKNOWN lpThis);
        !           610: STDAPI_(BOOL) OleStdCheckVtbl(LPVOID lpVtbl, UINT nSizeOfVtbl, LPSTR lpszIface);
        !           611: STDAPI_(ULONG) OleStdVerifyRelease(LPUNKNOWN lpUnk, LPSTR lpszMsg);
        !           612: STDAPI_(ULONG) OleStdRelease(LPUNKNOWN lpUnk);
        !           613: 
        !           614: STDAPI_(HDC) OleStdCreateDC(DVTARGETDEVICE FAR* ptd);
        !           615: STDAPI_(HDC) OleStdCreateIC(DVTARGETDEVICE FAR* ptd);
        !           616: STDAPI_(DVTARGETDEVICE FAR*) OleStdCreateTargetDevice(LPPRINTDLG lpPrintDlg);
        !           617: STDAPI_(BOOL) OleStdDeleteTargetDevice(DVTARGETDEVICE FAR* ptd);
        !           618: STDAPI_(DVTARGETDEVICE FAR*) OleStdCopyTargetDevice(DVTARGETDEVICE FAR* ptdSrc);
        !           619: STDAPI_(BOOL) OleStdCopyFormatEtc(LPFORMATETC petcDest, LPFORMATETC petcSrc);
        !           620: 
        !           621: 
        !           622: STDAPI_(void) OleDbgPrint(
        !           623:         int     nDbgLvl,
        !           624:         LPSTR   lpszPrefix,
        !           625:         LPSTR   lpszMsg,
        !           626:         int     nIndent
        !           627: );
        !           628: STDAPI_(void) OleDbgPrintAlways(LPSTR lpszPrefix, LPSTR lpszMsg, int nIndent);
        !           629: STDAPI_(void) OleDbgSetDbgLevel(int nDbgLvl);
        !           630: STDAPI_(int) OleDbgGetDbgLevel( void );
        !           631: STDAPI_(void) OleDbgIndent(int n);
        !           632: STDAPI_(void) OleDbgPrintRefCnt(
        !           633:         int         nDbgLvl,
        !           634:         LPSTR       lpszPrefix,
        !           635:         LPSTR       lpszMsg,
        !           636:         LPVOID      lpObj,
        !           637:         ULONG       refcnt
        !           638: );
        !           639: STDAPI_(void) OleDbgPrintRefCntAlways(
        !           640:         LPSTR       lpszPrefix,
        !           641:         LPSTR       lpszMsg,
        !           642:         LPVOID      lpObj,
        !           643:         ULONG       refcnt
        !           644: );
        !           645: STDAPI_(void) OleDbgPrintRect(
        !           646:         int         nDbgLvl,
        !           647:         LPSTR       lpszPrefix,
        !           648:         LPSTR       lpszMsg,
        !           649:         LPRECT      lpRect
        !           650: );
        !           651: STDAPI_(void) OleDbgPrintRectAlways(
        !           652:         LPSTR       lpszPrefix,
        !           653:         LPSTR       lpszMsg,
        !           654:         LPRECT      lpRect
        !           655: );
        !           656: STDAPI_(void) OleDbgPrintScodeAlways(LPSTR lpszPrefix, LPSTR lpszMsg, SCODE sc);
        !           657: 
        !           658: 
        !           659: #endif // _OLESTD_H_

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.