home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / detk45he.zip / PMWP.H < prev    next >
C/C++ Source or Header  |  1999-04-30  |  11KB  |  318 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. /* NOINC */
  29. #if __IBMC__ || __IBMCPP__
  30.    #pragma info( none )
  31.    #ifndef __CHKHDR__
  32.       #pragma info( none )
  33.    #endif
  34.    #pragma info( restore )
  35. #endif
  36. #ifdef __cplusplus
  37.       extern "C" {
  38. #endif
  39. /* INC */
  40.  
  41. /* NOINC */
  42. #ifndef PMWP_INCLUDED  /* multiple include protection */
  43.    /* INC */
  44.    #define PMWP_INCLUDED
  45.    
  46.    #ifdef INCL_WINWORKPLACE
  47.       #define INCL_WPCLASS
  48.    #endif
  49.    
  50.    /*** Common types *******************************************************/
  51.    
  52.    typedef LHANDLE HOBJECT;
  53.    
  54.    /*** Object management calls ********************************************/
  55.    #if (defined(INCL_WPCLASS) || !defined(INCL_NOCOMMON))
  56.       /*** Standard object classes *****************************************/
  57.       
  58.       
  59.       #define CCHMAXCLASS              3      /* Length of a classname     */
  60.       
  61.       #define QC_First                 0      /* Codes for OA_QueryContent */
  62.       #define QC_Next                  1
  63.       #define QC_Last                  2
  64.       /* NOINC */
  65.       #define QC_FIRST              QC_First
  66.       #define QC_NEXT               QC_Next
  67.       #define QC_LAST               QC_Last
  68.       /* INC */
  69.       
  70.       #ifndef LOCATION_DESKTOP
  71.          #define LOCATION_DESKTOP ((PSZ)0xFFFF0001) /* Current Desktop             */
  72.          /* use instead of <WP_DESKTOP> */
  73.       #endif
  74.       
  75.       /*** An object's appearance (icon or bitmap or outline) **************/
  76.       
  77.       typedef struct _OBJECTIMAGE     /* oimg */
  78.       {
  79.          HPOINTER hptrObject;
  80.       } OBJECTIMAGE;
  81.       typedef OBJECTIMAGE *POBJECTIMAGE;
  82.       
  83.       /*** Class info structure returned by WinEnumObjectClasses ***********/
  84.       typedef struct _OBJCLASS         /* ocls */
  85.       {
  86.          struct _OBJCLASS *pNext;         /* Null for the last structure.. */
  87.          PSZ               pszClassName;  /* Class name                    */
  88.          PSZ               pszModName;    /* Module name                   */
  89.       } OBJCLASS;
  90.       typedef OBJCLASS *POBJCLASS;
  91.       
  92.       
  93.       /*** Workplace object management functions ***************************/
  94.       
  95. #ifdef __cplusplus
  96.       BOOL APIENTRY WinRegisterObjectClass(PCSZ  pszClassName,
  97.                                            PCSZ  pszModName);
  98. #else
  99.       BOOL APIENTRY WinRegisterObjectClass(PSZ pszClassName,
  100.                                            PSZ pszModName);
  101. #endif
  102.       
  103. #ifdef __cplusplus
  104.       BOOL APIENTRY WinDeregisterObjectClass(PCSZ  pszClassName);
  105. #else
  106.       BOOL APIENTRY WinDeregisterObjectClass(PSZ pszClassName);
  107. #endif
  108.       
  109. #ifdef __cplusplus
  110.       BOOL APIENTRY WinReplaceObjectClass(PCSZ  pszOldClassName,
  111.                                           PCSZ  pszNewClassName,
  112.                                           BOOL fReplace);
  113. #else
  114.       BOOL APIENTRY WinReplaceObjectClass(PSZ pszOldClassName,
  115.                                           PSZ pszNewClassName,
  116.                                           BOOL fReplace);
  117. #endif
  118.       
  119.       BOOL APIENTRY WinEnumObjectClasses(POBJCLASS pObjClass,
  120.                                          PULONG pulSize);
  121.       
  122. #ifdef __cplusplus
  123.       HOBJECT APIENTRY WinCreateObject(PCSZ  pszClassName,
  124.                                        PCSZ  pszTitle,
  125.                                        PCSZ  pszSetupString,
  126.                                        PCSZ  pszLocation,
  127.                                        ULONG ulFlags );
  128. #else
  129.       HOBJECT APIENTRY WinCreateObject(PSZ pszClassName,
  130.                                        PSZ pszTitle,
  131.                                        PSZ pszSetupString,
  132.                                        PSZ pszLocation,
  133.                                        ULONG ulFlags );
  134. #endif
  135.       #define CO_FAILIFEXISTS     0
  136.       #define CO_REPLACEIFEXISTS  1
  137.       #define CO_UPDATEIFEXISTS   2
  138.       
  139. #ifdef __cplusplus
  140.       BOOL APIENTRY WinSetObjectData(HOBJECT hObject,
  141.                                      PCSZ  pszSetupString);
  142. #else
  143.       BOOL APIENTRY WinSetObjectData(HOBJECT hObject,
  144.                                      PSZ pszSetupString);
  145. #endif
  146.       
  147.       BOOL APIENTRY WinDestroyObject(HOBJECT hObject);
  148.       
  149. #ifdef __cplusplus
  150.       HOBJECT APIENTRY WinQueryObject(PCSZ  pszObjectID);
  151. #else
  152.       HOBJECT APIENTRY WinQueryObject(PSZ pszObjectID);
  153. #endif
  154.       
  155.       BOOL APIENTRY WinSaveObject(HOBJECT hObject,
  156.                                   BOOL    fAsync);
  157.       
  158.       BOOL APIENTRY WinOpenObject(HOBJECT hObject,
  159.                                   ULONG   ulView,
  160.                                   BOOL    Flag);
  161.       
  162.       HOBJECT APIENTRY WinMoveObject(HOBJECT hObjectofObject,
  163.                                      HOBJECT hObjectofDest,
  164.                                      ULONG   ulReserved);
  165.       
  166.       HOBJECT APIENTRY WinCopyObject(HOBJECT hObjectofObject,
  167.                                      HOBJECT hObjectofDest,
  168.                                      ULONG   ulReserved);
  169.       
  170.       HOBJECT APIENTRY WinCreateShadow(HOBJECT hObjectofObject,
  171.                                        HOBJECT hObjectofDest,
  172.                                        ULONG   ulReserved);
  173. #ifdef __cplusplus
  174.       BOOL APIENTRY WinQueryActiveDesktopPathname(PCSZ  pszPathName,
  175.                                                   ULONG ulSize);
  176. #else
  177.       BOOL APIENTRY WinQueryActiveDesktopPathname(PSZ pszPathName,
  178.                                                   ULONG ulSize);
  179. #endif
  180. #ifdef __cplusplus
  181.       BOOL APIENTRY WinQueryObjectPath(HOBJECT hobject,
  182.                                        PCSZ  pszPathName,
  183.                                        ULONG ulSize);
  184. #else
  185.       BOOL APIENTRY WinQueryObjectPath(HOBJECT hobject,
  186.                                        PSZ pszPathName,
  187.                                        ULONG ulSize);
  188. #endif
  189.       
  190.       APIRET  APIENTRY WinRestartWPDServer( BOOL fState );
  191.       BOOL    APIENTRY WinIsWPDServerReady( VOID );
  192.       APIRET  APIENTRY WinRestartSOMDD( BOOL fState );
  193.       BOOL    APIENTRY WinIsSOMDDReady( VOID );
  194.       
  195.    #endif  /*WPCLASS*/
  196.    
  197.    /*** Error codes ********************************************************/
  198.    #define INCL_WPERRORS
  199.    #include <pmerr.h>
  200.    
  201.    /*** Object settings notebook page insertion structure ******************/
  202.    
  203.    typedef struct _PAGEINFO     /* pginf */
  204.    {
  205.       ULONG   cb;
  206.       HWND    hwndPage;
  207.       PFNWP   pfnwp;
  208.       ULONG   resid;
  209.       PVOID   pCreateParams;
  210.       USHORT  dlgid;
  211.       USHORT  usPageStyleFlags;
  212.       USHORT  usPageInsertFlags;
  213.       USHORT  usSettingsFlags;
  214.       PSZ     pszName;
  215.       USHORT  idDefaultHelpPanel;
  216.       USHORT  usReserved2;
  217.       PSZ     pszHelpLibraryName;
  218.       PUSHORT pHelpSubtable;   /* PHELPSUBTABLE when PMHELP.H is included*/
  219.       HMODULE hmodHelpSubtable;
  220.       ULONG   ulPageInsertId;
  221.    } PAGEINFO;
  222.    typedef PAGEINFO *PPAGEINFO;
  223.    
  224.    #define  SETTINGS_PAGE_NUMBERS     0x01
  225.    
  226.    /*** Utility apis +******************************************************/
  227.    
  228.    #if (!defined(INCL_NOCOMMON))
  229.       typedef struct _ICONPOS     /* icp */
  230.       {
  231.          POINTL  ptlIcon;                    /* Location */
  232.          CHAR    szIdentity[1];              /* Object identity string */
  233.       } ICONPOS;
  234.       typedef ICONPOS *PICONPOS;
  235.       
  236.       /*********************************************************************/
  237.       #ifdef INCL_WINPOINTERS
  238. #ifdef __cplusplus
  239.          BOOL APIENTRY WinSetFileIcon(PCSZ  pszFileName,
  240.                                       PICONINFO pIcnInfo);
  241. #else
  242.          BOOL APIENTRY WinSetFileIcon(PSZ pszFileName,
  243.                                       PICONINFO pIcnInfo);
  244. #endif
  245.          
  246. #ifdef __cplusplus
  247.          BOOL APIENTRY WinSetFileIconN(PCSZ  pszFileName,
  248.                                        PICONINFO pIcnInfo,
  249.                                        ULONG ulIconIndex);
  250. #else
  251.          BOOL APIENTRY WinSetFileIconN(PSZ pszFileName,
  252.                                        PICONINFO pIcnInfo,
  253.                                        ULONG ulIconIndex);
  254. #endif
  255.       #endif
  256.       BOOL APIENTRY WinFreeFileIcon(HPOINTER hptr);
  257.       
  258. #ifdef __cplusplus
  259.       HPOINTER APIENTRY WinLoadFileIcon(PCSZ  pszFileName,
  260.                                         BOOL fPrivate);
  261. #else
  262.       HPOINTER APIENTRY WinLoadFileIcon(PSZ pszFileName,
  263.                                         BOOL fPrivate);
  264. #endif
  265.       
  266. #ifdef __cplusplus
  267.       HPOINTER APIENTRY WinLoadFileIconN(PCSZ  pszFileName,
  268.                                          BOOL fPrivate,
  269.                                          ULONG ulIconIndex);
  270. #else
  271.       HPOINTER APIENTRY WinLoadFileIconN(PSZ pszFileName,
  272.                                          BOOL fPrivate,
  273.                                          ULONG ulIconIndex);
  274. #endif
  275.       
  276. #ifdef __cplusplus
  277.       BOOL APIENTRY WinStoreWindowPos(PCSZ  pszAppName,
  278.                                       PCSZ  pszKeyName,
  279.                                       HWND hwnd);
  280. #else
  281.       BOOL APIENTRY WinStoreWindowPos(PSZ pszAppName,
  282.                                       PSZ pszKeyName,
  283.                                       HWND hwnd);
  284. #endif
  285.       
  286. #ifdef __cplusplus
  287.       BOOL APIENTRY WinRestoreWindowPos(PCSZ  pszAppName,
  288.                                         PCSZ  pszKeyName,
  289.                                         HWND hwnd);
  290. #else
  291.       BOOL APIENTRY WinRestoreWindowPos(PSZ pszAppName,
  292.                                         PSZ pszKeyName,
  293.                                         HWND hwnd);
  294. #endif
  295.       
  296.       BOOL APIENTRY WinShutdownSystem(HAB hab,
  297.                                       HMQ hmq);
  298.    #endif
  299.    
  300.    /* NOINC */
  301. #endif /* PMWP_INCLUDED */
  302. /* INC */
  303.  
  304. /* NOINC */
  305. #ifdef __cplusplus
  306.         }
  307. #endif
  308. #if __IBMC__ || __IBMCPP__
  309.    #pragma info( none )
  310.    #ifndef __CHKHDR__
  311.       #pragma info( restore )
  312.    #endif
  313.    #pragma info( restore )
  314. #endif
  315. /* INC */
  316.  
  317. /**************************** end of file **********************************/
  318.