2 windows.h - main header file for the Win32 API
4 Written by Anders Norlander <anorland@hem2.passagen.se>
6 This file is part of a free library for the Win32 API.
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.
15 /* translate GCC target defines to MS equivalents. Keep this synchronized
17 #if defined(__i686__) && !defined(_M_IX86)
19 #elif defined(__i586__) && !defined(_M_IX86)
21 #elif defined(__i486__) && !defined(_M_IX86)
23 #elif defined(__i386__) && !defined(_M_IX86)
26 #if defined(_M_IX86) && !defined(_X86_)
28 #elif defined(_M_ALPHA) && !defined(_ALPHA_)
30 #elif defined(_M_PPC) && !defined(_PPC_)
32 #elif defined(_M_MRX000) && !defined(_MIPS_)
34 #elif defined(_M_M68K) && !defined(_68K_)
39 /* winresrc.h includes the necessary headers */
44 #ifndef NONAMELESSUNION
45 #if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)
46 #define _ANONYMOUS_UNION __extension__
47 #define _ANONYMOUS_STRUCT __extension__
49 #if defined(__cplusplus)
50 #define _ANONYMOUS_UNION __extension__
51 #endif /* __cplusplus */
52 #endif /* __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 95) */
53 #endif /* NONAMELESSUNION */
54 #elif defined(__WATCOMC__)
55 #define _ANONYMOUS_UNION
56 #define _ANONYMOUS_STRUCT
57 #endif /* __GNUC__/__WATCOMC__ */
59 #ifndef _ANONYMOUS_UNION
60 #define _ANONYMOUS_UNION
61 #define _UNION_NAME(x) x
62 #define DUMMYUNIONNAME u
63 #define DUMMYUNIONNAME2 u2
64 #define DUMMYUNIONNAME3 u3
65 #define DUMMYUNIONNAME4 u4
66 #define DUMMYUNIONNAME5 u5
67 #define DUMMYUNIONNAME6 u6
68 #define DUMMYUNIONNAME7 u7
69 #define DUMMYUNIONNAME8 u8
71 #define _UNION_NAME(x)
72 #define DUMMYUNIONNAME
73 #define DUMMYUNIONNAME2
74 #define DUMMYUNIONNAME3
75 #define DUMMYUNIONNAME4
76 #define DUMMYUNIONNAME5
77 #define DUMMYUNIONNAME6
78 #define DUMMYUNIONNAME7
79 #define DUMMYUNIONNAME8
81 #ifndef _ANONYMOUS_STRUCT
82 #define _ANONYMOUS_STRUCT
83 #define _STRUCT_NAME(x) x
84 #define DUMMYSTRUCTNAME s
85 #define DUMMYSTRUCTNAME2 s2
86 #define DUMMYSTRUCTNAME3 s3
88 #define _STRUCT_NAME(x)
89 #define DUMMYSTRUCTNAME
90 #define DUMMYSTRUCTNAME2
91 #define DUMMYSTRUCTNAME3
103 #include <basetyps.h>
119 #include <winnetwk.h>
128 #ifndef WIN32_LEAN_AND_MEAN
134 #include <lzexpand.h>
135 #include <mmsystem.h>
138 #include <shellapi.h>
140 #include <winspool.h>
141 #if defined(Win32_Winsock)
142 #warning "The Win32_Winsock macro name is deprecated.\
143 Please use __USE_W32_SOCKETS instead"
144 #ifndef __USE_W32_SOCKETS
145 #define __USE_W32_SOCKETS
148 #if defined(__USE_W32_SOCKETS) || !(defined(__CYGWIN__) || defined(__MSYS__) || defined(_UWIN))
149 #if (_WIN32_WINNT >= 0x0400) && (__W32API_MAJOR_VERSION > 0)
150 #include <winsock2.h>
152 * MS likes to include mswsock.h here as well,
153 * but that can cause undefined symbols if
154 * winsock2.h is included before windows.h
158 #endif /* (_WIN32_WINNT >= 0x0400) && (__W32API_MAJOR_VERSION > 0) */
160 #endif /* WIN32_LEAN_AND_MEAN */
162 #endif /* RC_INVOKED */
165 /* FIXME: Not undefining BOOL here causes all BOOLs to be WINBOOL (int),
166 but undefining it causes trouble as well if a file is included after