home *** CD-ROM | disk | FTP | other *** search
/ Chip 2002 June / Chip_2002-06_cd1.bin / zkuste / cecko / install / devcpp4920.exe / include / windows.h < prev    next >
Encoding:
C/C++ Source or Header  |  2001-09-14  |  4.0 KB  |  170 lines

  1. /*
  2.     windows.h - main header file for the Win32 API
  3.  
  4.     Written by Anders Norlander <anorland@hem2.passagen.se>
  5.  
  6.     This file is part of a free library for the Win32 API.
  7.  
  8.     This library is distributed in the hope that it will be useful,
  9.     but WITHOUT ANY WARRANTY; without even the implied warranty of
  10.     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  11.  
  12. */
  13. #ifndef _WINDOWS_H
  14. #define _WINDOWS_H
  15. /* translate GCC target defines to MS equivalents. Keep this synchronized
  16.    with winnt.h. */
  17. #if defined(__i686__) && !defined(_M_IX86)
  18. #define _M_IX86 600
  19. #elif defined(__i586__) && !defined(_M_IX86)
  20. #define _M_IX86 500
  21. #elif defined(__i486__) && !defined(_M_IX86)
  22. #define _M_IX86 400
  23. #elif defined(__i386__) && !defined(_M_IX86)
  24. #define _M_IX86 300
  25. #endif
  26. #if defined(_M_IX86) && !defined(_X86_)
  27. #define _X86_
  28. #elif defined(_M_ALPHA) && !defined(_ALPHA_)
  29. #define _ALPHA_
  30. #elif defined(_M_PPC) && !defined(_PPC_)
  31. #define _PPC_
  32. #elif defined(_M_MRX000) && !defined(_MIPS_)
  33. #define _MIPS_
  34. #elif defined(_M_M68K) && !defined(_68K_)
  35. #define _68K_
  36. #endif
  37.  
  38. #ifdef RC_INVOKED
  39. /* winresrc.h includes the necessary headers */
  40. #include <winresrc.h>
  41. #else
  42.  
  43. #ifdef __GNUC__
  44. #ifndef NONAMELESSUNION
  45. #if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 95) 
  46. #define _ANONYMOUS_UNION __extension__
  47. #define _ANONYMOUS_STRUCT __extension__
  48. #else
  49. #if defined(__cplusplus)
  50. #define _ANONYMOUS_UNION __extension__
  51. #endif
  52. #endif /* __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 95) */
  53. #endif /* NONAMELESSUNION */
  54. #endif /* __GNUC__ */
  55.  
  56. #ifndef _ANONYMOUS_UNION
  57. #define _ANONYMOUS_UNION
  58. #define _UNION_NAME(x) x
  59. #define DUMMYUNIONNAME    u
  60. #define DUMMYUNIONNAME2    u2
  61. #define DUMMYUNIONNAME3    u3
  62. #define DUMMYUNIONNAME4    u4
  63. #define DUMMYUNIONNAME5    u5
  64. #define DUMMYUNIONNAME6    u6
  65. #define DUMMYUNIONNAME7    u7
  66. #define DUMMYUNIONNAME8    u8
  67. #else
  68. #define _UNION_NAME(x)
  69. #define DUMMYUNIONNAME
  70. #define DUMMYUNIONNAME2
  71. #define DUMMYUNIONNAME3
  72. #define DUMMYUNIONNAME4
  73. #define DUMMYUNIONNAME5
  74. #define DUMMYUNIONNAME6
  75. #define DUMMYUNIONNAME7
  76. #define DUMMYUNIONNAME8
  77. #endif
  78. #ifndef _ANONYMOUS_STRUCT
  79. #define _ANONYMOUS_STRUCT
  80. #define _STRUCT_NAME(x) x
  81. #define DUMMYSTRUCTNAME    s
  82. #define DUMMYSTRUCTNAME2 s2
  83. #define DUMMYSTRUCTNAME3 s3
  84. #else
  85. #define _STRUCT_NAME(x)
  86. #define DUMMYSTRUCTNAME
  87. #define DUMMYSTRUCTNAME2
  88. #define DUMMYSTRUCTNAME3
  89. #endif
  90.  
  91. #ifndef NO_STRICT
  92. #ifndef STRICT
  93. #define STRICT 1
  94. #endif
  95. #endif
  96.  
  97. #include <stdarg.h>
  98. #include <windef.h>
  99. #include <wincon.h>
  100. #include <basetyps.h>
  101. #include <excpt.h>
  102. #include <winbase.h>
  103. #ifndef _WINGDI_H
  104. #include <wingdi.h>
  105. #endif
  106. #ifndef _WINUSER_H
  107. #include <winuser.h>
  108. #endif
  109. #ifndef _WINNLS_H
  110. #include <winnls.h>
  111. #endif
  112. #ifndef _WINVER_H
  113. #include <winver.h>
  114. #endif
  115. #ifndef _WINNETWK_H
  116. #include <winnetwk.h>
  117. #endif
  118. #ifndef _WINREG_H
  119. #include <winreg.h>
  120. #endif
  121. #ifndef _WINSVC_H
  122. #include <winsvc.h>
  123. #endif
  124.  
  125. #ifndef WIN32_LEAN_AND_MEAN
  126. #include <commdlg.h>
  127. #include <cderr.h>
  128. #include <dde.h>
  129. #include <ddeml.h>
  130. #include <dlgs.h>
  131. #include <lzexpand.h>
  132. #include <mmsystem.h>
  133. #include <nb30.h>
  134. #include <rpc.h>
  135. #include <shellapi.h>
  136. #include <winperf.h>
  137. #include <winspool.h>
  138. #if defined(Win32_Winsock)
  139. #warning "The  Win32_Winsock macro name is deprecated.\
  140.     Please use __USE_W32_SOCKETS instead"
  141. #ifndef __USE_W32_SOCKETS
  142. #define __USE_W32_SOCKETS
  143. #endif
  144. #endif
  145. #if defined(__USE_W32_SOCKETS) || !(defined(__CYGWIN__) || defined(__MSYS__) || defined(_UWIN))
  146. #if (_WIN32_WINNT >= 0x0400)  && (__W32API_MAJOR_VERSION > 0)
  147. #include <winsock2.h>
  148. /*
  149.  * MS likes to include mswsock.h here as well,
  150.  * but that can cause undefined symbols if
  151.  * winsock2.h is included before windows.h
  152.  */
  153. #else
  154. #include <winsock.h>
  155. #endif /*  (_WIN32_WINNT >= 0x0400)  && (__W32API_MAJOR_VERSION > 0) */
  156. #endif
  157. #endif /* WIN32_LEAN_AND_MEAN */
  158.  
  159. #endif /* RC_INVOKED */
  160.  
  161. #ifdef __OBJC__
  162. /* FIXME: Not undefining BOOL here causes all BOOLs to be WINBOOL (int),
  163.    but undefining it causes trouble as well if a file is included after
  164.    windows.h
  165. */
  166. #undef BOOL
  167. #endif
  168.  
  169. #endif
  170.