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.

84 lines
2.3 KiB

  1. /* File: D:\WACKER\tdll\stdtyp.h (Created: 30-Nov-1993)
  2. *
  3. * Copyright 1994 by Hilgraeve Inc. -- Monroe, MI
  4. * All rights reserved
  5. *
  6. * $Revision: 5 $
  7. * $Date: 7/08/02 6:49p $
  8. */
  9. /* This needs to be here because it can change the way ECHAR is defined. */
  10. #include "features.h"
  11. #if !defined(INCL_STDTYP)
  12. #define INCL_STDTYP
  13. /* --- Define all handles here --- */
  14. typedef struct stSessionExt *HSESSION;
  15. typedef struct stLayoutExt *HLAYOUT;
  16. typedef struct stUpdateExt *HUPDATE;
  17. typedef struct stEmulExt *HEMU;
  18. typedef struct stCnctExt *HCNCT;
  19. typedef struct s_com *HCOM;
  20. typedef struct stCLoopExt *HCLOOP;
  21. typedef struct stXferExt *HXFER;
  22. typedef struct stBckScrlExt *HBACKSCRL;
  23. typedef struct stPrintExt *HPRINT;
  24. typedef struct stTimerMuxExt *HTIMERMUX;
  25. typedef struct stTimerExt *HTIMER;
  26. typedef struct stFilesDirs *HFILES;
  27. typedef struct stCaptureFile *HCAPTUREFILE;
  28. typedef struct stTranslateExt *HTRANSLATE;
  29. /* --- This one is a little different --- */
  30. #define SF_HANDLE int
  31. /* --- Other HA specific types --- */
  32. typedef unsigned KEY_T; // for internal key representation
  33. typedef unsigned KEYDEF; // for internal key representation
  34. typedef unsigned short RCDATA_TYPE; // for reading resources of type RCDATA
  35. // Character type used by Emulator and Terminal display routines
  36. //
  37. #if defined(CHAR_NARROW)
  38. typedef char ECHAR;
  39. #define ETEXT(x) (ECHAR)x
  40. #else
  41. typedef unsigned short ECHAR;
  42. #define ETEXT(x) (ECHAR)x
  43. #endif
  44. /* --- TRUE/FALSE macros --- */
  45. #if !defined(FALSE)
  46. #define FALSE 0
  47. #endif
  48. #if !defined(TRUE)
  49. #define TRUE 1
  50. #endif
  51. /* --- HA5 code references this stuff alot --- */
  52. #define DIM(a) (sizeof(a) / sizeof(a[0]))
  53. #define IN_RANGE(n, lo, hi) ((lo) <= (n) && (n) <= (hi))
  54. #define bitset(t, b) ((t) |= (b))
  55. #define bitclear(t, b) ((t) &= (~(b)))
  56. #define bittest(t, b) ((t) & (b))
  57. #define startinterval() GetTickCount()
  58. #define interval(X) ((GetTickCount()-(DWORD)X)/100L)
  59. #define WINDOWSBORDERWIDTH max(GetSystemMetrics(SM_CXBORDER), GetSystemMetrics(SM_CXEDGE))
  60. #define WINDOWSBORDERHEIGHT max(GetSystemMetrics(SM_CYBORDER), GetSystemMetrics(SM_CYEDGE))
  61. /* --- Just for now --- */
  62. #define STATIC_FUNC static
  63. #define FNAME_LEN MAX_PATH
  64. #define PRINTER_NAME_LEN 80
  65. #endif /* --- end stdtyp.h --- */