home *** CD-ROM | disk | FTP | other *** search
/ PC Format (South-Africa) 2001 June / PCFJune.iso / Xenon / C++ / FreeCommandLineTools.exe / Include / wfext.h < prev    next >
Encoding:
C/C++ Source or Header  |  2000-01-31  |  6.5 KB  |  192 lines

  1. /*****************************************************************************\
  2. *                                                                             *
  3. * wfext.h -     Windows File Manager Extensions definitions (Win32 variant)   *
  4. *                                                                             *
  5. *               Version 3.10                                                  *
  6. *                                                                             *
  7. *               Copyright (c) 1991-1999, Microsoft Corp. All rights reserved. *
  8. *                                                                             *
  9. *******************************************************************************/
  10.  
  11. #ifndef _INC_WFEXT
  12. #pragma option push -b -a8 -pc -A- /*P_O_Push*/
  13. #define _INC_WFEXT            /* #defined if wfext.h has been included */
  14.  
  15. #if _MSC_VER > 1000
  16. #pragma once
  17. #endif
  18.  
  19. #ifdef __cplusplus            /* Assume C declaration for C++ */
  20. extern "C" {
  21. #endif  /* __cplusplus */
  22.  
  23. #define MENU_TEXT_LEN           40
  24.  
  25. #define FMMENU_FIRST            1
  26. #define FMMENU_LAST             99
  27.  
  28. #define FMEVENT_LOAD            100
  29. #define FMEVENT_UNLOAD          101
  30. #define FMEVENT_INITMENU        102
  31. #define FMEVENT_USER_REFRESH    103
  32. #define FMEVENT_SELCHANGE       104
  33. #define FMEVENT_TOOLBARLOAD     105
  34. #define FMEVENT_HELPSTRING      106
  35. #define FMEVENT_HELPMENUITEM    107
  36.  
  37. #define FMFOCUS_DIR             1
  38. #define FMFOCUS_TREE            2
  39. #define FMFOCUS_DRIVES          3
  40. #define FMFOCUS_SEARCH          4
  41.  
  42. #define FM_GETFOCUS           (WM_USER + 0x0200)
  43. #define FM_GETSELCOUNT        (WM_USER + 0x0202)
  44. #define FM_GETSELCOUNTLFN     (WM_USER + 0x0203)  /* LFN versions are odd */
  45. #define FM_REFRESH_WINDOWS    (WM_USER + 0x0206)
  46. #define FM_RELOAD_EXTENSIONS  (WM_USER + 0x0207)
  47.  
  48. #define FM_GETDRIVEINFOA      (WM_USER + 0x0201)
  49. #define FM_GETFILESELA        (WM_USER + 0x0204)
  50. #define FM_GETFILESELLFNA     (WM_USER + 0x0205)  /* LFN versions are odd */
  51.  
  52. #define FM_GETDRIVEINFOW      (WM_USER + 0x0211)
  53. #define FM_GETFILESELW        (WM_USER + 0x0214)
  54. #define FM_GETFILESELLFNW     (WM_USER + 0x0215)  /* LFN versions are odd */
  55.  
  56. #ifdef UNICODE
  57. #define FM_GETDRIVEINFO    FM_GETDRIVEINFOW
  58. #define FM_GETFILESEL      FM_GETFILESELW
  59. #define FM_GETFILESELLFN   FM_GETFILESELLFNW
  60. #else
  61. #define FM_GETDRIVEINFO    FM_GETDRIVEINFOA
  62. #define FM_GETFILESEL      FM_GETFILESELA
  63. #define FM_GETFILESELLFN   FM_GETFILESELLFNA
  64. #endif
  65.  
  66.  
  67. typedef struct _FMS_GETFILESELA {
  68.    FILETIME ftTime;
  69.    DWORD dwSize;
  70.    BYTE bAttr;
  71.    CHAR szName[260];          // always fully qualified
  72. } FMS_GETFILESELA, FAR *LPFMS_GETFILESELA;
  73.  
  74. typedef struct _FMS_GETFILESELW {
  75.    FILETIME ftTime ;
  76.    DWORD dwSize;
  77.    BYTE bAttr;
  78.    WCHAR szName[260];          // always fully qualified
  79. } FMS_GETFILESELW, FAR *LPFMS_GETFILESELW;
  80.  
  81. #ifdef UNICODE
  82. #define FMS_GETFILESEL   FMS_GETFILESELW
  83. #define LPFMS_GETFILESEL LPFMS_GETFILESELW
  84. #else
  85. #define FMS_GETFILESEL   FMS_GETFILESELA
  86. #define LPFMS_GETFILESEL LPFMS_GETFILESELA
  87. #endif
  88.  
  89.  
  90. typedef struct _FMS_GETDRIVEINFOA {      // for drive
  91.    DWORD dwTotalSpace;
  92.    DWORD dwFreeSpace;
  93.    CHAR  szPath[260];                    // current directory
  94.    CHAR  szVolume[14];                   // volume label
  95.    CHAR  szShare[128];                   // if this is a net drive
  96. } FMS_GETDRIVEINFOA, FAR *LPFMS_GETDRIVEINFOA;
  97.  
  98. typedef struct _FMS_GETDRIVEINFOW {      // for drive
  99.    DWORD dwTotalSpace;
  100.    DWORD dwFreeSpace;
  101.    WCHAR szPath[260];                    // current directory
  102.    WCHAR szVolume[14];                   // volume label
  103.    WCHAR szShare[128];                   // if this is a net drive
  104. } FMS_GETDRIVEINFOW, FAR *LPFMS_GETDRIVEINFOW;
  105.  
  106. #ifdef UNICODE
  107. #define FMS_GETDRIVEINFO   FMS_GETDRIVEINFOW
  108. #define LPFMS_GETDRIVEINFO LPFMS_GETDRIVEINFOW
  109. #else
  110. #define FMS_GETDRIVEINFO   FMS_GETDRIVEINFOA
  111. #define LPFMS_GETDRIVEINFO LPFMS_GETDRIVEINFOA
  112. #endif
  113.  
  114.  
  115. typedef struct _FMS_LOADA {
  116.    DWORD dwSize;                        // for version checks
  117.    CHAR  szMenuName[MENU_TEXT_LEN];     // output
  118.    HMENU hMenu;                         // output
  119.    UINT  wMenuDelta;                    // input
  120. } FMS_LOADA, FAR *LPFMS_LOADA;
  121.  
  122. typedef struct _FMS_LOADW {
  123.    DWORD dwSize;                        // for version checks
  124.    WCHAR szMenuName[MENU_TEXT_LEN];     // output
  125.    HMENU hMenu;                         // output
  126.    UINT  wMenuDelta;                    // input
  127. } FMS_LOADW, FAR *LPFMS_LOADW;
  128.  
  129. #ifdef UNICODE
  130. #define FMS_LOAD   FMS_LOADW
  131. #define LPFMS_LOAD LPFMS_LOADW
  132. #else
  133. #define FMS_LOAD   FMS_LOADA
  134. #define LPFMS_LOAD LPFMS_LOADA
  135. #endif
  136.  
  137.  
  138. // Toolbar definitions
  139.  
  140. typedef struct tagEXT_BUTTON {
  141.    WORD idCommand;                 /* menu command to trigger */
  142.    WORD idsHelp;                   /* help string ID */
  143.    WORD fsStyle;                   /* button style */
  144. } EXT_BUTTON, FAR *LPEXT_BUTTON;
  145.  
  146. typedef struct tagFMS_TOOLBARLOAD {
  147.    DWORD dwSize;                   /* for version checks */
  148.    LPEXT_BUTTON lpButtons;         /* output */
  149.    WORD cButtons;                  /* output, 0==>no buttons */
  150.    WORD cBitmaps;                  /* number of non-sep buttons */
  151.    WORD idBitmap;                  /* output */
  152.    HBITMAP hBitmap;                /* output if idBitmap==0 */
  153. } FMS_TOOLBARLOAD, FAR *LPFMS_TOOLBARLOAD;
  154.  
  155. typedef struct tagFMS_HELPSTRINGA {
  156.    INT   idCommand;       /* input, -1==>the menu was selected */
  157.    HMENU hMenu;           /* input, the extensions menu */
  158.    CHAR  szHelp[128];     /* output, the help string */
  159. } FMS_HELPSTRINGA, FAR *LPFMS_HELPSTRINGA;
  160.  
  161. typedef struct tagFMS_HELPSTRINGW {
  162.    INT   idCommand;       /* input, -1==>the menu was selected */
  163.    HMENU hMenu;           /* input, the extensions menu */
  164.    WCHAR szHelp[128];     /* output, the help string */
  165. } FMS_HELPSTRINGW, FAR *LPFMS_HELPSTRINGW;
  166.  
  167. #ifdef UNICODE
  168. #define FMS_HELPSTRING   FMS_HELPSTRINGW
  169. #define LPFMS_HELPSTRING LPFMS_HELPSTRINGW
  170. #else
  171. #define FMS_HELPSTRING   FMS_HELPSTRINGA
  172. #define LPFMS_HELPSTRING LPFMS_HELPSTRINGA
  173. #endif
  174.  
  175.  
  176. typedef DWORD (APIENTRY *FM_EXT_PROC)(HWND, WORD, LONG);
  177. typedef DWORD (APIENTRY *FM_UNDELETE_PROC)(HWND, LPTSTR);
  178.  
  179. #ifdef UNICODE
  180. LONG WINAPI FMExtensionProcW(HWND hwnd, WORD wEvent, LONG lParam);
  181. #else
  182. LONG WINAPI FMExtensionProc(HWND hwnd, WORD wEvent, LONG lParam);
  183. #endif
  184.  
  185. #ifdef __cplusplus
  186. }                  /* End of extern "C" { */
  187. #endif             /* __cplusplus */
  188.  
  189. #pragma option pop /*P_O_Pop*/
  190. #endif             /* _INC_WFEXT */
  191.  
  192.