home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / borhead.zip / PMWP.H < prev    next >
C/C++ Source or Header  |  1994-11-09  |  6KB  |  192 lines

  1. /****************************** Module Header ******************************\
  2. *
  3. * Module Name: PMWP.H
  4. *
  5. * OS/2 Presentation Manager Workplace include file.
  6. *
  7. * Copyright (c) International Business Machines Corporation 1981, 1988-1992
  8. *
  9. * ===========================================================================
  10. *
  11. * The folowing symbols are used in this file for conditional sections.
  12. *
  13. *   #define:                To include:
  14. *
  15. *   INCL_WINWORKPLACE       All of Workplace Shell
  16. *   INCL_WPCLASS            Workplace object class API's
  17. *
  18. * ===========================================================================
  19. *
  20. * Comments at the end of each typedef line give the name tags used in
  21. * the assembler include version of this file.
  22. *
  23. * The assembler include version of this file excludes lines between NOINC
  24. * and INC comments.
  25. *
  26. \***************************************************************************/
  27.  
  28. #if defined(__IBMC__)
  29.    #pragma info( none )
  30.    #ifndef __CHKHDR__
  31.       #pragma info( none )
  32.    #endif
  33.    #pragma info( restore )
  34. #endif    /* __IBMC__ */
  35.  
  36. #ifdef __cplusplus
  37.       extern "C" {
  38. #endif
  39.  
  40. /* NOINC */
  41. #ifndef PMWP_INCLUDED  /* multiple include protection */
  42.    /* INC */
  43.    #define PMWP_INCLUDED
  44.  
  45.    #ifdef INCL_WINWORKPLACE
  46.       #define INCL_WPCLASS
  47.    #endif
  48.  
  49.    /*** Common types *******************************************************/
  50.  
  51.    typedef LHANDLE HOBJECT;
  52.  
  53.    /*** Object management calls ********************************************/
  54.    #if (defined(INCL_WPCLASS) || !defined(INCL_NOCOMMON))
  55.       /*** Standard object classes *****************************************/
  56.  
  57.  
  58.       #define CCHMAXCLASS              3      /* Length of a classname     */
  59.  
  60.       #define QC_First                 0      /* Codes for OA_QueryContent */
  61.       #define QC_Next                  1
  62.       #define QC_Last                  2
  63.  
  64.       /*** An object's appearance (icon or bitmap or outline) **************/
  65.  
  66.       typedef struct _OBJECTIMAGE     /* oimg */
  67.       {
  68.          HPOINTER hptrObject;
  69.       } OBJECTIMAGE;
  70.       typedef OBJECTIMAGE *POBJECTIMAGE;
  71.  
  72.       /*** Class info structure returned by WinEnumObjectClasses ***********/
  73.       typedef struct _OBJCLASS         /* ocls */
  74.       {
  75.          struct _OBJCLASS *pNext;         /* Null for the last structure.. */
  76.          PSZ               pszClassName;  /* Class name                    */
  77.          PSZ               pszModName;    /* Module name                   */
  78.       } OBJCLASS;
  79.       typedef OBJCLASS *POBJCLASS;
  80.  
  81.  
  82.       /*** Workplace object management functions ***************************/
  83.  
  84.       BOOL APIENTRY WinRegisterObjectClass(PCSZ pszClassName,
  85.                                            PCSZ pszModName);
  86.  
  87.       BOOL APIENTRY WinDeregisterObjectClass(PCSZ pszClassName);
  88.  
  89.       BOOL APIENTRY WinReplaceObjectClass(PCSZ pszOldClassName,
  90.                                           PCSZ pszNewClassName,
  91.                                           BOOL fReplace);
  92.  
  93.       BOOL APIENTRY WinEnumObjectClasses(POBJCLASS pObjClass,
  94.                                          PULONG pulSize);
  95.  
  96.       HOBJECT APIENTRY WinCreateObject(PCSZ pszClassName,
  97.                                        PCSZ pszTitle,
  98.                                        PCSZ pszSetupString,
  99.                                        PCSZ pszLocation,
  100.                                        ULONG ulFlags );
  101.       #define CO_FAILIFEXISTS     0
  102.       #define CO_REPLACEIFEXISTS  1
  103.       #define CO_UPDATEIFEXISTS   2
  104.  
  105.       BOOL APIENTRY WinSetObjectData(HOBJECT hObject,
  106.                                      PCSZ pszSetupString);
  107.  
  108.       BOOL APIENTRY WinDestroyObject(HOBJECT hObject);
  109.  
  110.       HOBJECT APIENTRY WinQueryObject(PCSZ pszObjectID);
  111.  
  112.    #endif  /*WPCLASS*/
  113.  
  114.    /*** Error codes ********************************************************/
  115.    #define INCL_WPERRORS
  116.    #include <pmerr.h>
  117.  
  118.    /*** Object settings notebook page insertion structure ******************/
  119.  
  120.    typedef struct _PAGEINFO     /* pginf */
  121.    {
  122.       ULONG   cb;
  123.       HWND    hwndPage;
  124.       PFNWP   pfnwp;
  125.       ULONG   resid;
  126.       PVOID   pCreateParams;
  127.       USHORT  dlgid;
  128.       USHORT  usPageStyleFlags;
  129.       USHORT  usPageInsertFlags;
  130.       USHORT  usSettingsFlags;
  131.       PSZ     pszName;
  132.       USHORT  idDefaultHelpPanel;
  133.       USHORT  usReserved2;
  134.       PSZ     pszHelpLibraryName;
  135.       PUSHORT pHelpSubtable;   /* PHELPSUBTABLE when PMHELP.H is included*/
  136.       HMODULE hmodHelpSubtable;
  137.       ULONG   ulPageInsertId;
  138.    } PAGEINFO;
  139.    typedef PAGEINFO *PPAGEINFO;
  140.  
  141.    #define  SETTINGS_PAGE_NUMBERS     0x01
  142.  
  143.    /*** Utility apis +******************************************************/
  144.  
  145.    #if (!defined(INCL_NOCOMMON))
  146.       typedef struct _ICONPOS     /* icp */
  147.       {
  148.          POINTL  ptlIcon;                    /* Location */
  149.          CHAR    szIdentity[1];              /* Object identity string */
  150.       } ICONPOS;
  151.       typedef ICONPOS *PICONPOS;
  152.  
  153.       /*********************************************************************/
  154.       #ifdef INCL_WINPOINTERS
  155.          BOOL APIENTRY WinSetFileIcon(PCSZ pszFileName,
  156.                                       PICONINFO pIcnInfo);
  157.       #endif
  158.       BOOL APIENTRY WinFreeFileIcon(HPOINTER hptr);
  159.  
  160.       HPOINTER APIENTRY WinLoadFileIcon(PCSZ pszFileName,
  161.                                         BOOL fPrivate);
  162.  
  163.       BOOL APIENTRY WinStoreWindowPos(PCSZ pszAppName,
  164.                                       PCSZ pszKeyName,
  165.                                       HWND hwnd);
  166.  
  167.       BOOL APIENTRY WinRestoreWindowPos(PCSZ pszAppName,
  168.                                         PCSZ pszKeyName,
  169.                                         HWND hwnd);
  170.  
  171.       BOOL APIENTRY WinShutdownSystem(HAB hab,
  172.                                       HMQ hmq);
  173.    #endif
  174.  
  175.    /* NOINC */
  176. #endif /* PMWP_INCLUDED */
  177. /* INC */
  178.  
  179. #ifdef __cplusplus
  180.         }
  181. #endif
  182.  
  183. #if defined(__IBMC__)
  184.    #pragma info( none )
  185.    #ifndef __CHKHDR__
  186.       #pragma info( restore )
  187.    #endif
  188.    #pragma info( restore )
  189. #endif    /* __IBMC__ */
  190.  
  191. /**************************** end of file **********************************/
  192.