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.

106 lines
3.1 KiB

  1. /*****************************************************************************\
  2. * *
  3. * choosusr.h - choose user dialog function, types, and definitions *
  4. * *
  5. * Version 1.0 *
  6. * *
  7. * NOTE: windows.h must be #included first *
  8. * *
  9. * Copyright (c) 1993, Microsoft Corp. All rights reserved. *
  10. * *
  11. \*****************************************************************************/
  12. #ifndef _INC_CHOOSUSR
  13. #define _INC_CHOOSUSR
  14. #ifndef RC_INVOKED
  15. #pragma pack(1) /* Assume byte packing throughout */
  16. #endif /* !RC_INVOKED */
  17. #ifdef __cplusplus
  18. extern "C" { /* Assume C declarations for C++ */
  19. #endif /* __cplusplus */
  20. #ifndef WINAPI /* If not included with 3.1 headers... */
  21. #define WINAPI FAR PASCAL
  22. #define CALLBACK FAR PASCAL
  23. #define LPCSTR LPSTR
  24. #define UINT WORD
  25. #define LPARAM LONG
  26. #define WPARAM WORD
  27. #define LRESULT LONG
  28. #define HMODULE HANDLE
  29. #define HINSTANCE HANDLE
  30. #define HLOCAL HANDLE
  31. #define HGLOBAL HANDLE
  32. #endif /* _INC_WINDOWS */
  33. #define MAX_BINS 3
  34. // codes in CHOOSEUSER.dwError
  35. #define CUERR_NO_ERROR 0
  36. #define CUERR_BUF_TOO_SMALL 80
  37. #define CUERR_INVALID_PARAMETER 81
  38. #define CUERR_PROVIDER_ERROR 82
  39. #define CUERR_NO_AB_PROVIDER 83
  40. #define CUERR_INVALID_AB_PROVIDER 84
  41. // codes in CHOOSEUSER.Flags
  42. #define CUFLG_USR_ONLY 0x00000001
  43. #define CUFLG_GRP_ONLY 0x00000002
  44. struct tagCHOOSEUSER
  45. {
  46. DWORD lStructSize;
  47. HWND hwndOwner;
  48. HINSTANCE hInstance;
  49. DWORD Flags;
  50. UINT nBins;
  51. LPSTR lpszDialogTitle;
  52. LPSTR lpszProvider;
  53. LPSTR lpszReserved;
  54. LPSTR lpszRemote;
  55. LPSTR lpszHelpFile;
  56. LPSTR lpszBinButtonText[MAX_BINS];
  57. DWORD dwBinValue[MAX_BINS];
  58. DWORD dwBinHelpID[MAX_BINS];
  59. LPBYTE lpBuf;
  60. DWORD cbBuf;
  61. DWORD nEntries; // OUT
  62. DWORD cbData; // OUT
  63. DWORD dwError; // OUT
  64. DWORD dwErrorDetails; // OUT
  65. };
  66. typedef struct tagCHOOSEUSER CHOOSEUSER;
  67. typedef struct tagCHOOSEUSER FAR *LPCHOOSEUSER;
  68. // codes for CHOOSEUSERENTRY.dwEntryAttributes
  69. #define CUE_ATTR_USER 0x00000001
  70. #define CUE_ATTR_GROUP 0x00000002
  71. #define CUE_ATTR_WORLD 0x00000004
  72. struct tagCHOOSEUSERENTRY
  73. {
  74. LPSTR lpszShortName;
  75. LPSTR lpszLongName;
  76. DWORD dwBinAttributes;
  77. DWORD dwEntryAttributes;
  78. };
  79. typedef struct tagCHOOSEUSERENTRY CHOOSEUSERENTRY;
  80. typedef struct tagCHOOSEUSERENTRY FAR *LPCHOOSEUSERENTRY;
  81. BOOL WINAPI ChooseUser(CHOOSEUSER FAR*);
  82. typedef BOOL (WINAPI *LPFNCU)(LPCHOOSEUSER);
  83. #ifdef __cplusplus
  84. }
  85. #endif /* __cplusplus */
  86. #ifndef RC_INVOKED
  87. #pragma pack()
  88. #endif /* !RC_INVOKED */
  89. #endif /* !_INC_CHOOSUSR */