Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

88 lines
2.7 KiB

  1. //+-------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. //
  5. // Copyright (C) Microsoft Corporation, 1996 - 1999
  6. //
  7. // File: chklist.h
  8. //
  9. // Definitions and protytypes for the checklist pseudo-control.
  10. //
  11. //--------------------------------------------------------------------------
  12. #ifndef _CHKLIST_H_
  13. #define _CHKLIST_H_
  14. #ifdef __cplusplus
  15. extern "C" {
  16. #endif /* __cplusplus */
  17. //
  18. // CheckList window class name
  19. //
  20. #define WC_CHECKLIST "CHECKLIST_ACLUI"
  21. BOOL RegisterCheckListWndClass(void);
  22. //
  23. // CheckList check states
  24. //
  25. #define CLST_UNCHECKED 0 // == BST_UNCHECKED
  26. #define CLST_CHECKED 1 // == BST_CHECKED
  27. #define CLST_DISABLED 2 // == BST_INDETERMINATE
  28. #define CLST_CHECKDISABLED (CLST_CHECKED | CLST_DISABLED)
  29. //
  30. // CheckList window styles
  31. //
  32. #define CLS_1CHECK 0x0001
  33. #define CLS_2CHECK 0x0002
  34. //#define CLS_3CHECK 0x0003
  35. //#define CLS_4CHECK 0x0004
  36. #define CLS_CHECKMASK 0x000f
  37. //
  38. // CheckList messages
  39. //
  40. // row is 0-based
  41. // column is 1-based
  42. //
  43. #define CLM_SETCOLUMNWIDTH (WM_USER + 1) // lParam = width (dlg units) of a check column (default=32)
  44. #define CLM_ADDITEM (WM_USER + 2) // wParam = pszName, lParam = item data, return = row
  45. #define CLM_GETITEMCOUNT (WM_USER + 3) // no parameters
  46. #define CLM_SETSTATE (WM_USER + 4) // wParam = row/column, lParam = state
  47. #define CLM_GETSTATE (WM_USER + 5) // wParam = row/column, return = state
  48. #define CLM_SETITEMDATA (WM_USER + 6) // wParam = row, lParam = item data
  49. #define CLM_GETITEMDATA (WM_USER + 7) // wParam = row, return = item data
  50. #define CLM_RESETCONTENT (WM_USER + 8) // no parameters
  51. #define CLM_GETVISIBLECOUNT (WM_USER + 9) // no parameters, return = # of visible rows
  52. #define CLM_GETTOPINDEX (WM_USER + 10) // no parameters, return = index of top row
  53. #define CLM_SETTOPINDEX (WM_USER + 11) // wParam = index of new top row
  54. #define CLM_ENSUREVISIBLE (WM_USER + 12) // wParam = index of item to make fully visible
  55. //
  56. // CheckList notification messages
  57. //
  58. #define CLN_FIRST (1000U) // commctrl use negative values
  59. #define CLN_LAST (1049U)
  60. #define CLN_CLICK (CLN_FIRST+0) // lparam = PNM_CHECKLIST
  61. #define CLN_GETCOLUMNDESC (CLN_FIRST+1)
  62. typedef struct _NM_CHECKLIST
  63. {
  64. NMHDR hdr;
  65. int iItem; // row (0-based)
  66. int iSubItem; // column (1-based)
  67. DWORD dwState;
  68. DWORD_PTR dwItemData;
  69. ULONG cchTextMax;
  70. LPTSTR pszText;
  71. } NM_CHECKLIST, *PNM_CHECKLIST;
  72. #ifdef __cplusplus
  73. }
  74. #endif /* __cplusplus */
  75. #endif /* _CHKLIST_H_ */