annotate loader/wine/windef.h @ 20749:eafd9953b505

added demuxer_get_current_time() to get the current playtime (possibly aided by the stream layer)
author nicodvb
date Tue, 07 Nov 2006 22:55:49 +0000
parents 0783dd397f74
children 251338cf2f58
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
1 /*
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
2 * Basic types definitions
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
3 *
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
4 * Copyright 1996 Alexandre Julliard
15166
f5537cc95b02 Mark modified imported files as such to comply with GPL ¡ø2a.
diego
parents: 13182
diff changeset
5 *
18783
0783dd397f74 CVS --> Subversion in copyright notices
diego
parents: 15166
diff changeset
6 * Modified for use with MPlayer, detailed changelog at
0783dd397f74 CVS --> Subversion in copyright notices
diego
parents: 15166
diff changeset
7 * http://svn.mplayerhq.hu/mplayer/trunk/
15166
f5537cc95b02 Mark modified imported files as such to comply with GPL ¡ø2a.
diego
parents: 13182
diff changeset
8 * $Id$
f5537cc95b02 Mark modified imported files as such to comply with GPL ¡ø2a.
diego
parents: 13182
diff changeset
9 *
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
10 */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
11
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
12 #ifndef __WINE_WINDEF_H
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
13 #define __WINE_WINDEF_H
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
14
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
15 #ifdef __WINE__
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
16 # include "config.h"
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
17 # undef UNICODE
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
18 #endif
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
19
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
20 #ifdef _EGCS_
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
21 #define __stdcall
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
22 #endif
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
23
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
24 #ifdef __cplusplus
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
25 extern "C" {
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
26 #endif
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
27
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
28 /* Misc. constants. */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
29
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
30 #ifdef FALSE
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
31 #undef FALSE
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
32 #endif
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
33 #define FALSE 0
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
34
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
35 #ifdef TRUE
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
36 #undef TRUE
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
37 #endif
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
38 #define TRUE 1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
39
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
40 #ifdef NULL
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
41 #undef NULL
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
42 #endif
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
43 #define NULL 0
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
44
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
45 /* Macros to map Winelib names to the correct implementation name */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
46 /* depending on __WINE__ and UNICODE macros. */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
47 /* Note that Winelib is purely Win32. */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
48
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
49 #ifdef __WINE__
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
50 # define WINELIB_NAME_AW(func) \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
51 func##_must_be_suffixed_with_W_or_A_in_this_context \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
52 func##_must_be_suffixed_with_W_or_A_in_this_context
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
53 #else /* __WINE__ */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
54 # ifdef UNICODE
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
55 # define WINELIB_NAME_AW(func) func##W
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
56 # else
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
57 # define WINELIB_NAME_AW(func) func##A
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
58 # endif /* UNICODE */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
59 #endif /* __WINE__ */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
60
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
61 #ifdef __WINE__
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
62 # define DECL_WINELIB_TYPE_AW(type) /* nothing */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
63 #else /* __WINE__ */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
64 # define DECL_WINELIB_TYPE_AW(type) typedef WINELIB_NAME_AW(type) type;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
65 #endif /* __WINE__ */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
66
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
67 #ifndef NONAMELESSSTRUCT
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
68 # if defined(__WINE__) || !defined(_FORCENAMELESSSTRUCT)
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
69 # define NONAMELESSSTRUCT
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
70 # endif
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
71 #endif /* !defined(NONAMELESSSTRUCT) */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
72
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
73 #ifndef NONAMELESSUNION
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
74 # if defined(__WINE__) || !defined(_FORCENAMELESSUNION) || !defined(__cplusplus)
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
75 # define NONAMELESSUNION
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
76 # endif
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
77 #endif /* !defined(NONAMELESSUNION) */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
78
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
79 #ifndef NONAMELESSSTRUCT
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
80 #define DUMMYSTRUCTNAME
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
81 #define DUMMYSTRUCTNAME1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
82 #define DUMMYSTRUCTNAME2
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
83 #define DUMMYSTRUCTNAME3
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
84 #define DUMMYSTRUCTNAME4
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
85 #define DUMMYSTRUCTNAME5
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
86 #else /* !defined(NONAMELESSSTRUCT) */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
87 #define DUMMYSTRUCTNAME s
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
88 #define DUMMYSTRUCTNAME1 s1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
89 #define DUMMYSTRUCTNAME2 s2
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
90 #define DUMMYSTRUCTNAME3 s3
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
91 #define DUMMYSTRUCTNAME4 s4
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
92 #define DUMMYSTRUCTNAME5 s5
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
93 #endif /* !defined(NONAMELESSSTRUCT) */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
94
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
95 #ifndef NONAMELESSUNION
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
96 #define DUMMYUNIONNAME
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
97 #define DUMMYUNIONNAME1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
98 #define DUMMYUNIONNAME2
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
99 #define DUMMYUNIONNAME3
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
100 #define DUMMYUNIONNAME4
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
101 #define DUMMYUNIONNAME5
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
102 #else /* !defined(NONAMELESSUNION) */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
103 #define DUMMYUNIONNAME u
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
104 #define DUMMYUNIONNAME1 u1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
105 #define DUMMYUNIONNAME2 u2
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
106 #define DUMMYUNIONNAME3 u3
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
107 #define DUMMYUNIONNAME4 u4
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
108 #define DUMMYUNIONNAME5 u5
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
109 #endif /* !defined(NONAMELESSUNION) */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
110
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
111 /* Calling conventions definitions */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
112
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
113 #ifdef __i386__
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
114 # if defined(__GNUC__) && ((__GNUC__ > 2) || ((__GNUC__ == 2) && (__GNUC_MINOR__ >= 7)))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
115 # ifndef _EGCS_
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
116 #define __stdcall __attribute__((__stdcall__))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
117 #define __cdecl __attribute__((__cdecl__))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
118 # define __RESTORE_ES __asm__ __volatile__("pushl %ds\n\tpopl %es")
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
119 # endif
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
120 # else
186
8f393ca085bf 'You' bug fixed
arpi_esp
parents: 128
diff changeset
121 // # error You need gcc >= 2.7 to build Wine on a 386
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
122 # endif
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
123 #else
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
124 # define __stdcall
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
125 # define __cdecl
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
126 # define __RESTORE_ES
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
127 #endif
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
128
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
129 #define CALLBACK __stdcall
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
130 #define WINAPI __stdcall
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
131 #define APIPRIVATE __stdcall
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
132 #define PASCAL __stdcall
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
133 #define pascal __stdcall
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
134 #define _pascal __stdcall
9978
11cee15b1a8f last mingw32 support patch by Sascha Sommer
alex
parents: 7182
diff changeset
135 #if !defined(__CYGWIN__) && !defined(__MINGW32__)
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
136 #define _stdcall __stdcall
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
137 #define _fastcall __stdcall
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
138 #define __fastcall __stdcall
7182
0bfd137f492a fix some warnings on cygwin, patch by Sylvain Petreolle <spetreolle@yahoo.fr>
atmos4
parents: 6302
diff changeset
139 #endif
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
140 #define __export __stdcall
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
141 #define CDECL __cdecl
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
142 #define _CDECL __cdecl
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
143 #define cdecl __cdecl
9978
11cee15b1a8f last mingw32 support patch by Sascha Sommer
alex
parents: 7182
diff changeset
144 #if !defined(__CYGWIN__) && !defined(__MINGW32__)
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
145 #define _cdecl __cdecl
6302
aa9aca7772de cygwin & darwin fixes by Joey Parrish <joey@yunamusic.com>
arpi
parents: 3548
diff changeset
146 #endif
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
147 #define WINAPIV __cdecl
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
148 #define APIENTRY WINAPI
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
149
9978
11cee15b1a8f last mingw32 support patch by Sascha Sommer
alex
parents: 7182
diff changeset
150 #if !defined(__CYGWIN__) && !defined(__MINGW32__)
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
151 #define __declspec(x)
6302
aa9aca7772de cygwin & darwin fixes by Joey Parrish <joey@yunamusic.com>
arpi
parents: 3548
diff changeset
152 #endif
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
153 #define dllimport
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
154 #define dllexport
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
155
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
156 #define CONST const
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
157
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
158 /* Standard data types. These are the same for emulator and library. */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
159
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
160 typedef void VOID;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
161 typedef int INT;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
162 typedef unsigned int UINT;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
163 typedef unsigned short WORD;
13182
25cb0d6432d4 loader gcc warning fixes and avifile sync
rathann
parents: 9978
diff changeset
164 typedef unsigned long DWORD;
25cb0d6432d4 loader gcc warning fixes and avifile sync
rathann
parents: 9978
diff changeset
165 typedef unsigned long ULONG;
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
166 typedef unsigned char BYTE;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
167 typedef long LONG;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
168 typedef short SHORT;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
169 typedef unsigned short USHORT;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
170 typedef char CHAR;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
171 typedef unsigned char UCHAR;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
172
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
173 typedef LONG SCODE;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
174
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
175 /* Some systems might have wchar_t, but we really need 16 bit characters */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
176 typedef unsigned short WCHAR;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
177 typedef int WIN_BOOL;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
178 typedef double DATE;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
179 typedef double DOUBLE;
128
28091b3caff9 DLL loader updated from avifile-0.60beta4
arpi_esp
parents: 1
diff changeset
180 typedef long long LONGLONG;
28091b3caff9 DLL loader updated from avifile-0.60beta4
arpi_esp
parents: 1
diff changeset
181 typedef unsigned long long ULONGLONG;
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
182
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
183 /* FIXME: Wine does not compile with strict on, therefore strict
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
184 * handles are presently only usable on machines where sizeof(UINT) ==
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
185 * sizeof(void*). HANDLEs are supposed to be void* but a large amount
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
186 * of WINE code operates on HANDLES as if they are UINTs. So to WINE
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
187 * they exist as UINTs but to the Winelib user who turns on strict,
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
188 * they exist as void*. If there is a size difference between UINT and
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
189 * void* then things get ugly. */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
190 #ifdef STRICT
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
191 typedef VOID* HANDLE;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
192 #else
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
193 typedef UINT HANDLE;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
194 #endif
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
195
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
196
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
197 typedef HANDLE *LPHANDLE;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
198
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
199 /* Integer types. These are the same for emulator and library. */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
200 typedef UINT WPARAM;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
201 typedef LONG LPARAM;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
202 typedef LONG HRESULT;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
203 typedef LONG LRESULT;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
204 typedef WORD ATOM;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
205 typedef WORD CATCHBUF[9];
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
206 typedef WORD *LPCATCHBUF;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
207 typedef HANDLE HHOOK;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
208 typedef HANDLE HMONITOR;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
209 typedef DWORD LCID;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
210 typedef WORD LANGID;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
211 typedef DWORD LCTYPE;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
212 typedef float FLOAT;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
213
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
214 /* Pointers types. These are the same for emulator and library. */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
215 /* winnt types */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
216 typedef VOID *PVOID;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
217 typedef const void *PCVOID;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
218 typedef CHAR *PCHAR;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
219 typedef UCHAR *PUCHAR;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
220 typedef BYTE *PBYTE;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
221 typedef WORD *PWORD;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
222 typedef USHORT *PUSHORT;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
223 typedef SHORT *PSHORT;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
224 typedef ULONG *PULONG;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
225 typedef LONG *PLONG;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
226 typedef DWORD *PDWORD;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
227 /* common win32 types */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
228 typedef CHAR *LPSTR;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
229 typedef CHAR *PSTR;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
230 typedef const CHAR *LPCSTR;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
231 typedef const CHAR *PCSTR;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
232 typedef WCHAR *LPWSTR;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
233 typedef WCHAR *PWSTR;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
234 typedef const WCHAR *LPCWSTR;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
235 typedef const WCHAR *PCWSTR;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
236 typedef BYTE *LPBYTE;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
237 typedef WORD *LPWORD;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
238 typedef DWORD *LPDWORD;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
239 typedef LONG *LPLONG;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
240 typedef VOID *LPVOID;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
241 typedef const VOID *LPCVOID;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
242 typedef INT *PINT;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
243 typedef INT *LPINT;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
244 typedef UINT *PUINT;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
245 typedef UINT *LPUINT;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
246 typedef FLOAT *PFLOAT;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
247 typedef FLOAT *LPFLOAT;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
248 typedef WIN_BOOL *PWIN_BOOL;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
249 typedef WIN_BOOL *LPWIN_BOOL;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
250
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
251 /* Special case: a segmented pointer is just a pointer in the user's code. */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
252
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
253 #ifdef __WINE__
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
254 typedef DWORD SEGPTR;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
255 #else
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
256 typedef void* SEGPTR;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
257 #endif /* __WINE__ */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
258
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
259 /* Handle types that exist both in Win16 and Win32. */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
260
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
261 #ifdef STRICT
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
262 #define DECLARE_HANDLE(a) \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
263 typedef struct a##__ { int unused; } *a; \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
264 typedef a *P##a; \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
265 typedef a *LP##a
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
266 #else /*STRICT*/
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
267 #define DECLARE_HANDLE(a) \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
268 typedef HANDLE a; \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
269 typedef a *P##a; \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
270 typedef a *LP##a
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
271 #endif /*STRICT*/
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
272
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
273 DECLARE_HANDLE(HACMDRIVERID);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
274 DECLARE_HANDLE(HACMDRIVER);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
275 DECLARE_HANDLE(HACMOBJ);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
276 DECLARE_HANDLE(HACMSTREAM);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
277 DECLARE_HANDLE(HMETAFILEPICT);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
278
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
279 DECLARE_HANDLE(HACCEL);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
280 DECLARE_HANDLE(HBITMAP);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
281 DECLARE_HANDLE(HBRUSH);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
282 DECLARE_HANDLE(HCOLORSPACE);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
283 DECLARE_HANDLE(HCURSOR);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
284 DECLARE_HANDLE(HDC);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
285 DECLARE_HANDLE(HDROP);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
286 DECLARE_HANDLE(HDRVR);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
287 DECLARE_HANDLE(HDWP);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
288 DECLARE_HANDLE(HENHMETAFILE);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
289 DECLARE_HANDLE(HFILE);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
290 DECLARE_HANDLE(HFONT);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
291 DECLARE_HANDLE(HICON);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
292 DECLARE_HANDLE(HINSTANCE);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
293 DECLARE_HANDLE(HKEY);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
294 DECLARE_HANDLE(HMENU);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
295 DECLARE_HANDLE(HMETAFILE);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
296 DECLARE_HANDLE(HMIDI);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
297 DECLARE_HANDLE(HMIDIIN);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
298 DECLARE_HANDLE(HMIDIOUT);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
299 DECLARE_HANDLE(HMIDISTRM);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
300 DECLARE_HANDLE(HMIXER);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
301 DECLARE_HANDLE(HMIXEROBJ);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
302 DECLARE_HANDLE(HMMIO);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
303 DECLARE_HANDLE(HPALETTE);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
304 DECLARE_HANDLE(HPEN);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
305 DECLARE_HANDLE(HQUEUE);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
306 DECLARE_HANDLE(HRGN);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
307 DECLARE_HANDLE(HRSRC);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
308 DECLARE_HANDLE(HTASK);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
309 DECLARE_HANDLE(HWAVE);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
310 DECLARE_HANDLE(HWAVEIN);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
311 DECLARE_HANDLE(HWAVEOUT);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
312 DECLARE_HANDLE(HWINSTA);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
313 DECLARE_HANDLE(HDESK);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
314 DECLARE_HANDLE(HWND);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
315 DECLARE_HANDLE(HKL);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
316 DECLARE_HANDLE(HIC);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
317 DECLARE_HANDLE(HRASCONN);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
318
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
319 /* Handle types that must remain interchangeable even with strict on */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
320
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
321 typedef HINSTANCE HMODULE;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
322 typedef HANDLE HGDIOBJ;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
323 typedef HANDLE HGLOBAL;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
324 typedef HANDLE HLOCAL;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
325 typedef HANDLE GLOBALHANDLE;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
326 typedef HANDLE LOCALHANDLE;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
327
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
328 /* Callback function pointers types */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
329 //WIN_BOOL CALLBACK DATEFMT_ENUMPROCA(LPSTR);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
330
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
331 typedef WIN_BOOL CALLBACK (* DATEFMT_ENUMPROCA)(LPSTR);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
332 typedef WIN_BOOL CALLBACK (* DATEFMT_ENUMPROCW)(LPWSTR);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
333 DECL_WINELIB_TYPE_AW(DATEFMT_ENUMPROC)
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
334 typedef WIN_BOOL CALLBACK (*DLGPROC)(HWND,UINT,WPARAM,LPARAM);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
335 typedef LRESULT CALLBACK (*DRIVERPROC)(DWORD,HDRVR,UINT,LPARAM,LPARAM);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
336 typedef INT CALLBACK (*EDITWORDBREAKPROCA)(LPSTR,INT,INT,INT);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
337 typedef INT CALLBACK (*EDITWORDBREAKPROCW)(LPWSTR,INT,INT,INT);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
338 DECL_WINELIB_TYPE_AW(EDITWORDBREAKPROC)
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
339 typedef LRESULT CALLBACK (*FARPROC)();
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
340 typedef INT CALLBACK (*PROC)();
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
341 typedef WIN_BOOL CALLBACK (*GRAYSTRINGPROC)(HDC,LPARAM,INT);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
342 typedef LRESULT CALLBACK (*HOOKPROC)(INT,WPARAM,LPARAM);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
343 typedef WIN_BOOL CALLBACK (*PROPENUMPROCA)(HWND,LPCSTR,HANDLE);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
344 typedef WIN_BOOL CALLBACK (*PROPENUMPROCW)(HWND,LPCWSTR,HANDLE);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
345 DECL_WINELIB_TYPE_AW(PROPENUMPROC)
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
346 typedef WIN_BOOL CALLBACK (*PROPENUMPROCEXA)(HWND,LPCSTR,HANDLE,LPARAM);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
347 typedef WIN_BOOL CALLBACK (*PROPENUMPROCEXW)(HWND,LPCWSTR,HANDLE,LPARAM);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
348 DECL_WINELIB_TYPE_AW(PROPENUMPROCEX)
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
349 typedef WIN_BOOL CALLBACK (* TIMEFMT_ENUMPROCA)(LPSTR);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
350 typedef WIN_BOOL CALLBACK (* TIMEFMT_ENUMPROCW)(LPWSTR);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
351 DECL_WINELIB_TYPE_AW(TIMEFMT_ENUMPROC)
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
352 typedef VOID CALLBACK (*TIMERPROC)(HWND,UINT,UINT,DWORD);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
353 typedef WIN_BOOL CALLBACK (*WNDENUMPROC)(HWND,LPARAM);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
354 typedef LRESULT CALLBACK (*WNDPROC)(HWND,UINT,WPARAM,LPARAM);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
355
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
356 /*----------------------------------------------------------------------------
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
357 ** FIXME: Better isolate Wine's reliance on the xxx16 type definitions.
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
358 ** For now, we just isolate them to make the situation clear.
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
359 **--------------------------------------------------------------------------*/
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
360 /*
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
361 * Basic type definitions for 16 bit variations on Windows types.
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
362 * These types are provided mostly to insure compatibility with
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
363 * 16 bit windows code.
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
364 */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
365
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
366 #ifndef __WINE_WINDEF16_H
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
367 #define __WINE_WINDEF16_H
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
368
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
369 #include "windef.h"
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
370
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
371 /* Standard data types */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
372
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
373 typedef short INT16;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
374 typedef unsigned short UINT16;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
375 typedef unsigned short WIN_BOOL16;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
376
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
377 typedef UINT16 HANDLE16;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
378 typedef HANDLE16 *LPHANDLE16;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
379
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
380 typedef UINT16 WPARAM16;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
381 typedef INT16 *LPINT16;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
382 typedef UINT16 *LPUINT16;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
383
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
384 #define DECLARE_HANDLE16(a) \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
385 typedef HANDLE16 a##16; \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
386 typedef a##16 *P##a##16; \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
387 typedef a##16 *NP##a##16; \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
388 typedef a##16 *LP##a##16
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
389
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
390 DECLARE_HANDLE16(HACMDRIVERID);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
391 DECLARE_HANDLE16(HACMDRIVER);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
392 DECLARE_HANDLE16(HACMOBJ);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
393 DECLARE_HANDLE16(HACMSTREAM);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
394 DECLARE_HANDLE16(HMETAFILEPICT);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
395
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
396 DECLARE_HANDLE16(HACCEL);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
397 DECLARE_HANDLE16(HBITMAP);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
398 DECLARE_HANDLE16(HBRUSH);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
399 DECLARE_HANDLE16(HCOLORSPACE);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
400 DECLARE_HANDLE16(HCURSOR);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
401 DECLARE_HANDLE16(HDC);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
402 DECLARE_HANDLE16(HDROP);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
403 DECLARE_HANDLE16(HDRVR);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
404 DECLARE_HANDLE16(HDWP);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
405 DECLARE_HANDLE16(HENHMETAFILE);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
406 DECLARE_HANDLE16(HFILE);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
407 DECLARE_HANDLE16(HFONT);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
408 DECLARE_HANDLE16(HICON);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
409 DECLARE_HANDLE16(HINSTANCE);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
410 DECLARE_HANDLE16(HKEY);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
411 DECLARE_HANDLE16(HMENU);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
412 DECLARE_HANDLE16(HMETAFILE);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
413 DECLARE_HANDLE16(HMIDI);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
414 DECLARE_HANDLE16(HMIDIIN);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
415 DECLARE_HANDLE16(HMIDIOUT);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
416 DECLARE_HANDLE16(HMIDISTRM);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
417 DECLARE_HANDLE16(HMIXER);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
418 DECLARE_HANDLE16(HMIXEROBJ);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
419 DECLARE_HANDLE16(HMMIO);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
420 DECLARE_HANDLE16(HPALETTE);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
421 DECLARE_HANDLE16(HPEN);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
422 DECLARE_HANDLE16(HQUEUE);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
423 DECLARE_HANDLE16(HRGN);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
424 DECLARE_HANDLE16(HRSRC);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
425 DECLARE_HANDLE16(HTASK);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
426 DECLARE_HANDLE16(HWAVE);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
427 DECLARE_HANDLE16(HWAVEIN);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
428 DECLARE_HANDLE16(HWAVEOUT);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
429 DECLARE_HANDLE16(HWINSTA);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
430 DECLARE_HANDLE16(HDESK);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
431 DECLARE_HANDLE16(HWND);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
432 DECLARE_HANDLE16(HKL);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
433 DECLARE_HANDLE16(HIC);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
434 DECLARE_HANDLE16(HRASCONN);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
435 #undef DECLARE_HANDLE16
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
436
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
437 typedef HINSTANCE16 HMODULE16;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
438 typedef HANDLE16 HGDIOBJ16;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
439 typedef HANDLE16 HGLOBAL16;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
440 typedef HANDLE16 HLOCAL16;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
441
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
442 /* The SIZE structure */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
443 typedef struct
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
444 {
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
445 INT16 cx;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
446 INT16 cy;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
447 } SIZE16, *PSIZE16, *LPSIZE16;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
448
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
449 /* The POINT structure */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
450
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
451 typedef struct
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
452 {
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
453 INT16 x;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
454 INT16 y;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
455 } POINT16, *PPOINT16, *LPPOINT16;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
456
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
457 /* The RECT structure */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
458
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
459 typedef struct
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
460 {
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
461 INT16 left;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
462 INT16 top;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
463 INT16 right;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
464 INT16 bottom;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
465 } RECT16, *LPRECT16;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
466
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
467 /* Callback function pointers types */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
468
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
469 typedef LRESULT CALLBACK (*DRIVERPROC16)(DWORD,HDRVR16,UINT16,LPARAM,LPARAM);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
470 typedef WIN_BOOL16 CALLBACK (*DLGPROC16)(HWND16,UINT16,WPARAM16,LPARAM);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
471 typedef INT16 CALLBACK (*EDITWORDBREAKPROC16)(LPSTR,INT16,INT16,INT16);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
472 typedef LRESULT CALLBACK (*FARPROC16)();
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
473 typedef INT16 CALLBACK (*PROC16)();
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
474 typedef WIN_BOOL16 CALLBACK (*GRAYSTRINGPROC16)(HDC16,LPARAM,INT16);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
475 typedef LRESULT CALLBACK (*HOOKPROC16)(INT16,WPARAM16,LPARAM);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
476 typedef WIN_BOOL16 CALLBACK (*PROPENUMPROC16)(HWND16,SEGPTR,HANDLE16);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
477 typedef VOID CALLBACK (*TIMERPROC16)(HWND16,UINT16,UINT16,DWORD);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
478 typedef LRESULT CALLBACK (*WNDENUMPROC16)(HWND16,LPARAM);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
479 typedef LRESULT CALLBACK (*WNDPROC16)(HWND16,UINT16,WPARAM16,LPARAM);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
480
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
481 #endif /* __WINE_WINDEF16_H */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
482
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
483 /* Define some empty macros for compatibility with Windows code. */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
484
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
485 #ifndef __WINE__
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
486 #define NEAR
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
487 #define FAR
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
488 #define near
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
489 #define far
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
490 #define _near
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
491 #define _far
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
492 #define IN
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
493 #define OUT
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
494 #define OPTIONAL
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
495 #endif /* __WINE__ */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
496
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
497 /* Macro for structure packing. */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
498
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
499 #ifdef __GNUC__
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
500 #ifndef _EGCS_
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
501 #define WINE_PACKED __attribute__((packed))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
502 #define WINE_UNUSED __attribute__((unused))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
503 #define WINE_NORETURN __attribute__((noreturn))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
504 #endif
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
505 #else
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
506 #define WINE_PACKED /* nothing */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
507 #define WINE_UNUSED /* nothing */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
508 #define WINE_NORETURN /* nothing */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
509 #endif
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
510
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
511 /* Macros to split words and longs. */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
512
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
513 #define LOBYTE(w) ((BYTE)(WORD)(w))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
514 #define HIBYTE(w) ((BYTE)((WORD)(w) >> 8))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
515
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
516 #define LOWORD(l) ((WORD)(DWORD)(l))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
517 #define HIWORD(l) ((WORD)((DWORD)(l) >> 16))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
518
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
519 #define SLOWORD(l) ((INT16)(LONG)(l))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
520 #define SHIWORD(l) ((INT16)((LONG)(l) >> 16))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
521
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
522 #define MAKEWORD(low,high) ((WORD)(((BYTE)(low)) | ((WORD)((BYTE)(high))) << 8))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
523 #define MAKELONG(low,high) ((LONG)(((WORD)(low)) | (((DWORD)((WORD)(high))) << 16)))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
524 #define MAKELPARAM(low,high) ((LPARAM)MAKELONG(low,high))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
525 #define MAKEWPARAM(low,high) ((WPARAM)MAKELONG(low,high))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
526 #define MAKELRESULT(low,high) ((LRESULT)MAKELONG(low,high))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
527 #define MAKEINTATOM(atom) ((LPCSTR)MAKELONG((atom),0))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
528
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
529 #define SELECTOROF(ptr) (HIWORD(ptr))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
530 #define OFFSETOF(ptr) (LOWORD(ptr))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
531
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
532 #ifdef __WINE__
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
533 /* macros to set parts of a DWORD (not in the Windows API) */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
534 #define SET_LOWORD(dw,val) ((dw) = ((dw) & 0xffff0000) | LOWORD(val))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
535 #define SET_LOBYTE(dw,val) ((dw) = ((dw) & 0xffffff00) | LOBYTE(val))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
536 #define SET_HIBYTE(dw,val) ((dw) = ((dw) & 0xffff00ff) | (LOWORD(val) & 0xff00))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
537 #define ADD_LOWORD(dw,val) ((dw) = ((dw) & 0xffff0000) | LOWORD((DWORD)(dw)+(val)))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
538 #endif
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
539
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
540 /* Macros to access unaligned or wrong-endian WORDs and DWORDs. */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
541 /* Note: These macros are semantically broken, at least for wrc. wrc
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
542 spits out data in the platform's current binary format, *not* in
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
543 little-endian format. These macros are used throughout the resource
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
544 code to load and store data to the resources. Since it is unlikely
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
545 that we'll ever be dealing with little-endian resource data, the
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
546 byte-swapping nature of these macros has been disabled. Rather than
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
547 remove the use of these macros from the resource loading code, the
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
548 macros have simply been disabled. In the future, someone may want
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
549 to reactivate these macros for other purposes. In that case, the
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
550 resource code will have to be modified to use different macros. */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
551
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
552 #if 1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
553 #define PUT_WORD(ptr,w) (*(WORD *)(ptr) = (w))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
554 #define GET_WORD(ptr) (*(WORD *)(ptr))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
555 #define PUT_DWORD(ptr,dw) (*(DWORD *)(ptr) = (dw))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
556 #define GET_DWORD(ptr) (*(DWORD *)(ptr))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
557 #else
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
558 #define PUT_WORD(ptr,w) (*(BYTE *)(ptr) = LOBYTE(w), \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
559 *((BYTE *)(ptr) + 1) = HIBYTE(w))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
560 #define GET_WORD(ptr) ((WORD)(*(BYTE *)(ptr) | \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
561 (WORD)(*((BYTE *)(ptr)+1) << 8)))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
562 #define PUT_DWORD(ptr,dw) (PUT_WORD((ptr),LOWORD(dw)), \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
563 PUT_WORD((WORD *)(ptr)+1,HIWORD(dw)))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
564 #define GET_DWORD(ptr) ((DWORD)(GET_WORD(ptr) | \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
565 ((DWORD)GET_WORD((WORD *)(ptr)+1) << 16)))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
566 #endif /* 1 */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
567
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
568 /* min and max macros */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
569 #define __max(a,b) (((a) > (b)) ? (a) : (b))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
570 #define __min(a,b) (((a) < (b)) ? (a) : (b))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
571 #ifndef max
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
572 #define max(a,b) (((a) > (b)) ? (a) : (b))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
573 #endif
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
574 #ifndef min
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
575 #define min(a,b) (((a) < (b)) ? (a) : (b))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
576 #endif
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
577
9978
11cee15b1a8f last mingw32 support patch by Sascha Sommer
alex
parents: 7182
diff changeset
578 #ifndef _MAX_PATH
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
579 #define _MAX_PATH 260
9978
11cee15b1a8f last mingw32 support patch by Sascha Sommer
alex
parents: 7182
diff changeset
580 #endif
11cee15b1a8f last mingw32 support patch by Sascha Sommer
alex
parents: 7182
diff changeset
581 #ifndef MAX_PATH
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
582 #define MAX_PATH 260
9978
11cee15b1a8f last mingw32 support patch by Sascha Sommer
alex
parents: 7182
diff changeset
583 #endif
11cee15b1a8f last mingw32 support patch by Sascha Sommer
alex
parents: 7182
diff changeset
584 #ifndef _MAX_DRIVE
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
585 #define _MAX_DRIVE 3
9978
11cee15b1a8f last mingw32 support patch by Sascha Sommer
alex
parents: 7182
diff changeset
586 #endif
11cee15b1a8f last mingw32 support patch by Sascha Sommer
alex
parents: 7182
diff changeset
587 #ifndef _MAX_DIR
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
588 #define _MAX_DIR 256
9978
11cee15b1a8f last mingw32 support patch by Sascha Sommer
alex
parents: 7182
diff changeset
589 #endif
11cee15b1a8f last mingw32 support patch by Sascha Sommer
alex
parents: 7182
diff changeset
590 #ifndef _MAX_FNAME
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
591 #define _MAX_FNAME 255
9978
11cee15b1a8f last mingw32 support patch by Sascha Sommer
alex
parents: 7182
diff changeset
592 #endif
11cee15b1a8f last mingw32 support patch by Sascha Sommer
alex
parents: 7182
diff changeset
593 #ifndef _MAX_EXT
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
594 #define _MAX_EXT 256
9978
11cee15b1a8f last mingw32 support patch by Sascha Sommer
alex
parents: 7182
diff changeset
595 #endif
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
596
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
597 #define HFILE_ERROR16 ((HFILE16)-1)
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
598 #define HFILE_ERROR ((HFILE)-1)
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
599
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
600 /* The SIZE structure */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
601 typedef struct tagSIZE
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
602 {
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
603 INT cx;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
604 INT cy;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
605 } SIZE, *PSIZE, *LPSIZE;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
606
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
607
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
608 typedef SIZE SIZEL, *PSIZEL, *LPSIZEL;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
609
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
610 #define CONV_SIZE16TO32(s16,s32) \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
611 ((s32)->cx = (INT)(s16)->cx, (s32)->cy = (INT)(s16)->cy)
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
612 #define CONV_SIZE32TO16(s32,s16) \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
613 ((s16)->cx = (INT16)(s32)->cx, (s16)->cy = (INT16)(s32)->cy)
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
614
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
615 /* The POINT structure */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
616 typedef struct tagPOINT
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
617 {
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
618 LONG x;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
619 LONG y;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
620 } POINT, *PPOINT, *LPPOINT;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
621
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
622 typedef struct _POINTL
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
623 {
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
624 LONG x;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
625 LONG y;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
626 } POINTL;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
627
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
628 #define CONV_POINT16TO32(p16,p32) \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
629 ((p32)->x = (INT)(p16)->x, (p32)->y = (INT)(p16)->y)
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
630 #define CONV_POINT32TO16(p32,p16) \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
631 ((p16)->x = (INT16)(p32)->x, (p16)->y = (INT16)(p32)->y)
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
632
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
633 #define MAKEPOINT16(l) (*((POINT16 *)&(l)))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
634
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
635 /* The POINTS structure */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
636
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
637 typedef struct tagPOINTS
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
638 {
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
639 SHORT x;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
640 SHORT y;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
641 } POINTS, *PPOINTS, *LPPOINTS;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
642
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
643
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
644 #define MAKEPOINTS(l) (*((POINTS *)&(l)))
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
645
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
646
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
647 /* The RECT structure */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
648 typedef struct tagRECT
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
649 {
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
650 short left;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
651 short top;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
652 short right;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
653 short bottom;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
654 } RECT, *PRECT, *LPRECT;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
655 typedef const RECT *LPCRECT;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
656
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
657
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
658 typedef struct tagRECTL
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
659 {
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
660 LONG left;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
661 LONG top;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
662 LONG right;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
663 LONG bottom;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
664 } RECTL, *PRECTL, *LPRECTL;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
665
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
666 typedef const RECTL *LPCRECTL;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
667
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
668 #define CONV_RECT16TO32(r16,r32) \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
669 ((r32)->left = (INT)(r16)->left, (r32)->top = (INT)(r16)->top, \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
670 (r32)->right = (INT)(r16)->right, (r32)->bottom = (INT)(r16)->bottom)
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
671 #define CONV_RECT32TO16(r32,r16) \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
672 ((r16)->left = (INT16)(r32)->left, (r16)->top = (INT16)(r32)->top, \
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
673 (r16)->right = (INT16)(r32)->right, (r16)->bottom = (INT16)(r32)->bottom)
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
674
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
675 #ifdef __cplusplus
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
676 }
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
677 #endif
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
678
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
679 #endif /* __WINE_WINDEF_H */