Source code of Windows XP (NT5)
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.

369 lines
18 KiB

  1. /**INC+**********************************************************************/
  2. /* Header: adcgctyp.h */
  3. /* */
  4. /* Purpose: Complex types - portable include file. */
  5. /* */
  6. /* Copyright(C) Microsoft Corporation 1997 */
  7. /* */
  8. /****************************************************************************/
  9. /** Changes:
  10. * $Log: Y:/logs/h/dcl/ADCGCTYP.H_v $
  11. *
  12. * Rev 1.7 07 Aug 1997 14:33:46 MR
  13. * SFR1133: Persuade Wd to compile under C++
  14. *
  15. * Rev 1.6 23 Jul 1997 10:47:54 mr
  16. * SFR1079: Merged \server\h duplicates to \h\dcl
  17. *
  18. * Rev 1.5 10 Jul 1997 11:51:36 AK
  19. * SFR1016: Initial changes to support Unicode
  20. **/
  21. /**INC-**********************************************************************/
  22. #ifndef _H_ADCGCTYP
  23. #define _H_ADCGCTYP
  24. /****************************************************************************/
  25. /* */
  26. /* INCLUDES */
  27. /* */
  28. /****************************************************************************/
  29. /****************************************************************************/
  30. /* Include appropriate header files. */
  31. /****************************************************************************/
  32. #ifndef __midl
  33. #ifndef OS_WINCE
  34. #include <time.h>
  35. #endif // OS_WINCE
  36. #endif
  37. /****************************************************************************/
  38. /* Include the proxy header. This will then include the appropriate OS */
  39. /* specific header for us. */
  40. /****************************************************************************/
  41. #include <wdcgctyp.h>
  42. /****************************************************************************/
  43. /* */
  44. /* TYPES */
  45. /* */
  46. /****************************************************************************/
  47. /****************************************************************************/
  48. /* DC-Share specific types. Note that some of these are OS specific so */
  49. /* the actual type definition appears in an OS specific header. However */
  50. /* the definition of the pointer to type is OS independant and therefore */
  51. /* appears in this file. */
  52. /****************************************************************************/
  53. typedef DCUINT32 DCAPPID;
  54. typedef DCUINT32 DCWINID;
  55. typedef DCUINT DCLOCALPERSONID;
  56. typedef DCUINT DCNETPERSONID;
  57. typedef DCUINT32 DCENTITYID;
  58. typedef DCAPPID DCPTR PDCAPPID;
  59. typedef DCWINID DCPTR PDCWINID;
  60. typedef DCLOCALPERSONID DCPTR PDCLOCALPERSONID;
  61. typedef DCNETPERSONID DCPTR PDCNETPERSONID;
  62. typedef DCENTITYID DCPTR PDCENTITYID;
  63. typedef DCREGIONID DCPTR PDCREGIONID;
  64. typedef DCPALID DCPTR PDCPALID;
  65. typedef DCCURSORID DCPTR PDCCURSORID;
  66. typedef DCHFONT DCPTR PDCHFONT;
  67. typedef DCFILETIME DCPTR PDCFILETIME;
  68. typedef DCHFILE DCPTR PDCHFILE;
  69. typedef PDCACHAR PDCSTR;
  70. typedef DCUINT ATRETCODE;
  71. typedef PDCVOID SYSREGION;
  72. typedef SYSRECT DCPTR PSYSRECT;
  73. typedef SYSAPPID DCPTR PSYSAPPID;
  74. typedef SYSWINID DCPTR PSYSWINID;
  75. typedef SYSBITMAP DCPTR PSYSBITMAP;
  76. typedef SYSBMIHEADER DCPTR PSYSBMIHEADER;
  77. typedef SYSBMI DCPTR PSYSBMI;
  78. typedef SYSPOINT DCPTR PSYSPOINT;
  79. typedef SYSREGION DCPTR PSYSREGION;
  80. /****************************************************************************/
  81. /* Window and dialog procedure typedefs. */
  82. /****************************************************************************/
  83. #if !defined(DLL_DISP) && !defined(DLL_WD)
  84. typedef WNDPROC PDCWNDPROC;
  85. typedef DLGPROC PDCDLGPROC;
  86. #endif
  87. typedef WPARAM DCPARAM1;
  88. typedef LPARAM DCPARAM2;
  89. /****************************************************************************/
  90. /* Time typedefs. */
  91. /****************************************************************************/
  92. typedef time_t DC_LONGTIME;
  93. typedef struct tm DC_TMTIME;
  94. /****************************************************************************/
  95. /* */
  96. /* STRUCTURES */
  97. /* */
  98. /****************************************************************************/
  99. /****************************************************************************/
  100. /* RGBQUAD */
  101. /* ======= */
  102. /* rgbBlue : blue value. */
  103. /* rgbGreen : green value. */
  104. /* */
  105. /* rgbRed : red value. */
  106. /* rgbReserved : reserved. */
  107. /****************************************************************************/
  108. typedef struct tagDCRGBQUAD
  109. {
  110. DCUINT8 rgbBlue;
  111. DCUINT8 rgbGreen;
  112. DCUINT8 rgbRed;
  113. DCUINT8 rgbReserved;
  114. } DCRGBQUAD;
  115. typedef DCRGBQUAD DCPTR PDCRGBQUAD;
  116. /****************************************************************************/
  117. /* DCRECT16 */
  118. /* ======== */
  119. /* This is an OS independant rectangle structure. */
  120. /* */
  121. /* left : left position. */
  122. /* top : top position. */
  123. /* right : right position. */
  124. /* bottom : bottom position. */
  125. /****************************************************************************/
  126. typedef struct tagDCRECT16
  127. {
  128. DCINT16 left;
  129. DCINT16 top;
  130. DCINT16 right;
  131. DCINT16 bottom;
  132. } DCRECT16;
  133. typedef DCRECT16 DCPTR PDCRECT16;
  134. /****************************************************************************/
  135. /* DCRECT */
  136. /* ====== */
  137. /* left : left position. */
  138. /* top : top position. */
  139. /* right : right position. */
  140. /* bottom : bottom position. */
  141. /****************************************************************************/
  142. typedef struct tagDCRECT
  143. {
  144. DCINT left;
  145. DCINT top;
  146. DCINT right;
  147. DCINT bottom;
  148. } DCRECT;
  149. typedef DCRECT DCPTR PDCRECT;
  150. /****************************************************************************/
  151. /* DCRGB */
  152. /* ===== */
  153. /* red : red value. */
  154. /* green : green value. */
  155. /* blue : blue value. */
  156. /****************************************************************************/
  157. typedef struct tagDCRGB
  158. {
  159. DCUINT8 red;
  160. DCUINT8 green;
  161. DCUINT8 blue;
  162. } DCRGB;
  163. typedef DCRGB DCPTR PDCRGB;
  164. /****************************************************************************/
  165. /* DCCOLOR */
  166. /* ======= */
  167. /* */
  168. /* Union of DCRGB and an index into a color table */
  169. /* */
  170. /****************************************************************************/
  171. typedef struct tagDCCOLOR
  172. {
  173. union
  174. {
  175. DCRGB rgb;
  176. DCUINT8 index;
  177. } u;
  178. } DCCOLOR;
  179. typedef DCCOLOR DCPTR PDCCOLOR;
  180. /****************************************************************************/
  181. /* DCSIZE */
  182. /* ====== */
  183. /* width : x dimension. */
  184. /* height : y dimension. */
  185. /****************************************************************************/
  186. typedef struct tagDCSIZE
  187. {
  188. DCUINT width;
  189. DCUINT height;
  190. } DCSIZE;
  191. typedef DCSIZE DCPTR PDCSIZE;
  192. /****************************************************************************/
  193. /* DCPOINT */
  194. /* ======= */
  195. /* x : x co-ordinate. */
  196. /* y : y co-ordinate. */
  197. /****************************************************************************/
  198. typedef struct tagDCPOINT
  199. {
  200. DCINT x;
  201. DCINT y;
  202. } DCPOINT;
  203. typedef DCPOINT DCPTR PDCPOINT;
  204. /****************************************************************************/
  205. /* DCPOINT16 */
  206. /* ========= */
  207. /* x : x co-ordinate. */
  208. /* y : y co-ordinate. */
  209. /****************************************************************************/
  210. typedef struct tagDCPOINT16
  211. {
  212. DCINT16 x;
  213. DCINT16 y;
  214. } DCPOINT16;
  215. typedef DCPOINT16 DCPTR PDCPOINT16;
  216. /****************************************************************************/
  217. /* DCPOINT32 */
  218. /* ========= */
  219. /* x : x co-ordinate. */
  220. /* y : y co-ordinate. */
  221. /****************************************************************************/
  222. typedef struct tagDCPOINT32
  223. {
  224. DCINT32 x;
  225. DCINT32 y;
  226. } DCPOINT32;
  227. typedef DCPOINT32 DCPTR PDCPOINT32;
  228. #ifndef __midl
  229. /****************************************************************************/
  230. /* BITMAPINFO_ours */
  231. /* =============== */
  232. /* bmiHeader : */
  233. /* bmiColors : */
  234. /****************************************************************************/
  235. typedef struct tagBITMAPINFO_ours
  236. {
  237. SYSBMIHEADER bmiHeader;
  238. DCRGBQUAD bmiColors[256];
  239. } BITMAPINFO_ours;
  240. /****************************************************************************/
  241. /* BITMAPINFO_PLUS */
  242. /* =============== */
  243. /* bmiHeader : */
  244. /* bmiColors : */
  245. /****************************************************************************/
  246. typedef struct tagBINFO_PLUS
  247. {
  248. SYSBMIHEADER bmiHeader;
  249. DCRGBQUAD bmiColors[256];
  250. } BITMAPINFO_PLUS_COLOR_TABLE;
  251. #endif
  252. /****************************************************************************/
  253. /* DC_DATE */
  254. /* ======= */
  255. /* day : day of the month (1-31). */
  256. /* month : month (1-12). */
  257. /* year : year (e.g. 1996). */
  258. /****************************************************************************/
  259. typedef struct tagDC_DATE
  260. {
  261. DCUINT8 day;
  262. DCUINT8 month;
  263. DCUINT16 year;
  264. } DC_DATE;
  265. typedef DC_DATE DCPTR PDC_DATE;
  266. /****************************************************************************/
  267. /* DC_TIME */
  268. /* ======= */
  269. /* hour : hour (0-23). */
  270. /* min : minute (0-59). */
  271. /* sec : seconds (0-59). */
  272. /* hundredths : hundredths of a second (0-99). */
  273. /****************************************************************************/
  274. typedef struct tagDC_TIME
  275. {
  276. DCUINT8 hour;
  277. DCUINT8 min;
  278. DCUINT8 sec;
  279. DCUINT8 hundredths;
  280. } DC_TIME;
  281. typedef DC_TIME DCPTR PDC_TIME;
  282. /****************************************************************************/
  283. /* Types of addresses supported by Groupware (these go in the <addressType> */
  284. /* field of the DC_PERSON_ADDRESS structure): */
  285. /****************************************************************************/
  286. #define DC_ADDRESS_TYPE_NONE 0
  287. #define DC_ADDRESS_TYPE_NETBIOS 1
  288. #define DC_ADDRESS_TYPE_IPXSPX 2
  289. #define DC_ADDRESS_TYPE_VIRTUAL_ASYNC 3
  290. #define DC_ADDRESS_TYPE_MODEM 4
  291. #define DC_ADDRESS_TYPE_LIVELAN 5
  292. #define DC_ADDRESS_TYPE_PCS100 6
  293. /****************************************************************************/
  294. /* This is the max number of addresses the address book will store for */
  295. /* one person: */
  296. /****************************************************************************/
  297. #define DC_MAX_ADDRESSES_PER_PERSON 6
  298. /****************************************************************************/
  299. /* These constants define the maximum length of person names and addresses */
  300. /* supported by the Address Book. */
  301. /****************************************************************************/
  302. #define DC_MAX_NAME_LEN 48 /* for general purpose names */
  303. /* (includes the nul term) */
  304. #define DC_MAX_ADDR_DATA_LEN 48 /* for general purpose addresses */
  305. /* this may be binary data */
  306. /****************************************************************************/
  307. /* Defines the maximum number of BYTES allowed in a translated "shared by " */
  308. /* string. */
  309. /****************************************************************************/
  310. #define DC_MAX_SHARED_BY_BUFFER 64
  311. #ifdef DESKTOPSHARING
  312. #define DC_MAX_SHAREDDESKTOP_BUFFER 64
  313. #endif /*DESKTOPSHARING*/
  314. /****************************************************************************/
  315. /* Address for a specific transport type: */
  316. /****************************************************************************/
  317. typedef struct tagDC_PERSON_ADDRESS
  318. {
  319. DCUINT16 addressType; /* N'bios, async, IPX... */
  320. DCUINT16 addressLen; /* length of <addressData>*/
  321. DCACHAR addressData[DC_MAX_ADDR_DATA_LEN]; /* TDD specific data */
  322. } DC_PERSON_ADDRESS;
  323. typedef DC_PERSON_ADDRESS DCPTR PDC_PERSON_ADDRESS;
  324. /****************************************************************************/
  325. /* General purpose address holder */
  326. /****************************************************************************/
  327. typedef struct tagDC_PERSON
  328. {
  329. DCACHAR name[DC_MAX_NAME_LEN];
  330. /* textual name - displayed to user */
  331. /* (must be NULL-terminated). */
  332. DC_PERSON_ADDRESS address[DC_MAX_ADDRESSES_PER_PERSON];
  333. /* array of addresses for this person */
  334. } DC_PERSON;
  335. typedef DC_PERSON DCPTR PDC_PERSON;
  336. #endif /* _H_ADCGCTYP */