Changed the pixmap to look like the windows default application icon.
[wine] / include / winbase.h
1 #ifndef __WINE_WINBASE_H
2 #define __WINE_WINBASE_H
3
4 #include "basetsd.h"
5 #include "winnt.h"
6 #include "wine/winestring.h"
7
8 #include "pshpack1.h"
9
10
11 #ifdef __cplusplus
12 extern "C" {
13 #endif
14
15 typedef struct tagCOORD {
16     INT16 x;
17     INT16 y;
18 } COORD, *LPCOORD;
19
20
21   /* Windows Exit Procedure flag values */
22 #define WEP_FREE_DLL        0
23 #define WEP_SYSTEM_EXIT     1
24
25 typedef DWORD (CALLBACK *LPTHREAD_START_ROUTINE)(LPVOID);
26
27 #define EXCEPTION_DEBUG_EVENT       1
28 #define CREATE_THREAD_DEBUG_EVENT   2
29 #define CREATE_PROCESS_DEBUG_EVENT  3
30 #define EXIT_THREAD_DEBUG_EVENT     4
31 #define EXIT_PROCESS_DEBUG_EVENT    5
32 #define LOAD_DLL_DEBUG_EVENT        6
33 #define UNLOAD_DLL_DEBUG_EVENT      7
34 #define OUTPUT_DEBUG_STRING_EVENT   8
35 #define RIP_EVENT                   9
36
37 typedef struct _EXCEPTION_DEBUG_INFO {
38     EXCEPTION_RECORD ExceptionRecord;
39     DWORD dwFirstChance;
40 } EXCEPTION_DEBUG_INFO;
41
42 typedef struct _CREATE_THREAD_DEBUG_INFO {
43     HANDLE hThread;
44     LPVOID lpThreadLocalBase;
45     LPTHREAD_START_ROUTINE lpStartAddress;
46 } CREATE_THREAD_DEBUG_INFO;
47
48 typedef struct _CREATE_PROCESS_DEBUG_INFO {
49     HANDLE hFile;
50     HANDLE hProcess;
51     HANDLE hThread;
52     LPVOID lpBaseOfImage;
53     DWORD dwDebugInfoFileOffset;
54     DWORD nDebugInfoSize;
55     LPVOID lpThreadLocalBase;
56     LPTHREAD_START_ROUTINE lpStartAddress;
57     LPVOID lpImageName;
58     WORD fUnicode;
59 } CREATE_PROCESS_DEBUG_INFO;
60
61 typedef struct _EXIT_THREAD_DEBUG_INFO {
62     DWORD dwExitCode;
63 } EXIT_THREAD_DEBUG_INFO;
64
65 typedef struct _EXIT_PROCESS_DEBUG_INFO {
66     DWORD dwExitCode;
67 } EXIT_PROCESS_DEBUG_INFO;
68
69 typedef struct _LOAD_DLL_DEBUG_INFO {
70     HANDLE hFile;
71     LPVOID   lpBaseOfDll;
72     DWORD    dwDebugInfoFileOffset;
73     DWORD    nDebugInfoSize;
74     LPVOID   lpImageName;
75     WORD     fUnicode;
76 } LOAD_DLL_DEBUG_INFO;
77
78 typedef struct _UNLOAD_DLL_DEBUG_INFO {
79     LPVOID lpBaseOfDll;
80 } UNLOAD_DLL_DEBUG_INFO;
81
82 typedef struct _OUTPUT_DEBUG_STRING_INFO {
83     LPSTR lpDebugStringData;
84     WORD  fUnicode;
85     WORD  nDebugStringLength;
86 } OUTPUT_DEBUG_STRING_INFO;
87
88 typedef struct _RIP_INFO {
89     DWORD dwError;
90     DWORD dwType;
91 } RIP_INFO;
92
93 typedef struct _DEBUG_EVENT {
94     DWORD dwDebugEventCode;
95     DWORD dwProcessId;
96     DWORD dwThreadId;
97     union {
98         EXCEPTION_DEBUG_INFO      Exception;
99         CREATE_THREAD_DEBUG_INFO  CreateThread;
100         CREATE_PROCESS_DEBUG_INFO CreateProcessInfo;
101         EXIT_THREAD_DEBUG_INFO    ExitThread;
102         EXIT_PROCESS_DEBUG_INFO   ExitProcess;
103         LOAD_DLL_DEBUG_INFO       LoadDll;
104         UNLOAD_DLL_DEBUG_INFO     UnloadDll;
105         OUTPUT_DEBUG_STRING_INFO  DebugString;
106         RIP_INFO                  RipInfo;
107     } u;
108 } DEBUG_EVENT, *LPDEBUG_EVENT;
109
110 #define OFS_MAXPATHNAME 128
111 typedef struct
112 {
113     BYTE cBytes;
114     BYTE fFixedDisk;
115     WORD nErrCode;
116     BYTE reserved[4];
117     BYTE szPathName[OFS_MAXPATHNAME];
118 } OFSTRUCT, *LPOFSTRUCT;
119
120 #define OF_READ               0x0000
121 #define OF_WRITE              0x0001
122 #define OF_READWRITE          0x0002
123 #define OF_SHARE_COMPAT       0x0000
124 #define OF_SHARE_EXCLUSIVE    0x0010
125 #define OF_SHARE_DENY_WRITE   0x0020
126 #define OF_SHARE_DENY_READ    0x0030
127 #define OF_SHARE_DENY_NONE    0x0040
128 #define OF_PARSE              0x0100
129 #define OF_DELETE             0x0200
130 #define OF_VERIFY             0x0400   /* Used with OF_REOPEN */
131 #define OF_SEARCH             0x0400   /* Used without OF_REOPEN */
132 #define OF_CANCEL             0x0800
133 #define OF_CREATE             0x1000
134 #define OF_PROMPT             0x2000
135 #define OF_EXIST              0x4000
136 #define OF_REOPEN             0x8000
137
138 /* SetErrorMode values */
139 #define SEM_FAILCRITICALERRORS      0x0001
140 #define SEM_NOGPFAULTERRORBOX       0x0002
141 #define SEM_NOALIGNMENTFAULTEXCEPT  0x0004
142 #define SEM_NOOPENFILEERRORBOX      0x8000
143
144 /* CopyFileEx flags */
145 #define COPY_FILE_FAIL_IF_EXISTS        0x00000001
146 #define COPY_FILE_RESTARTABLE           0x00000002
147 #define COPY_FILE_OPEN_SOURCE_FOR_WRITE 0x00000004
148
149 /* GetTempFileName() Flags */
150 #define TF_FORCEDRIVE           0x80
151
152 #define DRIVE_CANNOTDETERMINE      0
153 #define DRIVE_DOESNOTEXIST         1
154 #define DRIVE_REMOVABLE            2
155 #define DRIVE_FIXED                3
156 #define DRIVE_REMOTE               4
157 /* Win32 additions */
158 #define DRIVE_CDROM                5
159 #define DRIVE_RAMDISK              6
160
161 /* The security attributes structure */
162 typedef struct
163 {
164     DWORD   nLength;
165     LPVOID  lpSecurityDescriptor;
166     BOOL  bInheritHandle;
167 } SECURITY_ATTRIBUTES, *PSECURITY_ATTRIBUTES, *LPSECURITY_ATTRIBUTES;
168
169 #ifndef _FILETIME_
170 #define _FILETIME_
171 /* 64 bit number of 100 nanoseconds intervals since January 1, 1601 */
172 typedef struct
173 {
174   DWORD  dwLowDateTime;
175   DWORD  dwHighDateTime;
176 } FILETIME, *LPFILETIME;
177 #endif /* _FILETIME_ */
178
179 /* Find* structures */
180 typedef struct
181 {
182     DWORD     dwFileAttributes;
183     FILETIME  ftCreationTime;
184     FILETIME  ftLastAccessTime;
185     FILETIME  ftLastWriteTime;
186     DWORD     nFileSizeHigh;
187     DWORD     nFileSizeLow;
188     DWORD     dwReserved0;
189     DWORD     dwReserved1;
190     CHAR      cFileName[260];
191     CHAR      cAlternateFileName[14];
192 } WIN32_FIND_DATAA, *LPWIN32_FIND_DATAA;
193
194 typedef struct
195 {
196     DWORD     dwFileAttributes;
197     FILETIME  ftCreationTime;
198     FILETIME  ftLastAccessTime;
199     FILETIME  ftLastWriteTime;
200     DWORD     nFileSizeHigh;
201     DWORD     nFileSizeLow;
202     DWORD     dwReserved0;
203     DWORD     dwReserved1;
204     WCHAR     cFileName[260];
205     WCHAR     cAlternateFileName[14];
206 } WIN32_FIND_DATAW, *LPWIN32_FIND_DATAW;
207
208 DECL_WINELIB_TYPE_AW(WIN32_FIND_DATA)
209 DECL_WINELIB_TYPE_AW(LPWIN32_FIND_DATA)
210
211 typedef struct
212 {
213     LPVOID lpData;
214     DWORD cbData;
215     BYTE cbOverhead;
216     BYTE iRegionIndex;
217     WORD wFlags;
218     union {
219         struct {
220             HANDLE hMem;
221             DWORD dwReserved[3];
222         } Block;
223         struct {
224             DWORD dwCommittedSize;
225             DWORD dwUnCommittedSize;
226             LPVOID lpFirstBlock;
227             LPVOID lpLastBlock;
228         } Region;
229     } Foo;
230 } PROCESS_HEAP_ENTRY, *LPPROCESS_HEAP_ENTRY;
231
232 #define PROCESS_HEAP_REGION                   0x0001
233 #define PROCESS_HEAP_UNCOMMITTED_RANGE        0x0002
234 #define PROCESS_HEAP_ENTRY_BUSY               0x0004
235 #define PROCESS_HEAP_ENTRY_MOVEABLE           0x0010
236 #define PROCESS_HEAP_ENTRY_DDESHARE           0x0020
237
238 #define INVALID_HANDLE_VALUE16  ((HANDLE16) -1)
239 #define INVALID_HANDLE_VALUE  ((HANDLE) -1)
240
241 /* comm */
242
243 #define CBR_110 0xFF10
244 #define CBR_300 0xFF11
245 #define CBR_600 0xFF12
246 #define CBR_1200        0xFF13
247 #define CBR_2400        0xFF14
248 #define CBR_4800        0xFF15
249 #define CBR_9600        0xFF16
250 #define CBR_14400       0xFF17
251 #define CBR_19200       0xFF18
252 #define CBR_38400       0xFF1B
253 #define CBR_56000       0xFF1F
254 #define CBR_128000      0xFF23
255 #define CBR_256000      0xFF27
256
257 #define NOPARITY        0
258 #define ODDPARITY       1
259 #define EVENPARITY      2
260 #define MARKPARITY      3
261 #define SPACEPARITY     4
262 #define ONESTOPBIT      0
263 #define ONE5STOPBITS    1
264 #define TWOSTOPBITS     2
265
266 #define IGNORE          0
267 #define INFINITE16      0xFFFF
268 #define INFINITE      0xFFFFFFFF
269
270 #define CE_RXOVER       0x0001
271 #define CE_OVERRUN      0x0002
272 #define CE_RXPARITY     0x0004
273 #define CE_FRAME        0x0008
274 #define CE_BREAK        0x0010
275 #define CE_CTSTO        0x0020
276 #define CE_DSRTO        0x0040
277 #define CE_RLSDTO       0x0080
278 #define CE_TXFULL       0x0100
279 #define CE_PTO          0x0200
280 #define CE_IOE          0x0400
281 #define CE_DNS          0x0800
282 #define CE_OOP          0x1000
283 #define CE_MODE 0x8000
284
285 #define IE_BADID        -1
286 #define IE_OPEN -2
287 #define IE_NOPEN        -3
288 #define IE_MEMORY       -4
289 #define IE_DEFAULT      -5
290 #define IE_HARDWARE     -10
291 #define IE_BYTESIZE     -11
292 #define IE_BAUDRATE     -12
293
294 #define EV_RXCHAR       0x0001
295 #define EV_RXFLAG       0x0002
296 #define EV_TXEMPTY      0x0004
297 #define EV_CTS          0x0008
298 #define EV_DSR          0x0010
299 #define EV_RLSD 0x0020
300 #define EV_BREAK        0x0040
301 #define EV_ERR          0x0080
302 #define EV_RING 0x0100
303 #define EV_PERR 0x0200
304 #define EV_CTSS 0x0400
305 #define EV_DSRS 0x0800
306 #define EV_RLSDS        0x1000
307 #define EV_RINGTE       0x2000
308 #define EV_RingTe       EV_RINGTE
309
310 #define SETXOFF 1
311 #define SETXON          2
312 #define SETRTS          3
313 #define CLRRTS          4
314 #define SETDTR          5
315 #define CLRDTR          6
316 #define RESETDEV        7
317 #define SETBREAK        8
318 #define CLRBREAK        9
319
320 #define GETBASEIRQ      10
321
322 /* Purge functions for Comm Port */
323 #define PURGE_TXABORT       0x0001  /* Kill the pending/current writes to the 
324                                        comm port */
325 #define PURGE_RXABORT       0x0002  /*Kill the pending/current reads to 
326                                      the comm port */
327 #define PURGE_TXCLEAR       0x0004  /* Kill the transmit queue if there*/
328 #define PURGE_RXCLEAR       0x0008  /* Kill the typeahead buffer if there*/
329
330
331 /* Modem Status Flags */
332 #define MS_CTS_ON           ((DWORD)0x0010)
333 #define MS_DSR_ON           ((DWORD)0x0020)
334 #define MS_RING_ON          ((DWORD)0x0040)
335 #define MS_RLSD_ON          ((DWORD)0x0080)
336
337 #define RTS_CONTROL_DISABLE     0
338 #define RTS_CONTROL_ENABLE      1
339 #define RTS_CONTROL_HANDSHAKE   2
340 #define RTS_CONTROL_TOGGLE      3
341
342 #define DTR_CONTROL_DISABLE     0
343 #define DTR_CONTROL_ENABLE      1
344 #define DTR_CONTROL_HANDSHAKE   2
345
346 #define CSTF_CTSHOLD    0x01
347 #define CSTF_DSRHOLD    0x02
348 #define CSTF_RLSDHOLD   0x04
349 #define CSTF_XOFFHOLD   0x08
350 #define CSTF_XOFFSENT   0x10
351 #define CSTF_EOF        0x20
352 #define CSTF_TXIM       0x40
353
354 #define MAKEINTRESOURCEA(i) (LPSTR)((DWORD)((WORD)(i)))
355 #define MAKEINTRESOURCEW(i) (LPWSTR)((DWORD)((WORD)(i)))
356 #define MAKEINTRESOURCE WINELIB_NAME_AW(MAKEINTRESOURCE)
357
358 /* Predefined resource types */
359 #define RT_CURSORA         MAKEINTRESOURCEA(1)
360 #define RT_CURSORW         MAKEINTRESOURCEW(1)
361 #define RT_CURSOR            WINELIB_NAME_AW(RT_CURSOR)
362 #define RT_BITMAPA         MAKEINTRESOURCEA(2)
363 #define RT_BITMAPW         MAKEINTRESOURCEW(2)
364 #define RT_BITMAP            WINELIB_NAME_AW(RT_BITMAP)
365 #define RT_ICONA           MAKEINTRESOURCEA(3)
366 #define RT_ICONW           MAKEINTRESOURCEW(3)
367 #define RT_ICON              WINELIB_NAME_AW(RT_ICON)
368 #define RT_MENUA           MAKEINTRESOURCEA(4)
369 #define RT_MENUW           MAKEINTRESOURCEW(4)
370 #define RT_MENU              WINELIB_NAME_AW(RT_MENU)
371 #define RT_DIALOGA         MAKEINTRESOURCEA(5)
372 #define RT_DIALOGW         MAKEINTRESOURCEW(5)
373 #define RT_DIALOG            WINELIB_NAME_AW(RT_DIALOG)
374 #define RT_STRINGA         MAKEINTRESOURCEA(6)
375 #define RT_STRINGW         MAKEINTRESOURCEW(6)
376 #define RT_STRING            WINELIB_NAME_AW(RT_STRING)
377 #define RT_FONTDIRA        MAKEINTRESOURCEA(7)
378 #define RT_FONTDIRW        MAKEINTRESOURCEW(7)
379 #define RT_FONTDIR           WINELIB_NAME_AW(RT_FONTDIR)
380 #define RT_FONTA           MAKEINTRESOURCEA(8)
381 #define RT_FONTW           MAKEINTRESOURCEW(8)
382 #define RT_FONT              WINELIB_NAME_AW(RT_FONT)
383 #define RT_ACCELERATORA    MAKEINTRESOURCEA(9)
384 #define RT_ACCELERATORW    MAKEINTRESOURCEW(9)
385 #define RT_ACCELERATOR       WINELIB_NAME_AW(RT_ACCELERATOR)
386 #define RT_RCDATAA         MAKEINTRESOURCEA(10)
387 #define RT_RCDATAW         MAKEINTRESOURCEW(10)
388 #define RT_RCDATA            WINELIB_NAME_AW(RT_RCDATA)
389 #define RT_MESSAGELISTA    MAKEINTRESOURCEA(11)
390 #define RT_MESSAGELISTW    MAKEINTRESOURCEW(11)
391 #define RT_MESSAGELIST       WINELIB_NAME_AW(RT_MESSAGELIST)
392 #define RT_GROUP_CURSORA   MAKEINTRESOURCEA(12)
393 #define RT_GROUP_CURSORW   MAKEINTRESOURCEW(12)
394 #define RT_GROUP_CURSOR      WINELIB_NAME_AW(RT_GROUP_CURSOR)
395 #define RT_GROUP_ICONA     MAKEINTRESOURCEA(14)
396 #define RT_GROUP_ICONW     MAKEINTRESOURCEW(14)
397 #define RT_GROUP_ICON        WINELIB_NAME_AW(RT_GROUP_ICON)
398
399
400 #define LMEM_FIXED          0   
401 #define LMEM_MOVEABLE       0x0002
402 #define LMEM_NOCOMPACT      0x0010
403 #define LMEM_NODISCARD      0x0020
404 #define LMEM_ZEROINIT       0x0040
405 #define LMEM_MODIFY         0x0080
406 #define LMEM_DISCARDABLE    0x0F00
407 #define LMEM_DISCARDED      0x4000
408 #define LMEM_LOCKCOUNT      0x00FF
409
410 #define LPTR (LMEM_FIXED | LMEM_ZEROINIT)
411
412 #define GMEM_FIXED          0x0000
413 #define GMEM_MOVEABLE       0x0002
414 #define GMEM_NOCOMPACT      0x0010
415 #define GMEM_NODISCARD      0x0020
416 #define GMEM_ZEROINIT       0x0040
417 #define GMEM_MODIFY         0x0080
418 #define GMEM_DISCARDABLE    0x0100
419 #define GMEM_NOT_BANKED     0x1000
420 #define GMEM_SHARE          0x2000
421 #define GMEM_DDESHARE       0x2000
422 #define GMEM_NOTIFY         0x4000
423 #define GMEM_LOWER          GMEM_NOT_BANKED
424 #define GMEM_DISCARDED      0x4000
425 #define GMEM_LOCKCOUNT      0x00ff
426 #define GMEM_INVALID_HANDLE 0x8000
427
428 #define GHND                (GMEM_MOVEABLE | GMEM_ZEROINIT)
429 #define GPTR                (GMEM_FIXED | GMEM_ZEROINIT)
430
431
432 typedef struct tagMEMORYSTATUS
433 {
434     DWORD    dwLength;
435     DWORD    dwMemoryLoad;
436     DWORD    dwTotalPhys;
437     DWORD    dwAvailPhys;
438     DWORD    dwTotalPageFile;
439     DWORD    dwAvailPageFile;
440     DWORD    dwTotalVirtual;
441     DWORD    dwAvailVirtual;
442 } MEMORYSTATUS, *LPMEMORYSTATUS;
443
444
445 #ifndef NOLOGERROR
446
447 /* LogParamError and LogError values */
448
449 /* Error modifier bits */
450 #define ERR_WARNING             0x8000
451 #define ERR_PARAM               0x4000
452
453 #define ERR_SIZE_MASK           0x3000
454 #define ERR_BYTE                0x1000
455 #define ERR_WORD                0x2000
456 #define ERR_DWORD               0x3000
457
458 /* LogParamError() values */
459
460 /* Generic parameter values */
461 #define ERR_BAD_VALUE           0x6001
462 #define ERR_BAD_FLAGS           0x6002
463 #define ERR_BAD_INDEX           0x6003
464 #define ERR_BAD_DVALUE          0x7004
465 #define ERR_BAD_DFLAGS          0x7005
466 #define ERR_BAD_DINDEX          0x7006
467 #define ERR_BAD_PTR             0x7007
468 #define ERR_BAD_FUNC_PTR        0x7008
469 #define ERR_BAD_SELECTOR        0x6009
470 #define ERR_BAD_STRING_PTR      0x700a
471 #define ERR_BAD_HANDLE          0x600b
472
473 /* KERNEL parameter errors */
474 #define ERR_BAD_HINSTANCE       0x6020
475 #define ERR_BAD_HMODULE         0x6021
476 #define ERR_BAD_GLOBAL_HANDLE   0x6022
477 #define ERR_BAD_LOCAL_HANDLE    0x6023
478 #define ERR_BAD_ATOM            0x6024
479 #define ERR_BAD_HFILE           0x6025
480
481 /* USER parameter errors */
482 #define ERR_BAD_HWND            0x6040
483 #define ERR_BAD_HMENU           0x6041
484 #define ERR_BAD_HCURSOR         0x6042
485 #define ERR_BAD_HICON           0x6043
486 #define ERR_BAD_HDWP            0x6044
487 #define ERR_BAD_CID             0x6045
488 #define ERR_BAD_HDRVR           0x6046
489
490 /* GDI parameter errors */
491 #define ERR_BAD_COORDS          0x7060
492 #define ERR_BAD_GDI_OBJECT      0x6061
493 #define ERR_BAD_HDC             0x6062
494 #define ERR_BAD_HPEN            0x6063
495 #define ERR_BAD_HFONT           0x6064
496 #define ERR_BAD_HBRUSH          0x6065
497 #define ERR_BAD_HBITMAP         0x6066
498 #define ERR_BAD_HRGN            0x6067
499 #define ERR_BAD_HPALETTE        0x6068
500 #define ERR_BAD_HMETAFILE       0x6069
501
502
503 /* LogError() values */
504
505 /* KERNEL errors */
506 #define ERR_GALLOC              0x0001
507 #define ERR_GREALLOC            0x0002
508 #define ERR_GLOCK               0x0003
509 #define ERR_LALLOC              0x0004
510 #define ERR_LREALLOC            0x0005
511 #define ERR_LLOCK               0x0006
512 #define ERR_ALLOCRES            0x0007
513 #define ERR_LOCKRES             0x0008
514 #define ERR_LOADMODULE          0x0009
515
516 /* USER errors */
517 #define ERR_CREATEDLG           0x0040
518 #define ERR_CREATEDLG2          0x0041
519 #define ERR_REGISTERCLASS       0x0042
520 #define ERR_DCBUSY              0x0043
521 #define ERR_CREATEWND           0x0044
522 #define ERR_STRUCEXTRA          0x0045
523 #define ERR_LOADSTR             0x0046
524 #define ERR_LOADMENU            0x0047
525 #define ERR_NESTEDBEGINPAINT    0x0048
526 #define ERR_BADINDEX            0x0049
527 #define ERR_CREATEMENU          0x004a
528
529 /* GDI errors */
530 #define ERR_CREATEDC            0x0080
531 #define ERR_CREATEMETA          0x0081
532 #define ERR_DELOBJSELECTED      0x0082
533 #define ERR_SELBITMAP           0x0083
534
535
536
537 /* Debugging support (DEBUG SYSTEM ONLY) */
538 typedef struct
539 {
540     UINT16  flags;
541     DWORD   dwOptions WINE_PACKED;
542     DWORD   dwFilter WINE_PACKED;
543     CHAR    achAllocModule[8] WINE_PACKED;
544     DWORD   dwAllocBreak WINE_PACKED;
545     DWORD   dwAllocCount WINE_PACKED;
546 } WINDEBUGINFO, *LPWINDEBUGINFO;
547
548 /* WINDEBUGINFO flags values */
549 #define WDI_OPTIONS         0x0001
550 #define WDI_FILTER          0x0002
551 #define WDI_ALLOCBREAK      0x0004
552
553 /* dwOptions values */
554 #define DBO_CHECKHEAP       0x0001
555 #define DBO_BUFFERFILL      0x0004
556 #define DBO_DISABLEGPTRAPPING 0x0010
557 #define DBO_CHECKFREE       0x0020
558
559 #define DBO_SILENT          0x8000
560
561 #define DBO_TRACEBREAK      0x2000
562 #define DBO_WARNINGBREAK    0x1000
563 #define DBO_NOERRORBREAK    0x0800
564 #define DBO_NOFATALBREAK    0x0400
565 #define DBO_INT3BREAK       0x0100
566
567 /* DebugOutput flags values */
568 #define DBF_TRACE           0x0000
569 #define DBF_WARNING         0x4000
570 #define DBF_ERROR           0x8000
571 #define DBF_FATAL           0xc000
572
573 /* dwFilter values */
574 #define DBF_KERNEL          0x1000
575 #define DBF_KRN_MEMMAN      0x0001
576 #define DBF_KRN_LOADMODULE  0x0002
577 #define DBF_KRN_SEGMENTLOAD 0x0004
578 #define DBF_USER            0x0800
579 #define DBF_GDI             0x0400
580 #define DBF_MMSYSTEM        0x0040
581 #define DBF_PENWIN          0x0020
582 #define DBF_APPLICATION     0x0008
583 #define DBF_DRIVER          0x0010
584
585 #endif /* NOLOGERROR */
586
587 typedef struct {
588         WORD wYear;
589         WORD wMonth;
590         WORD wDayOfWeek;
591         WORD wDay;
592         WORD wHour;
593         WORD wMinute;
594         WORD wSecond;
595         WORD wMilliseconds;
596 } SYSTEMTIME, *LPSYSTEMTIME;
597
598
599 /* Code page information.
600  */
601 #define MAX_LEADBYTES     12
602 #define MAX_DEFAULTCHAR   2
603
604 typedef struct
605 {
606     UINT MaxCharSize;
607     BYTE   DefaultChar[MAX_DEFAULTCHAR];
608     BYTE   LeadByte[MAX_LEADBYTES];
609 } CPINFO, *LPCPINFO;
610
611 /* The 'overlapped' data structure used by async I/O functions.
612  */
613 typedef struct {
614         DWORD Internal;
615         DWORD InternalHigh;
616         DWORD Offset;
617         DWORD OffsetHigh;
618         HANDLE hEvent;
619 } OVERLAPPED, *LPOVERLAPPED;
620
621 /* Process startup information.
622  */
623
624 /* STARTUPINFO.dwFlags */
625 #define STARTF_USESHOWWINDOW    0x00000001
626 #define STARTF_USESIZE          0x00000002
627 #define STARTF_USEPOSITION      0x00000004
628 #define STARTF_USECOUNTCHARS    0x00000008
629 #define STARTF_USEFILLATTRIBUTE 0x00000010
630 #define STARTF_RUNFULLSCREEN    0x00000020
631 #define STARTF_FORCEONFEEDBACK  0x00000040
632 #define STARTF_FORCEOFFFEEDBACK 0x00000080
633 #define STARTF_USESTDHANDLES    0x00000100
634 #define STARTF_USEHOTKEY        0x00000200
635
636 typedef struct {
637         DWORD cb;               /* 00: size of struct */
638         LPSTR lpReserved;       /* 04: */
639         LPSTR lpDesktop;        /* 08: */
640         LPSTR lpTitle;          /* 0c: */
641         DWORD dwX;              /* 10: */
642         DWORD dwY;              /* 14: */
643         DWORD dwXSize;          /* 18: */
644         DWORD dwYSize;          /* 1c: */
645         DWORD dwXCountChars;    /* 20: */
646         DWORD dwYCountChars;    /* 24: */
647         DWORD dwFillAttribute;  /* 28: */
648         DWORD dwFlags;          /* 2c: */
649         WORD wShowWindow;       /* 30: */
650         WORD cbReserved2;       /* 32: */
651         BYTE *lpReserved2;      /* 34: */
652         HANDLE hStdInput;       /* 38: */
653         HANDLE hStdOutput;      /* 3c: */
654         HANDLE hStdError;       /* 40: */
655 } STARTUPINFOA, *LPSTARTUPINFOA;
656
657 typedef struct {
658         DWORD cb;
659         LPWSTR lpReserved;
660         LPWSTR lpDesktop;
661         LPWSTR lpTitle;
662         DWORD dwX;
663         DWORD dwY;
664         DWORD dwXSize;
665         DWORD dwYSize;
666         DWORD dwXCountChars;
667         DWORD dwYCountChars;
668         DWORD dwFillAttribute;
669         DWORD dwFlags;
670         WORD wShowWindow;
671         WORD cbReserved2;
672         BYTE *lpReserved2;
673         HANDLE hStdInput;
674         HANDLE hStdOutput;
675         HANDLE hStdError;
676 } STARTUPINFOW, *LPSTARTUPINFOW;
677
678 DECL_WINELIB_TYPE_AW(STARTUPINFO)
679 DECL_WINELIB_TYPE_AW(LPSTARTUPINFO)
680
681 typedef struct {
682         HANDLE  hProcess;
683         HANDLE  hThread;
684         DWORD           dwProcessId;
685         DWORD           dwThreadId;
686 } PROCESS_INFORMATION,*LPPROCESS_INFORMATION;
687
688 typedef struct {
689         LONG Bias;
690         WCHAR StandardName[32];
691         SYSTEMTIME StandardDate;
692         LONG StandardBias;
693         WCHAR DaylightName[32];
694         SYSTEMTIME DaylightDate;
695         LONG DaylightBias;
696 } TIME_ZONE_INFORMATION, *LPTIME_ZONE_INFORMATION;
697
698 #define TIME_ZONE_ID_UNKNOWN    0
699 #define TIME_ZONE_ID_STANDARD   1
700 #define TIME_ZONE_ID_DAYLIGHT   2
701
702 /* CreateProcess: dwCreationFlag values
703  */
704 #define DEBUG_PROCESS               0x00000001
705 #define DEBUG_ONLY_THIS_PROCESS     0x00000002
706 #define CREATE_SUSPENDED            0x00000004
707 #define DETACHED_PROCESS            0x00000008
708 #define CREATE_NEW_CONSOLE          0x00000010
709 #define NORMAL_PRIORITY_CLASS       0x00000020
710 #define IDLE_PRIORITY_CLASS         0x00000040
711 #define HIGH_PRIORITY_CLASS         0x00000080
712 #define REALTIME_PRIORITY_CLASS     0x00000100
713 #define CREATE_NEW_PROCESS_GROUP    0x00000200
714 #define CREATE_UNICODE_ENVIRONMENT  0x00000400
715 #define CREATE_SEPARATE_WOW_VDM     0x00000800
716 #define CREATE_SHARED_WOW_VDM       0x00001000
717 #define CREATE_DEFAULT_ERROR_MODE   0x04000000
718 #define CREATE_NO_WINDOW            0x08000000
719 #define PROFILE_USER                0x10000000
720 #define PROFILE_KERNEL              0x20000000
721 #define PROFILE_SERVER              0x40000000
722
723
724 /* File object type definitions
725  */
726 #define FILE_TYPE_UNKNOWN       0
727 #define FILE_TYPE_DISK          1
728 #define FILE_TYPE_CHAR          2
729 #define FILE_TYPE_PIPE          3
730 #define FILE_TYPE_REMOTE        32768
731
732 /* File creation flags
733  */
734 #define FILE_FLAG_WRITE_THROUGH    0x80000000UL
735 #define FILE_FLAG_OVERLAPPED       0x40000000L
736 #define FILE_FLAG_NO_BUFFERING     0x20000000L
737 #define FILE_FLAG_RANDOM_ACCESS    0x10000000L
738 #define FILE_FLAG_SEQUENTIAL_SCAN  0x08000000L
739 #define FILE_FLAG_DELETE_ON_CLOSE  0x04000000L
740 #define FILE_FLAG_BACKUP_SEMANTICS 0x02000000L
741 #define FILE_FLAG_POSIX_SEMANTICS  0x01000000L
742 #define CREATE_NEW              1
743 #define CREATE_ALWAYS           2
744 #define OPEN_EXISTING           3
745 #define OPEN_ALWAYS             4
746 #define TRUNCATE_EXISTING       5
747
748 /* Standard handle identifiers
749  */
750 #define STD_INPUT_HANDLE        ((DWORD) -10)
751 #define STD_OUTPUT_HANDLE       ((DWORD) -11)
752 #define STD_ERROR_HANDLE        ((DWORD) -12)
753
754 typedef struct
755 {
756   int dwFileAttributes;
757   FILETIME ftCreationTime;
758   FILETIME ftLastAccessTime;
759   FILETIME ftLastWriteTime;
760   int dwVolumeSerialNumber;
761   int nFileSizeHigh;
762   int nFileSizeLow;
763   int nNumberOfLinks;
764   int nFileIndexHigh;
765   int nFileIndexLow;
766 } BY_HANDLE_FILE_INFORMATION ;
767
768
769 typedef struct _SYSTEM_POWER_STATUS
770 {
771   BOOL16  ACLineStatus;
772   BYTE    BatteryFlag;
773   BYTE    BatteryLifePercent;
774   BYTE    reserved;
775   DWORD   BatteryLifeTime;
776   DWORD   BatteryFullLifeTime;
777 } SYSTEM_POWER_STATUS, *LPSYSTEM_POWER_STATUS;
778
779 typedef struct _MEMORY_BASIC_INFORMATION
780 {
781     LPVOID   BaseAddress;
782     LPVOID   AllocationBase;
783     DWORD    AllocationProtect;
784     DWORD    RegionSize;
785     DWORD    State;
786     DWORD    Protect;
787     DWORD    Type;
788 } MEMORY_BASIC_INFORMATION,*LPMEMORY_BASIC_INFORMATION;
789
790
791 typedef BOOL (CALLBACK *CODEPAGE_ENUMPROCA)(LPSTR);
792 typedef BOOL (CALLBACK *CODEPAGE_ENUMPROCW)(LPWSTR);
793 DECL_WINELIB_TYPE_AW(CODEPAGE_ENUMPROC)
794 typedef BOOL (CALLBACK *LOCALE_ENUMPROCA)(LPSTR);
795 typedef BOOL (CALLBACK *LOCALE_ENUMPROCW)(LPWSTR);
796 DECL_WINELIB_TYPE_AW(LOCALE_ENUMPROC)
797
798 typedef struct tagSYSTEM_INFO
799 {
800     union {
801         DWORD   dwOemId;
802         struct {
803                 WORD wProcessorArchitecture;
804                 WORD wReserved;
805         } x;
806     } u;
807     DWORD       dwPageSize;
808     LPVOID      lpMinimumApplicationAddress;
809     LPVOID      lpMaximumApplicationAddress;
810     DWORD       dwActiveProcessorMask;
811     DWORD       dwNumberOfProcessors;
812     DWORD       dwProcessorType;
813     DWORD       dwAllocationGranularity;
814     WORD        wProcessorLevel;
815     WORD        wProcessorRevision;
816 } SYSTEM_INFO, *LPSYSTEM_INFO;
817
818 /* {G,S}etPriorityClass */
819 #define NORMAL_PRIORITY_CLASS   0x00000020
820 #define IDLE_PRIORITY_CLASS     0x00000040
821 #define HIGH_PRIORITY_CLASS     0x00000080
822 #define REALTIME_PRIORITY_CLASS 0x00000100
823
824 typedef BOOL (CALLBACK *ENUMRESTYPEPROCA)(HMODULE,LPSTR,LONG);
825 typedef BOOL (CALLBACK *ENUMRESTYPEPROCW)(HMODULE,LPWSTR,LONG);
826 typedef BOOL (CALLBACK *ENUMRESNAMEPROCA)(HMODULE,LPCSTR,LPSTR,LONG);
827 typedef BOOL (CALLBACK *ENUMRESNAMEPROCW)(HMODULE,LPCWSTR,LPWSTR,LONG);
828 typedef BOOL (CALLBACK *ENUMRESLANGPROCA)(HMODULE,LPCSTR,LPCSTR,WORD,LONG);
829 typedef BOOL (CALLBACK *ENUMRESLANGPROCW)(HMODULE,LPCWSTR,LPCWSTR,WORD,LONG);
830
831 DECL_WINELIB_TYPE_AW(ENUMRESTYPEPROC)
832 DECL_WINELIB_TYPE_AW(ENUMRESNAMEPROC)
833 DECL_WINELIB_TYPE_AW(ENUMRESLANGPROC)
834
835 /* flags that can be passed to LoadLibraryEx */
836 #define DONT_RESOLVE_DLL_REFERENCES     0x00000001
837 #define LOAD_LIBRARY_AS_DATAFILE        0x00000002
838 #define LOAD_WITH_ALTERED_SEARCH_PATH   0x00000008
839
840 /* ifdef _x86_ ... */
841 typedef struct _LDT_ENTRY {
842     WORD        LimitLow;
843     WORD        BaseLow;
844     union {
845         struct {
846             BYTE        BaseMid;
847             BYTE        Flags1;/*Declare as bytes to avoid alignment problems */
848             BYTE        Flags2; 
849             BYTE        BaseHi;
850         } Bytes;
851         struct {            
852             unsigned    BaseMid         : 8;
853             unsigned    Type            : 5;
854             unsigned    Dpl             : 2;
855             unsigned    Pres            : 1;
856             unsigned    LimitHi         : 4;
857             unsigned    Sys             : 1;
858             unsigned    Reserved_0      : 1;
859             unsigned    Default_Big     : 1;
860             unsigned    Granularity     : 1;
861             unsigned    BaseHi          : 8;
862         } Bits;
863     } HighWord;
864 } LDT_ENTRY, *LPLDT_ENTRY;
865
866
867 typedef enum _GET_FILEEX_INFO_LEVELS {
868     GetFileExInfoStandard
869 } GET_FILEEX_INFO_LEVELS;
870
871 typedef struct _WIN32_FILE_ATTRIBUTES_DATA {
872     DWORD    dwFileAttributes;
873     FILETIME ftCreationTime;
874     FILETIME ftLastAccessTime;
875     FILETIME ftLastWriteTime;
876     DWORD    nFileSizeHigh;
877     DWORD    nFileSizeLow;
878 } WIN32_FILE_ATTRIBUTE_DATA, *LPWIN32_FILE_ATTRIBUTE_DATA;
879
880 typedef struct _DllVersionInfo {
881     DWORD cbSize;
882     DWORD dwMajorVersion;
883     DWORD dwMinorVersion;
884     DWORD dwBuildNumber;
885     DWORD dwPlatformID;
886 } DLLVERSIONINFO;
887
888 /*
889  * This one seems to be a Win32 only definition. It also is defined with
890  * WINAPI instead of CALLBACK in the windows headers.
891  */
892 typedef DWORD (WINAPI *LPPROGRESS_ROUTINE)(LARGE_INTEGER, LARGE_INTEGER, LARGE_INTEGER, 
893                                            LARGE_INTEGER, DWORD, DWORD, HANDLE,
894                                            HANDLE, LPVOID);
895
896
897 #define WAIT_FAILED             0xffffffff
898 #define WAIT_OBJECT_0           0
899 #define WAIT_ABANDONED          STATUS_ABANDONED_WAIT_0
900 #define WAIT_ABANDONED_0        STATUS_ABANDONED_WAIT_0
901 #define WAIT_IO_COMPLETION      STATUS_USER_APC
902 #define WAIT_TIMEOUT            STATUS_TIMEOUT
903
904 #define PAGE_NOACCESS           0x01
905 #define PAGE_READONLY           0x02
906 #define PAGE_READWRITE          0x04
907 #define PAGE_WRITECOPY          0x08
908 #define PAGE_EXECUTE            0x10
909 #define PAGE_EXECUTE_READ       0x20
910 #define PAGE_EXECUTE_READWRITE  0x40
911 #define PAGE_EXECUTE_WRITECOPY  0x80
912 #define PAGE_GUARD              0x100
913 #define PAGE_NOCACHE            0x200
914
915 #define MEM_COMMIT              0x00001000
916 #define MEM_RESERVE             0x00002000
917 #define MEM_DECOMMIT            0x00004000
918 #define MEM_RELEASE             0x00008000
919 #define MEM_FREE                0x00010000
920 #define MEM_PRIVATE             0x00020000
921 #define MEM_MAPPED              0x00040000
922 #define MEM_TOP_DOWN            0x00100000
923
924 #define SEC_FILE                0x00800000
925 #define SEC_IMAGE               0x01000000
926 #define SEC_RESERVE             0x04000000
927 #define SEC_COMMIT              0x08000000
928 #define SEC_NOCACHE             0x10000000
929
930 #define FILE_BEGIN              0
931 #define FILE_CURRENT            1
932 #define FILE_END                2
933
934 #define FILE_CASE_SENSITIVE_SEARCH      0x00000001
935 #define FILE_CASE_PRESERVED_NAMES       0x00000002
936 #define FILE_UNICODE_ON_DISK            0x00000004
937 #define FILE_PERSISTENT_ACLS            0x00000008
938
939 #define FILE_MAP_COPY                   0x00000001
940 #define FILE_MAP_WRITE                  0x00000002
941 #define FILE_MAP_READ                   0x00000004
942 #define FILE_MAP_ALL_ACCESS             0x000f001f
943
944 #define MOVEFILE_REPLACE_EXISTING       0x00000001
945 #define MOVEFILE_COPY_ALLOWED           0x00000002
946 #define MOVEFILE_DELAY_UNTIL_REBOOT     0x00000004
947
948 #define FS_CASE_SENSITIVE               FILE_CASE_SENSITIVE_SEARCH
949 #define FS_CASE_IS_PRESERVED            FILE_CASE_PRESERVED_NAMES
950 #define FS_UNICODE_STORED_ON_DISK       FILE_UNICODE_ON_DISK
951
952 #define EXCEPTION_ACCESS_VIOLATION          STATUS_ACCESS_VIOLATION
953 #define EXCEPTION_DATATYPE_MISALIGNMENT     STATUS_DATATYPE_MISALIGNMENT
954 #define EXCEPTION_BREAKPOINT                STATUS_BREAKPOINT
955 #define EXCEPTION_SINGLE_STEP               STATUS_SINGLE_STEP
956 #define EXCEPTION_ARRAY_BOUNDS_EXCEEDED     STATUS_ARRAY_BOUNDS_EXCEEDED
957 #define EXCEPTION_FLT_DENORMAL_OPERAND      STATUS_FLOAT_DENORMAL_OPERAND
958 #define EXCEPTION_FLT_DIVIDE_BY_ZERO        STATUS_FLOAT_DIVIDE_BY_ZERO
959 #define EXCEPTION_FLT_INEXACT_RESULT        STATUS_FLOAT_INEXACT_RESULT
960 #define EXCEPTION_FLT_INVALID_OPERATION     STATUS_FLOAT_INVALID_OPERATION
961 #define EXCEPTION_FLT_OVERFLOW              STATUS_FLOAT_OVERFLOW
962 #define EXCEPTION_FLT_STACK_CHECK           STATUS_FLOAT_STACK_CHECK
963 #define EXCEPTION_FLT_UNDERFLOW             STATUS_FLOAT_UNDERFLOW
964 #define EXCEPTION_INT_DIVIDE_BY_ZERO        STATUS_INTEGER_DIVIDE_BY_ZERO
965 #define EXCEPTION_INT_OVERFLOW              STATUS_INTEGER_OVERFLOW
966 #define EXCEPTION_PRIV_INSTRUCTION          STATUS_PRIVILEGED_INSTRUCTION
967 #define EXCEPTION_IN_PAGE_ERROR             STATUS_IN_PAGE_ERROR
968 #define EXCEPTION_ILLEGAL_INSTRUCTION       STATUS_ILLEGAL_INSTRUCTION
969 #define EXCEPTION_NONCONTINUABLE_EXCEPTION  STATUS_NONCONTINUABLE_EXCEPTION
970 #define EXCEPTION_STACK_OVERFLOW            STATUS_STACK_OVERFLOW
971 #define EXCEPTION_INVALID_DISPOSITION       STATUS_INVALID_DISPOSITION
972 #define EXCEPTION_GUARD_PAGE                STATUS_GUARD_PAGE_VIOLATION
973 #define EXCEPTION_INVALID_HANDLE            STATUS_INVALID_HANDLE
974 #define CONTROL_C_EXIT                      STATUS_CONTROL_C_EXIT
975
976
977 #define DUPLICATE_CLOSE_SOURCE          0x00000001
978 #define DUPLICATE_SAME_ACCESS           0x00000002
979
980 #define HANDLE_FLAG_INHERIT             0x00000001
981 #define HANDLE_FLAG_PROTECT_FROM_CLOSE  0x00000002
982
983 #define HINSTANCE_ERROR 32
984
985 #define THREAD_PRIORITY_LOWEST          THREAD_BASE_PRIORITY_MIN
986 #define THREAD_PRIORITY_BELOW_NORMAL    (THREAD_PRIORITY_LOWEST+1)
987 #define THREAD_PRIORITY_NORMAL          0
988 #define THREAD_PRIORITY_HIGHEST         THREAD_BASE_PRIORITY_MAX
989 #define THREAD_PRIORITY_ABOVE_NORMAL    (THREAD_PRIORITY_HIGHEST-1)
990 #define THREAD_PRIORITY_ERROR_RETURN    (0x7fffffff)
991 #define THREAD_PRIORITY_TIME_CRITICAL   THREAD_BASE_PRIORITY_LOWRT
992 #define THREAD_PRIORITY_IDLE            THREAD_BASE_PRIORITY_IDLE
993
994 /* Could this type be considered opaque? */
995 typedef struct {
996         LPVOID  DebugInfo;
997         LONG LockCount;
998         LONG RecursionCount;
999         HANDLE OwningThread;
1000         HANDLE LockSemaphore;
1001         DWORD Reserved;
1002 }CRITICAL_SECTION;
1003
1004 typedef struct {
1005         DWORD dwOSVersionInfoSize;
1006         DWORD dwMajorVersion;
1007         DWORD dwMinorVersion;
1008         DWORD dwBuildNumber;
1009         DWORD dwPlatformId;
1010         CHAR szCSDVersion[128];
1011 } OSVERSIONINFO16;
1012
1013 typedef struct {
1014         DWORD dwOSVersionInfoSize;
1015         DWORD dwMajorVersion;
1016         DWORD dwMinorVersion;
1017         DWORD dwBuildNumber;
1018         DWORD dwPlatformId;
1019         CHAR szCSDVersion[128];
1020 } OSVERSIONINFOA;
1021
1022 typedef struct {
1023         DWORD dwOSVersionInfoSize;
1024         DWORD dwMajorVersion;
1025         DWORD dwMinorVersion;
1026         DWORD dwBuildNumber;
1027         DWORD dwPlatformId;
1028         WCHAR szCSDVersion[128];
1029 } OSVERSIONINFOW;
1030
1031 DECL_WINELIB_TYPE_AW(OSVERSIONINFO)
1032
1033 #define VER_PLATFORM_WIN32s             0
1034 #define VER_PLATFORM_WIN32_WINDOWS      1
1035 #define VER_PLATFORM_WIN32_NT           2
1036
1037 typedef struct tagCOMSTAT
1038 {
1039     DWORD status;
1040     DWORD cbInQue;
1041     DWORD cbOutQue;
1042 } COMSTAT,*LPCOMSTAT;
1043
1044 typedef struct tagDCB
1045 {
1046     DWORD DCBlength;
1047     DWORD BaudRate;
1048     unsigned fBinary               :1;
1049     unsigned fParity               :1;
1050     unsigned fOutxCtsFlow          :1;
1051     unsigned fOutxDsrFlow          :1;
1052     unsigned fDtrControl           :2;
1053     unsigned fDsrSensitivity       :1;
1054     unsigned fTXContinueOnXoff     :1;
1055     unsigned fOutX                 :1;
1056     unsigned fInX                  :1;
1057     unsigned fErrorChar            :1;
1058     unsigned fNull                 :1;
1059     unsigned fRtsControl           :2;
1060     unsigned fAbortOnError         :1;
1061     unsigned fDummy2               :17;
1062     WORD wReserved;
1063     WORD XonLim;
1064     WORD XoffLim;
1065     BYTE ByteSize;
1066     BYTE Parity;
1067     BYTE StopBits;
1068     char XonChar;
1069     char XoffChar;
1070     char ErrorChar;
1071     char EofChar;
1072     char EvtChar;
1073 } DCB, *LPDCB;
1074
1075
1076
1077 typedef struct tagCOMMTIMEOUTS {
1078         DWORD   ReadIntervalTimeout;
1079         DWORD   ReadTotalTimeoutMultiplier;
1080         DWORD   ReadTotalTimeoutConstant;
1081         DWORD   WriteTotalTimeoutMultiplier;
1082         DWORD   WriteTotalTimeoutConstant;
1083 } COMMTIMEOUTS,*LPCOMMTIMEOUTS;
1084   
1085 #include "poppack.h"
1086
1087 typedef VOID (CALLBACK *PAPCFUNC)(ULONG_PTR);
1088
1089 BOOL      WINAPI ClearCommError(INT,LPDWORD,LPCOMSTAT);
1090 BOOL      WINAPI BuildCommDCBA(LPCSTR,LPDCB);
1091 BOOL      WINAPI BuildCommDCBW(LPCWSTR,LPDCB);
1092 #define     BuildCommDCB WINELIB_NAME_AW(BuildCommDCB)
1093 BOOL      WINAPI BuildCommDCBAndTimeoutsA(LPCSTR,LPDCB,LPCOMMTIMEOUTS);
1094 BOOL      WINAPI BuildCommDCBAndTimeoutsW(LPCWSTR,LPDCB,LPCOMMTIMEOUTS);
1095 #define     BuildCommDCBAndTimeouts WINELIB_NAME_AW(BuildCommDCBAndTimeouts)
1096 BOOL      WINAPI GetCommTimeouts(INT,LPCOMMTIMEOUTS);
1097 BOOL      WINAPI SetCommTimeouts(INT,LPCOMMTIMEOUTS);
1098 BOOL      WINAPI GetCommState(INT,LPDCB);
1099 BOOL      WINAPI SetCommState(INT,LPDCB);
1100 BOOL      WINAPI TransmitCommChar(INT,CHAR);
1101 BOOL      WINAPI SetupComm(HANDLE, DWORD, DWORD);
1102 BOOL      WINAPI GetCommProperties(HANDLE, LPDCB *);
1103   
1104 /*DWORD WINAPI GetVersion( void );*/
1105 BOOL16 WINAPI GetVersionEx16(OSVERSIONINFO16*);
1106 BOOL WINAPI GetVersionExA(OSVERSIONINFOA*);
1107 BOOL WINAPI GetVersionExW(OSVERSIONINFOW*);
1108 #define GetVersionEx WINELIB_NAME_AW(GetVersionEx)
1109
1110 /*int WinMain(HINSTANCE, HINSTANCE prev, char *cmd, int show);*/
1111
1112 void      WINAPI DeleteCriticalSection(CRITICAL_SECTION *lpCrit);
1113 void      WINAPI EnterCriticalSection(CRITICAL_SECTION *lpCrit);
1114 BOOL      WINAPI TryEnterCriticalSection(CRITICAL_SECTION *lpCrit);
1115 void      WINAPI InitializeCriticalSection(CRITICAL_SECTION *lpCrit);
1116 void      WINAPI LeaveCriticalSection(CRITICAL_SECTION *lpCrit);
1117 void      WINAPI MakeCriticalSectionGlobal(CRITICAL_SECTION *lpCrit);
1118 BOOL    WINAPI GetProcessWorkingSetSize(HANDLE,LPDWORD,LPDWORD);
1119 DWORD     WINAPI QueueUserAPC(PAPCFUNC,HANDLE,ULONG_PTR);
1120 void      WINAPI RaiseException(DWORD,DWORD,DWORD,const LPDWORD);
1121 BOOL    WINAPI SetProcessWorkingSetSize(HANDLE,DWORD,DWORD);
1122 BOOL    WINAPI TerminateProcess(HANDLE,DWORD);
1123 BOOL    WINAPI TerminateThread(HANDLE,DWORD);
1124 BOOL    WINAPI GetExitCodeThread(HANDLE,LPDWORD); 
1125
1126 /* GetBinaryType return values.
1127  */
1128
1129 #define SCS_32BIT_BINARY    0
1130 #define SCS_DOS_BINARY      1
1131 #define SCS_WOW_BINARY      2
1132 #define SCS_PIF_BINARY      3
1133 #define SCS_POSIX_BINARY    4
1134 #define SCS_OS216_BINARY    5
1135
1136 BOOL WINAPI GetBinaryTypeA( LPCSTR lpApplicationName, LPDWORD lpBinaryType );
1137 BOOL WINAPI GetBinaryTypeW( LPCWSTR lpApplicationName, LPDWORD lpBinaryType );
1138 #define GetBinaryType WINELIB_NAME_AW(GetBinaryType)
1139
1140 BOOL16      WINAPI GetWinDebugInfo16(LPWINDEBUGINFO,UINT16);
1141 BOOL16      WINAPI SetWinDebugInfo16(LPWINDEBUGINFO);
1142 /* Declarations for functions that exist only in Win32 */
1143
1144
1145 BOOL        WINAPI AttachThreadInput(DWORD,DWORD,BOOL);
1146 BOOL        WINAPI AccessCheck(PSECURITY_DESCRIPTOR,HANDLE,DWORD,PGENERIC_MAPPING,PPRIVILEGE_SET,LPDWORD,LPDWORD,LPBOOL);
1147 BOOL        WINAPI AdjustTokenPrivileges(HANDLE,BOOL,LPVOID,DWORD,LPVOID,LPDWORD);
1148 BOOL        WINAPI AllocateAndInitializeSid(PSID_IDENTIFIER_AUTHORITY,BYTE,DWORD,DWORD,DWORD,DWORD,DWORD,DWORD,DWORD,DWORD,PSID *);
1149 BOOL        WINAPI AllocateLocallyUniqueId(PLUID);
1150 BOOL      WINAPI AllocConsole(void);
1151 BOOL      WINAPI AreFileApisANSI(void);
1152 BOOL        WINAPI BackupEventLogA(HANDLE,LPCSTR);
1153 BOOL        WINAPI BackupEventLogW(HANDLE,LPCWSTR);
1154 #define     BackupEventLog WINELIB_NAME_AW(BackupEventLog)
1155 BOOL      WINAPI Beep(DWORD,DWORD);
1156 BOOL        WINAPI ClearEventLogA(HANDLE,LPCSTR);
1157 BOOL        WINAPI ClearEventLogW(HANDLE,LPCWSTR);
1158 #define     ClearEventLog WINELIB_NAME_AW(ClearEventLog)
1159 BOOL        WINAPI CloseEventLog(HANDLE);
1160 BOOL      WINAPI CloseHandle(HANDLE);
1161 BOOL      WINAPI ContinueDebugEvent(DWORD,DWORD,DWORD);
1162 HANDLE    WINAPI ConvertToGlobalHandle(HANDLE hSrc);
1163 BOOL      WINAPI CopyFileA(LPCSTR,LPCSTR,BOOL);
1164 BOOL      WINAPI CopyFileW(LPCWSTR,LPCWSTR,BOOL);
1165 #define     CopyFile WINELIB_NAME_AW(CopyFile)
1166 BOOL      WINAPI CopyFileExA(LPCSTR, LPCSTR, LPPROGRESS_ROUTINE, LPVOID, LPBOOL, DWORD);
1167 BOOL      WINAPI CopyFileExW(LPCWSTR, LPCWSTR, LPPROGRESS_ROUTINE, LPVOID, LPBOOL, DWORD);
1168 #define     CopyFileEx WINELIB_NAME_AW(CopyFileEx)
1169 BOOL        WINAPI CopySid(DWORD,PSID,PSID);
1170 INT       WINAPI CompareFileTime(LPFILETIME,LPFILETIME);
1171 HANDLE    WINAPI CreateEventA(LPSECURITY_ATTRIBUTES,BOOL,BOOL,LPCSTR);
1172 HANDLE    WINAPI CreateEventW(LPSECURITY_ATTRIBUTES,BOOL,BOOL,LPCWSTR);
1173 #define     CreateEvent WINELIB_NAME_AW(CreateEvent)
1174 HFILE     WINAPI CreateFileA(LPCSTR,DWORD,DWORD,LPSECURITY_ATTRIBUTES,
1175                                  DWORD,DWORD,HANDLE);
1176 HFILE     WINAPI CreateFileW(LPCWSTR,DWORD,DWORD,LPSECURITY_ATTRIBUTES,
1177                                  DWORD,DWORD,HANDLE);
1178 #define     CreateFile WINELIB_NAME_AW(CreateFile)
1179 HANDLE    WINAPI CreateFileMappingA(HANDLE,LPSECURITY_ATTRIBUTES,DWORD,
1180                                         DWORD,DWORD,LPCSTR);
1181 HANDLE    WINAPI CreateFileMappingW(HANDLE,LPSECURITY_ATTRIBUTES,DWORD,
1182                                         DWORD,DWORD,LPCWSTR);
1183 #define     CreateFileMapping WINELIB_NAME_AW(CreateFileMapping)
1184 HANDLE    WINAPI CreateMutexA(LPSECURITY_ATTRIBUTES,BOOL,LPCSTR);
1185 HANDLE    WINAPI CreateMutexW(LPSECURITY_ATTRIBUTES,BOOL,LPCWSTR);
1186 #define     CreateMutex WINELIB_NAME_AW(CreateMutex)
1187 BOOL      WINAPI CreatePipe(PHANDLE,PHANDLE,LPSECURITY_ATTRIBUTES,DWORD);
1188 BOOL      WINAPI CreateProcessA(LPCSTR,LPSTR,LPSECURITY_ATTRIBUTES,
1189                                     LPSECURITY_ATTRIBUTES,BOOL,DWORD,LPVOID,LPCSTR,
1190                                     LPSTARTUPINFOA,LPPROCESS_INFORMATION);
1191 BOOL      WINAPI CreateProcessW(LPCWSTR,LPWSTR,LPSECURITY_ATTRIBUTES,
1192                                     LPSECURITY_ATTRIBUTES,BOOL,DWORD,LPVOID,LPCWSTR,
1193                                     LPSTARTUPINFOW,LPPROCESS_INFORMATION);
1194 #define     CreateProcess WINELIB_NAME_AW(CreateProcess)
1195 HANDLE    WINAPI CreateSemaphoreA(LPSECURITY_ATTRIBUTES,LONG,LONG,LPCSTR);
1196 HANDLE    WINAPI CreateSemaphoreW(LPSECURITY_ATTRIBUTES,LONG,LONG,LPCWSTR);
1197 #define     CreateSemaphore WINELIB_NAME_AW(CreateSemaphore)
1198 HANDLE      WINAPI CreateThread(LPSECURITY_ATTRIBUTES,DWORD,LPTHREAD_START_ROUTINE,LPVOID,DWORD,LPDWORD);
1199 BOOL        WINAPI DebugActiveProcess(DWORD);
1200 void        WINAPI DebugBreak(void);
1201 BOOL        WINAPI DeregisterEventSource(HANDLE);
1202 BOOL        WINAPI DisableThreadLibraryCalls(HMODULE);
1203 BOOL        WINAPI DosDateTimeToFileTime(WORD,WORD,LPFILETIME);
1204 BOOL        WINAPI DuplicateHandle(HANDLE,HANDLE,HANDLE,HANDLE*,DWORD,BOOL,DWORD);
1205 BOOL        WINAPI EnumDateFormatsA(DATEFMT_ENUMPROCA lpDateFmtEnumProc, LCID Locale, DWORD dwFlags);
1206 BOOL        WINAPI EnumDateFormatsW(DATEFMT_ENUMPROCW lpDateFmtEnumProc, LCID Locale, DWORD dwFlags);
1207 #define     EnumDateFormats WINELIB_NAME_AW(EnumDateFormats)
1208 BOOL      WINAPI EnumResourceLanguagesA(HMODULE,LPCSTR,LPCSTR,
1209                                             ENUMRESLANGPROCA,LONG);
1210 BOOL      WINAPI EnumResourceLanguagesW(HMODULE,LPCWSTR,LPCWSTR,
1211                                             ENUMRESLANGPROCW,LONG);
1212 #define     EnumResourceLanguages WINELIB_NAME_AW(EnumResourceLanguages)
1213 BOOL      WINAPI EnumResourceNamesA(HMODULE,LPCSTR,ENUMRESNAMEPROCA,
1214                                         LONG);
1215 BOOL      WINAPI EnumResourceNamesW(HMODULE,LPCWSTR,ENUMRESNAMEPROCW,
1216                                         LONG);
1217 #define     EnumResourceNames WINELIB_NAME_AW(EnumResourceNames)
1218 BOOL      WINAPI EnumResourceTypesA(HMODULE,ENUMRESTYPEPROCA,LONG);
1219 BOOL      WINAPI EnumResourceTypesW(HMODULE,ENUMRESTYPEPROCW,LONG);
1220 #define     EnumResourceTypes WINELIB_NAME_AW(EnumResourceTypes)
1221 BOOL      WINAPI EnumSystemCodePagesA(CODEPAGE_ENUMPROCA,DWORD);
1222 BOOL      WINAPI EnumSystemCodePagesW(CODEPAGE_ENUMPROCW,DWORD);
1223 #define     EnumSystemCodePages WINELIB_NAME_AW(EnumSystemCodePages)
1224 BOOL      WINAPI EnumSystemLocalesA(LOCALE_ENUMPROCA,DWORD);
1225 BOOL      WINAPI EnumSystemLocalesW(LOCALE_ENUMPROCW,DWORD);
1226 #define     EnumSystemLocales WINELIB_NAME_AW(EnumSystemLocales)
1227 BOOL      WINAPI EnumTimeFormatsA(TIMEFMT_ENUMPROCA lpTimeFmtEnumProc, LCID Locale, DWORD dwFlags);
1228 BOOL      WINAPI EnumTimeFormatsW(TIMEFMT_ENUMPROCW lpTimeFmtEnumProc, LCID Locale, DWORD dwFlags);
1229 #define     EnumTimeFormats WINELIB_NAME_AW(EnumTimeFormats)
1230 BOOL        WINAPI EqualSid(PSID, PSID);
1231 BOOL        WINAPI EqualPrefixSid(PSID,PSID);
1232 VOID        WINAPI ExitProcess(DWORD);
1233 VOID        WINAPI ExitThread(DWORD);
1234 DWORD       WINAPI ExpandEnvironmentStringsA(LPCSTR,LPSTR,DWORD);
1235 DWORD       WINAPI ExpandEnvironmentStringsW(LPCWSTR,LPWSTR,DWORD);
1236 #define     ExpandEnvironmentStrings WINELIB_NAME_AW(ExpandEnvironmentStrings)
1237 BOOL      WINAPI FileTimeToDosDateTime(const FILETIME*,LPWORD,LPWORD);
1238 BOOL      WINAPI FileTimeToLocalFileTime(const FILETIME*,LPFILETIME);
1239 BOOL      WINAPI FileTimeToSystemTime(const FILETIME*,LPSYSTEMTIME);
1240 HANDLE    WINAPI FindFirstChangeNotificationA(LPCSTR,BOOL,DWORD);
1241 HANDLE    WINAPI FindFirstChangeNotificationW(LPCWSTR,BOOL,DWORD);
1242 #define     FindFirstChangeNotification WINELIB_NAME_AW(FindFirstChangeNotification)
1243 BOOL      WINAPI FindNextChangeNotification(HANDLE);
1244 BOOL      WINAPI FindCloseChangeNotification(HANDLE);
1245 HRSRC     WINAPI FindResourceExA(HMODULE,LPCSTR,LPCSTR,WORD);
1246 HRSRC     WINAPI FindResourceExW(HMODULE,LPCWSTR,LPCWSTR,WORD);
1247 #define     FindResourceEx WINELIB_NAME_AW(FindResourceEx)
1248 BOOL      WINAPI FlushConsoleInputBuffer(HANDLE);
1249 BOOL      WINAPI FlushFileBuffers(HFILE);
1250 BOOL      WINAPI FlushViewOfFile(LPCVOID, DWORD);
1251 DWORD       WINAPI FormatMessageA(DWORD,LPCVOID,DWORD,DWORD,LPSTR,
1252                                     DWORD,LPDWORD);
1253 DWORD       WINAPI FormatMessageW(DWORD,LPCVOID,DWORD,DWORD,LPWSTR,
1254                                     DWORD,LPDWORD);
1255 #define     FormatMessage WINELIB_NAME_AW(FormatMessage)
1256 BOOL      WINAPI FreeConsole(void);
1257 BOOL      WINAPI FreeEnvironmentStringsA(LPSTR);
1258 BOOL      WINAPI FreeEnvironmentStringsW(LPWSTR);
1259 #define     FreeEnvironmentStrings WINELIB_NAME_AW(FreeEnvironmentStrings)
1260 PVOID       WINAPI FreeSid(PSID);
1261 UINT      WINAPI GetACP(void);
1262 LPCSTR      WINAPI GetCommandLineA(void);
1263 LPCWSTR     WINAPI GetCommandLineW(void);
1264 #define     GetCommandLine WINELIB_NAME_AW(GetCommandLine)
1265 BOOL      WINAPI GetComputerNameA(LPSTR,LPDWORD);
1266 BOOL      WINAPI GetComputerNameW(LPWSTR,LPDWORD);
1267 #define     GetComputerName WINELIB_NAME_AW(GetComputerName)
1268 UINT      WINAPI GetConsoleCP(void);
1269 BOOL      WINAPI GetConsoleMode(HANDLE,LPDWORD);
1270 UINT      WINAPI GetConsoleOutputCP(void);
1271 DWORD       WINAPI GetConsoleTitleA(LPSTR,DWORD);
1272 DWORD       WINAPI GetConsoleTitleW(LPWSTR,DWORD);
1273 #define     GetConsoleTitle WINELIB_NAME_AW(GetConsoleTitle)
1274 BOOL      WINAPI GetCPInfo(UINT,LPCPINFO);
1275 BOOL      WINAPI GetCommMask(HANDLE, LPDWORD);
1276 BOOL      WINAPI GetCommModemStatus(HANDLE, LPDWORD);
1277 HANDLE    WINAPI GetCurrentProcess(void);
1278 DWORD       WINAPI GetCurrentProcessId(void);
1279 HANDLE    WINAPI GetCurrentThread(void);
1280 INT       WINAPI GetDateFormatA(LCID,DWORD,LPSYSTEMTIME,LPCSTR,LPSTR,INT);
1281 INT       WINAPI GetDateFormatW(LCID,DWORD,LPSYSTEMTIME,LPCWSTR,LPWSTR,INT);
1282 #define     GetDateFormat WINELIB_NAME_AW(GetDateFormat)
1283 LPSTR       WINAPI GetEnvironmentStringsA(void);
1284 LPWSTR      WINAPI GetEnvironmentStringsW(void);
1285 #define     GetEnvironmentStrings WINELIB_NAME_AW(GetEnvironmentStrings)
1286 DWORD       WINAPI GetEnvironmentVariableA(LPCSTR,LPSTR,DWORD);
1287 DWORD       WINAPI GetEnvironmentVariableW(LPCWSTR,LPWSTR,DWORD);
1288 #define     GetEnvironmentVariable WINELIB_NAME_AW(GetEnvironmentVariable)
1289 BOOL      WINAPI GetFileAttributesExA(LPCSTR,GET_FILEEX_INFO_LEVELS,LPVOID);
1290 BOOL      WINAPI GetFileAttributesExW(LPCWSTR,GET_FILEEX_INFO_LEVELS,LPVOID);
1291 #define     GetFileattributesEx WINELIB_NAME_AW(GetFileAttributesEx)
1292 DWORD       WINAPI GetFileInformationByHandle(HFILE,BY_HANDLE_FILE_INFORMATION*);
1293 BOOL        WINAPI GetFileSecurityA(LPCSTR,SECURITY_INFORMATION,PSECURITY_DESCRIPTOR,DWORD,LPDWORD);
1294 BOOL        WINAPI GetFileSecurityW(LPCWSTR,SECURITY_INFORMATION,PSECURITY_DESCRIPTOR,DWORD,LPDWORD);
1295 #define     GetFileSecurity WINELIB_NAME_AW(GetFileSecurity)
1296 DWORD       WINAPI GetFileSize(HFILE,LPDWORD);
1297 BOOL      WINAPI GetFileTime(HFILE,LPFILETIME,LPFILETIME,LPFILETIME);
1298 DWORD       WINAPI GetFileType(HFILE);
1299 DWORD       WINAPI GetFullPathNameA(LPCSTR,DWORD,LPSTR,LPSTR*);
1300 DWORD       WINAPI GetFullPathNameW(LPCWSTR,DWORD,LPWSTR,LPWSTR*);
1301 #define     GetFullPathName WINELIB_NAME_AW(GetFullPathName)
1302 BOOL      WINAPI GetHandleInformation(HANDLE,LPDWORD);
1303 DWORD       WINAPI GetLargestConsoleWindowSize(HANDLE);
1304 DWORD       WINAPI GetLengthSid(PSID);
1305 VOID        WINAPI GetLocalTime(LPSYSTEMTIME);
1306 DWORD       WINAPI GetLogicalDrives(void);
1307 DWORD       WINAPI GetLongPathNameA(LPCSTR,LPSTR,DWORD);
1308 DWORD       WINAPI GetLongPathNameW(LPCWSTR,LPWSTR,DWORD);
1309 #define     GetLongPathName WINELIB_NAME_AW(GetLongPathName)
1310 BOOL      WINAPI GetNumberOfConsoleInputEvents(HANDLE,LPDWORD);
1311 BOOL      WINAPI GetNumberOfConsoleMouseButtons(LPDWORD);
1312 BOOL        WINAPI GetNumberOfEventLogRecords(HANDLE,PDWORD);
1313 UINT      WINAPI GetOEMCP(void);
1314 BOOL        WINAPI GetOldestEventLogRecord(HANDLE,PDWORD);
1315 DWORD       WINAPI GetPriorityClass(HANDLE);
1316 HANDLE    WINAPI GetProcessHeap(void);
1317 DWORD       WINAPI GetProcessVersion(DWORD);
1318 BOOL        WINAPI GetSecurityDescriptorControl(PSECURITY_DESCRIPTOR,PSECURITY_DESCRIPTOR_CONTROL,LPDWORD);
1319 BOOL        WINAPI GetSecurityDescriptorDacl(PSECURITY_DESCRIPTOR,LPBOOL,PACL *,LPBOOL);
1320 BOOL        WINAPI GetSecurityDescriptorGroup(PSECURITY_DESCRIPTOR,PSID *,LPBOOL);
1321 DWORD       WINAPI GetSecurityDescriptorLength(PSECURITY_DESCRIPTOR);
1322 BOOL        WINAPI GetSecurityDescriptorOwner(PSECURITY_DESCRIPTOR,PSID *,LPBOOL);
1323 BOOL        WINAPI GetSecurityDescriptorSacl(PSECURITY_DESCRIPTOR,LPBOOL,PACL *,LPBOOL);
1324 PSID_IDENTIFIER_AUTHORITY WINAPI GetSidIdentifierAuthority(PSID);
1325 DWORD       WINAPI GetSidLengthRequired(BYTE);
1326 PDWORD      WINAPI GetSidSubAuthority(PSID,DWORD);
1327 PUCHAR      WINAPI GetSidSubAuthorityCount(PSID);
1328 DWORD       WINAPI GetShortPathNameA(LPCSTR,LPSTR,DWORD);
1329 DWORD       WINAPI GetShortPathNameW(LPCWSTR,LPWSTR,DWORD);
1330 #define     GetShortPathName WINELIB_NAME_AW(GetShortPathName)
1331 HFILE     WINAPI GetStdHandle(DWORD);
1332 BOOL      WINAPI GetStringTypeExA(LCID,DWORD,LPCSTR,INT,LPWORD);
1333 BOOL      WINAPI GetStringTypeExW(LCID,DWORD,LPCWSTR,INT,LPWORD);
1334 #define     GetStringTypeEx WINELIB_NAME_AW(GetStringTypeEx)
1335 VOID        WINAPI GetSystemInfo(LPSYSTEM_INFO);
1336 BOOL      WINAPI GetSystemPowerStatus(LPSYSTEM_POWER_STATUS);
1337 VOID        WINAPI GetSystemTime(LPSYSTEMTIME);
1338 INT       WINAPI GetTimeFormatA(LCID,DWORD,LPSYSTEMTIME,LPCSTR,LPSTR,INT);
1339 INT       WINAPI GetTimeFormatW(LCID,DWORD,LPSYSTEMTIME,LPCWSTR,LPWSTR,INT);
1340 #define     GetTimeFormat WINELIB_NAME_AW(GetTimeFormat)
1341 BOOL        WINAPI GetThreadContext(HANDLE,CONTEXT *);
1342 LCID        WINAPI GetThreadLocale(void);
1343 INT       WINAPI GetThreadPriority(HANDLE);
1344 BOOL      WINAPI GetThreadSelectorEntry(HANDLE,DWORD,LPLDT_ENTRY);
1345 BOOL        WINAPI GetThreadTimes(HANDLE,LPFILETIME,LPFILETIME,LPFILETIME,LPFILETIME);
1346 BOOL        WINAPI GetTokenInformation(HANDLE,TOKEN_INFORMATION_CLASS,LPVOID,DWORD,LPDWORD);
1347 BOOL        WINAPI GetUserNameA(LPSTR,LPDWORD);
1348 BOOL        WINAPI GetUserNameW(LPWSTR,LPDWORD);
1349 #define     GetUserName WINELIB_NAME_AW(GetUserName)
1350 VOID        WINAPI GlobalMemoryStatus(LPMEMORYSTATUS);
1351 LPVOID      WINAPI HeapAlloc(HANDLE,DWORD,DWORD);
1352 DWORD       WINAPI HeapCompact(HANDLE,DWORD);
1353 HANDLE    WINAPI HeapCreate(DWORD,DWORD,DWORD);
1354 BOOL      WINAPI HeapDestroy(HANDLE);
1355 BOOL      WINAPI HeapFree(HANDLE,DWORD,LPVOID);
1356 BOOL      WINAPI HeapLock(HANDLE);
1357 LPVOID      WINAPI HeapReAlloc(HANDLE,DWORD,LPVOID,DWORD);
1358 DWORD       WINAPI HeapSize(HANDLE,DWORD,LPVOID);
1359 BOOL      WINAPI HeapUnlock(HANDLE);
1360 BOOL      WINAPI HeapValidate(HANDLE,DWORD,LPCVOID);
1361 BOOL        WINAPI InitializeSid(PSID,PSID_IDENTIFIER_AUTHORITY,BYTE);
1362 BOOL        WINAPI IsValidSecurityDescriptor(PSECURITY_DESCRIPTOR);
1363 BOOL        WINAPI IsValidSid(PSID);
1364 BOOL        WINAPI ImpersonateSelf(SECURITY_IMPERSONATION_LEVEL);
1365 LONG        WINAPI InterlockedDecrement(LPLONG);
1366 LONG        WINAPI InterlockedExchange(LPLONG,LONG);
1367 LONG        WINAPI InterlockedIncrement(LPLONG);
1368 BOOL      WINAPI IsDBCSLeadByteEx(UINT,BYTE);
1369 BOOL      WINAPI IsProcessorFeaturePresent(DWORD);
1370 BOOL      WINAPI IsValidLocale(DWORD,DWORD);
1371 BOOL      WINAPI LocalFileTimeToFileTime(const FILETIME*,LPFILETIME);
1372 BOOL      WINAPI LockFile(HFILE,DWORD,DWORD,DWORD,DWORD);
1373 BOOL      WINAPI LockFileEx(HANDLE, DWORD, DWORD, DWORD, DWORD, LPOVERLAPPED);    
1374 BOOL        WINAPI LookupPrivilegeValueA(LPCSTR,LPCSTR,LPVOID);
1375 BOOL        WINAPI LookupPrivilegeValueW(LPCWSTR,LPCWSTR,LPVOID);
1376 #define     LookupPrivilegeValue WINELIB_NAME_AW(LookupPrivilegeValue)
1377 BOOL        WINAPI MakeSelfRelativeSD(PSECURITY_DESCRIPTOR,PSECURITY_DESCRIPTOR,LPDWORD);
1378 HMODULE   WINAPI MapHModuleSL(HMODULE16);
1379 HMODULE16   WINAPI MapHModuleLS(HMODULE);
1380 SEGPTR      WINAPI MapLS(LPVOID);
1381 LPVOID      WINAPI MapSL(SEGPTR);
1382 LPVOID      WINAPI MapViewOfFile(HANDLE,DWORD,DWORD,DWORD,DWORD);
1383 LPVOID      WINAPI MapViewOfFileEx(HANDLE,DWORD,DWORD,DWORD,DWORD,LPVOID);
1384 BOOL      WINAPI MoveFileA(LPCSTR,LPCSTR);
1385 BOOL      WINAPI MoveFileW(LPCWSTR,LPCWSTR);
1386 #define     MoveFile WINELIB_NAME_AW(MoveFile)
1387 BOOL      WINAPI MoveFileExA(LPCSTR,LPCSTR,DWORD);
1388 BOOL      WINAPI MoveFileExW(LPCWSTR,LPCWSTR,DWORD);
1389 #define     MoveFileEx WINELIB_NAME_AW(MoveFileEx)
1390 INT       WINAPI MultiByteToWideChar(UINT,DWORD,LPCSTR,INT,LPWSTR,INT);
1391 BOOL        WINAPI NotifyChangeEventLog(HANDLE,HANDLE);
1392 INT       WINAPI WideCharToMultiByte(UINT,DWORD,LPCWSTR,INT,LPSTR,INT,LPCSTR,BOOL*);
1393 HANDLE      WINAPI OpenBackupEventLogA(LPCSTR,LPCSTR);
1394 HANDLE      WINAPI OpenBackupEventLogW(LPCWSTR,LPCWSTR);
1395 #define     OpenBackupEventLog WINELIB_NAME_AW(OpenBackupEventLog)
1396 HANDLE    WINAPI OpenEventA(DWORD,BOOL,LPCSTR);
1397 HANDLE    WINAPI OpenEventW(DWORD,BOOL,LPCWSTR);
1398 #define     OpenEvent WINELIB_NAME_AW(OpenEvent)
1399 HANDLE      WINAPI OpenEventLogA(LPCSTR,LPCSTR);
1400 HANDLE      WINAPI OpenEventLogW(LPCWSTR,LPCWSTR);
1401 #define     OpenEventLog WINELIB_NAME_AW(OpenEventLog)
1402 HANDLE    WINAPI OpenFileMappingA(DWORD,BOOL,LPCSTR);
1403 HANDLE    WINAPI OpenFileMappingW(DWORD,BOOL,LPCWSTR);
1404 #define     OpenFileMapping WINELIB_NAME_AW(OpenFileMapping)
1405 HANDLE    WINAPI OpenMutexA(DWORD,BOOL,LPCSTR);
1406 HANDLE    WINAPI OpenMutexW(DWORD,BOOL,LPCWSTR);
1407 #define     OpenMutex WINELIB_NAME_AW(OpenMutex)
1408 HANDLE    WINAPI OpenProcess(DWORD,BOOL,DWORD);
1409 BOOL        WINAPI OpenProcessToken(HANDLE,DWORD,PHANDLE);
1410 HANDLE    WINAPI OpenSemaphoreA(DWORD,BOOL,LPCSTR);
1411 HANDLE    WINAPI OpenSemaphoreW(DWORD,BOOL,LPCWSTR);
1412 #define     OpenSemaphore WINELIB_NAME_AW(OpenSemaphore)
1413 BOOL        WINAPI OpenThreadToken(HANDLE,DWORD,BOOL,PHANDLE);
1414 BOOL      WINAPI PulseEvent(HANDLE);
1415 BOOL      WINAPI PurgeComm(HANDLE,DWORD);
1416 DWORD       WINAPI QueryDosDeviceA(LPCSTR,LPSTR,DWORD);
1417 DWORD       WINAPI QueryDosDeviceW(LPCWSTR,LPWSTR,DWORD);
1418 #define     QueryDosDevice WINELIB_NAME_AW(QueryDosDevice)
1419 BOOL      WINAPI QueryPerformanceCounter(PLARGE_INTEGER);
1420 BOOL      WINAPI ReadConsoleA(HANDLE,LPVOID,DWORD,LPDWORD,LPVOID);
1421 BOOL      WINAPI ReadConsoleW(HANDLE,LPVOID,DWORD,LPDWORD,LPVOID);
1422 #define     ReadConsole WINELIB_NAME_AW(ReadConsole)
1423 BOOL      WINAPI ReadConsoleOutputCharacterA(HANDLE,LPSTR,DWORD,
1424                                                  COORD,LPDWORD);
1425 #define     ReadConsoleOutputCharacter WINELIB_NAME_AW(ReadConsoleOutputCharacter)
1426 BOOL        WINAPI ReadEventLogA(HANDLE,DWORD,DWORD,LPVOID,DWORD,DWORD *,DWORD *);
1427 BOOL        WINAPI ReadEventLogW(HANDLE,DWORD,DWORD,LPVOID,DWORD,DWORD *,DWORD *);
1428 #define     ReadEventLog WINELIB_NAME_AW(ReadEventLog)
1429 BOOL      WINAPI ReadFile(HANDLE,LPVOID,DWORD,LPDWORD,LPOVERLAPPED);
1430 HANDLE      WINAPI RegisterEventSourceA(LPCSTR,LPCSTR);
1431 HANDLE      WINAPI RegisterEventSourceW(LPCWSTR,LPCWSTR);
1432 #define     RegisterEventSource WINELIB_NAME_AW(RegisterEventSource)
1433 BOOL      WINAPI ReleaseMutex(HANDLE);
1434 BOOL      WINAPI ReleaseSemaphore(HANDLE,LONG,LPLONG);
1435 BOOL        WINAPI ReportEventA(HANDLE,WORD,WORD,DWORD,PSID,WORD,DWORD,LPCSTR *,LPVOID);
1436 BOOL        WINAPI ReportEventW(HANDLE,WORD,WORD,DWORD,PSID,WORD,DWORD,LPCWSTR *,LPVOID);
1437 #define     ReportEvent WINELIB_NAME_AW(ReportEvent)
1438 BOOL      WINAPI ResetEvent(HANDLE);
1439 DWORD       WINAPI ResumeThread(HANDLE);
1440 VOID        WINAPI RtlFillMemory(LPVOID,UINT,UINT);
1441 #define     FillMemory RtlFillMemory
1442 VOID        WINAPI RtlMoveMemory(LPVOID,LPCVOID,UINT);
1443 #define     MoveMemory RtlMoveMemory
1444 VOID        WINAPI RtlZeroMemory(LPVOID,UINT);
1445 #define     ZeroMemory RtlZeroMemory
1446 VOID        WINAPI RtlCopyMemory(LPVOID,const VOID*, DWORD);
1447 #define     CopyMemory RtlCopyMemory
1448 BOOL        WINAPI RevertToSelf(void);
1449 DWORD       WINAPI SearchPathA(LPCSTR,LPCSTR,LPCSTR,DWORD,LPSTR,LPSTR*);
1450 DWORD       WINAPI SearchPathW(LPCWSTR,LPCWSTR,LPCWSTR,DWORD,LPWSTR,LPWSTR*);
1451 #define     SearchPath WINELIB_NAME_AW(SearchPath)
1452 BOOL      WINAPI SetCommMask(INT,DWORD);
1453 BOOL      WINAPI SetComputerNameA(LPCSTR);
1454 BOOL      WINAPI SetComputerNameW(LPCWSTR);
1455 #define     SetComputerName WINELIB_NAME_AW(SetComputerName)
1456 BOOL      WINAPI SetConsoleCursorPosition(HANDLE,COORD);
1457 BOOL      WINAPI SetConsoleMode(HANDLE,DWORD);
1458 BOOL      WINAPI SetConsoleTitleA(LPCSTR);
1459 BOOL      WINAPI SetConsoleTitleW(LPCWSTR);
1460 #define     SetConsoleTitle WINELIB_NAME_AW(SetConsoleTitle)
1461 BOOL      WINAPI SetEndOfFile(HFILE);
1462 BOOL      WINAPI SetEnvironmentVariableA(LPCSTR,LPCSTR);
1463 BOOL      WINAPI SetEnvironmentVariableW(LPCWSTR,LPCWSTR);
1464 #define     SetEnvironmentVariable WINELIB_NAME_AW(SetEnvironmentVariable)
1465 BOOL      WINAPI SetEvent(HANDLE);
1466 VOID        WINAPI SetFileApisToANSI(void);
1467 VOID        WINAPI SetFileApisToOEM(void);
1468 DWORD       WINAPI SetFilePointer(HFILE,LONG,LPLONG,DWORD);
1469 BOOL        WINAPI SetFileSecurityA(LPCSTR,SECURITY_INFORMATION,PSECURITY_DESCRIPTOR);
1470 BOOL        WINAPI SetFileSecurityW(LPCWSTR,SECURITY_INFORMATION,PSECURITY_DESCRIPTOR);
1471 #define     SetFileSecurity WINELIB_NAME_AW(SetFileSecurity)
1472 BOOL        WINAPI SetFileTime(HFILE,const FILETIME*,const FILETIME*,const FILETIME*);
1473 BOOL        WINAPI SetHandleInformation(HANDLE,DWORD,DWORD);
1474 BOOL        WINAPI SetLocalTime(const SYSTEMTIME*);
1475 BOOL        WINAPI SetPriorityClass(HANDLE,DWORD);
1476 BOOL        WINAPI SetSecurityDescriptorDacl(PSECURITY_DESCRIPTOR,BOOL,PACL,BOOL);
1477 BOOL        WINAPI SetSecurityDescriptorGroup(PSECURITY_DESCRIPTOR,PSID,BOOL);
1478 BOOL        WINAPI SetSecurityDescriptorOwner(PSECURITY_DESCRIPTOR,PSID,BOOL);
1479 BOOL        WINAPI SetSecurityDescriptorSacl(PSECURITY_DESCRIPTOR,BOOL,PACL,BOOL);
1480 BOOL      WINAPI SetStdHandle(DWORD,HANDLE);
1481 BOOL      WINAPI SetSystemPowerState(BOOL,BOOL);
1482 BOOL      WINAPI SetSystemTime(const SYSTEMTIME*);
1483 DWORD       WINAPI SetThreadAffinityMask(HANDLE,DWORD);
1484 BOOL        WINAPI SetThreadContext(HANDLE,const CONTEXT *);
1485 BOOL      WINAPI SetThreadLocale(LCID);
1486 BOOL      WINAPI SetThreadPriority(HANDLE,INT);
1487 BOOL      WINAPI SetTimeZoneInformation(const LPTIME_ZONE_INFORMATION);
1488 VOID        WINAPI Sleep(DWORD);
1489 DWORD       WINAPI SleepEx(DWORD,BOOL);
1490 DWORD       WINAPI SuspendThread(HANDLE);
1491 BOOL      WINAPI SystemTimeToFileTime(const SYSTEMTIME*,LPFILETIME);
1492 DWORD       WINAPI TlsAlloc(void);
1493 BOOL      WINAPI TlsFree(DWORD);
1494 LPVOID      WINAPI TlsGetValue(DWORD);
1495 BOOL      WINAPI TlsSetValue(DWORD,LPVOID);
1496 VOID        WINAPI UnMapLS(SEGPTR);
1497 BOOL      WINAPI UnlockFile(HFILE,DWORD,DWORD,DWORD,DWORD);
1498 BOOL      WINAPI UnmapViewOfFile(LPVOID);
1499 LPVOID      WINAPI VirtualAlloc(LPVOID,DWORD,DWORD,DWORD);
1500 BOOL      WINAPI VirtualFree(LPVOID,DWORD,DWORD);
1501 BOOL      WINAPI VirtualLock(LPVOID,DWORD);
1502 BOOL      WINAPI VirtualProtect(LPVOID,DWORD,DWORD,LPDWORD);
1503 BOOL      WINAPI VirtualProtectEx(HANDLE,LPVOID,DWORD,DWORD,LPDWORD);
1504 DWORD       WINAPI VirtualQuery(LPCVOID,LPMEMORY_BASIC_INFORMATION,DWORD);
1505 DWORD       WINAPI VirtualQueryEx(HANDLE,LPCVOID,LPMEMORY_BASIC_INFORMATION,DWORD);
1506 BOOL      WINAPI VirtualUnlock(LPVOID,DWORD);
1507 BOOL      WINAPI WaitCommEvent(HANDLE,LPDWORD,LPOVERLAPPED);
1508 BOOL      WINAPI WaitForDebugEvent(LPDEBUG_EVENT,DWORD);
1509 DWORD       WINAPI WaitForMultipleObjects(DWORD,const HANDLE*,BOOL,DWORD);
1510 DWORD       WINAPI WaitForMultipleObjectsEx(DWORD,const HANDLE*,BOOL,DWORD,BOOL);
1511 DWORD       WINAPI WaitForSingleObject(HANDLE,DWORD);
1512 DWORD       WINAPI WaitForSingleObjectEx(HANDLE,DWORD,BOOL);
1513 BOOL      WINAPI WriteConsoleA(HANDLE,LPCVOID,DWORD,LPDWORD,LPVOID);
1514 BOOL      WINAPI WriteConsoleW(HANDLE,LPCVOID,DWORD,LPDWORD,LPVOID);
1515 #define     WriteConsole WINELIB_NAME_AW(WriteConsole)
1516 BOOL      WINAPI WriteFile(HANDLE,LPCVOID,DWORD,LPDWORD,LPOVERLAPPED);
1517 DWORD       WINAPI GetLastError(void);
1518 LANGID      WINAPI GetSystemDefaultLangID(void);
1519 LCID        WINAPI GetSystemDefaultLCID(void);
1520 LANGID      WINAPI GetUserDefaultLangID(void);
1521 LCID        WINAPI GetUserDefaultLCID(void);
1522 ATOM        WINAPI AddAtomA(LPCSTR);
1523 ATOM        WINAPI AddAtomW(LPCWSTR);
1524 #define     AddAtom WINELIB_NAME_AW(AddAtom)
1525 UINT      WINAPI CompareStringA(DWORD,DWORD,LPCSTR,DWORD,LPCSTR,DWORD);
1526 UINT      WINAPI CompareStringW(DWORD,DWORD,LPCWSTR,DWORD,LPCWSTR,DWORD);
1527 #define     CompareString WINELIB_NAME_AW(CompareString)
1528 BOOL      WINAPI CreateDirectoryA(LPCSTR,LPSECURITY_ATTRIBUTES);
1529 BOOL      WINAPI CreateDirectoryW(LPCWSTR,LPSECURITY_ATTRIBUTES);
1530 #define     CreateDirectory WINELIB_NAME_AW(CreateDirectory)
1531 BOOL      WINAPI CreateDirectoryExA(LPCSTR,LPCSTR,LPSECURITY_ATTRIBUTES);
1532 BOOL      WINAPI CreateDirectoryExW(LPCWSTR,LPCWSTR,LPSECURITY_ATTRIBUTES);
1533 #define     CreateDirectoryEx WINELIB_NAME_AW(CreateDirectoryEx)
1534 BOOL        WINAPI DefineDosDeviceA(DWORD,LPCSTR,LPCSTR);
1535 #define     DefineHandleTable(w) ((w),TRUE)
1536 ATOM        WINAPI DeleteAtom(ATOM);
1537 BOOL      WINAPI DeleteFileA(LPCSTR);
1538 BOOL      WINAPI DeleteFileW(LPCWSTR);
1539 #define     DeleteFile WINELIB_NAME_AW(DeleteFile)
1540 void        WINAPI FatalAppExitA(UINT,LPCSTR);
1541 void        WINAPI FatalAppExitW(UINT,LPCWSTR);
1542 #define     FatalAppExit WINELIB_NAME_AW(FatalAppExit)
1543 ATOM        WINAPI FindAtomA(LPCSTR);
1544 ATOM        WINAPI FindAtomW(LPCWSTR);
1545 #define     FindAtom WINELIB_NAME_AW(FindAtom)
1546 BOOL      WINAPI FindClose(HANDLE);
1547 HANDLE16    WINAPI FindFirstFile16(LPCSTR,LPWIN32_FIND_DATAA);
1548 HANDLE    WINAPI FindFirstFileA(LPCSTR,LPWIN32_FIND_DATAA);
1549 HANDLE    WINAPI FindFirstFileW(LPCWSTR,LPWIN32_FIND_DATAW);
1550 #define     FindFirstFile WINELIB_NAME_AW(FindFirstFile)
1551 BOOL16      WINAPI FindNextFile16(HANDLE16,LPWIN32_FIND_DATAA);
1552 BOOL      WINAPI FindNextFileA(HANDLE,LPWIN32_FIND_DATAA);
1553 BOOL      WINAPI FindNextFileW(HANDLE,LPWIN32_FIND_DATAW);
1554 #define     FindNextFile WINELIB_NAME_AW(FindNextFile)
1555 HRSRC     WINAPI FindResourceA(HMODULE,LPCSTR,LPCSTR);
1556 HRSRC     WINAPI FindResourceW(HMODULE,LPCWSTR,LPCWSTR);
1557 #define     FindResource WINELIB_NAME_AW(FindResource)
1558 VOID        WINAPI FreeLibrary16(HINSTANCE16);
1559 BOOL      WINAPI FreeLibrary(HMODULE);
1560 #define     FreeModule(handle) FreeLibrary(handle)
1561 #define     FreeProcInstance(proc) /*nothing*/
1562 BOOL      WINAPI FreeResource(HGLOBAL);
1563 UINT      WINAPI GetAtomNameA(ATOM,LPSTR,INT);
1564 UINT      WINAPI GetAtomNameW(ATOM,LPWSTR,INT);
1565 #define     GetAtomName WINELIB_NAME_AW(GetAtomName)
1566 UINT      WINAPI GetCurrentDirectoryA(UINT,LPSTR);
1567 UINT      WINAPI GetCurrentDirectoryW(UINT,LPWSTR);
1568 #define     GetCurrentDirectory WINELIB_NAME_AW(GetCurrentDirectory)
1569 BOOL      WINAPI GetDiskFreeSpaceA(LPCSTR,LPDWORD,LPDWORD,LPDWORD,LPDWORD);
1570 BOOL      WINAPI GetDiskFreeSpaceW(LPCWSTR,LPDWORD,LPDWORD,LPDWORD,LPDWORD);
1571 #define     GetDiskFreeSpace WINELIB_NAME_AW(GetDiskFreeSpace)
1572 BOOL      WINAPI GetDiskFreeSpaceExA(LPCSTR,PULARGE_INTEGER,PULARGE_INTEGER,PULARGE_INTEGER);
1573 BOOL      WINAPI GetDiskFreeSpaceExW(LPCWSTR,PULARGE_INTEGER,PULARGE_INTEGER,PULARGE_INTEGER);
1574 #define     GetDiskFreeSpaceEx WINELIB_NAME_AW(GetDiskFreeSpaceEx)
1575 UINT      WINAPI GetDriveTypeA(LPCSTR);
1576 UINT      WINAPI GetDriveTypeW(LPCWSTR);
1577 #define     GetDriveType WINELIB_NAME_AW(GetDriveType)
1578 DWORD       WINAPI GetFileAttributesA(LPCSTR);
1579 DWORD       WINAPI GetFileAttributesW(LPCWSTR);
1580 #define     GetFileAttributes WINELIB_NAME_AW(GetFileAttributes)
1581 #define     GetFreeSpace(w) (0x100000L)
1582 UINT      WINAPI GetLogicalDriveStringsA(UINT,LPSTR);
1583 UINT      WINAPI GetLogicalDriveStringsW(UINT,LPWSTR);
1584 #define     GetLogicalDriveStrings WINELIB_NAME_AW(GetLogicalDriveStrings)
1585 INT       WINAPI GetLocaleInfoA(LCID,LCTYPE,LPSTR,INT);
1586 INT       WINAPI GetLocaleInfoW(LCID,LCTYPE,LPWSTR,INT);
1587 #define     GetLocaleInfo WINELIB_NAME_AW(GetLocaleInfo)
1588 DWORD       WINAPI GetModuleFileNameA(HMODULE,LPSTR,DWORD);
1589 DWORD       WINAPI GetModuleFileNameW(HMODULE,LPWSTR,DWORD);
1590 #define     GetModuleFileName WINELIB_NAME_AW(GetModuleFileName)
1591 HMODULE   WINAPI GetModuleHandleA(LPCSTR);
1592 HMODULE   WINAPI GetModuleHandleW(LPCWSTR);
1593 #define     GetModuleHandle WINELIB_NAME_AW(GetModuleHandle)
1594 UINT      WINAPI GetPrivateProfileIntA(LPCSTR,LPCSTR,INT,LPCSTR);
1595 UINT      WINAPI GetPrivateProfileIntW(LPCWSTR,LPCWSTR,INT,LPCWSTR);
1596 #define     GetPrivateProfileInt WINELIB_NAME_AW(GetPrivateProfileInt)
1597 INT       WINAPI GetPrivateProfileSectionA(LPCSTR,LPSTR,DWORD,LPCSTR);
1598 INT       WINAPI GetPrivateProfileSectionW(LPCWSTR,LPWSTR,DWORD,LPCWSTR);
1599 #define     GetPrivateProfileSection WINELIB_NAME_AW(GetPrivateProfileSection)
1600 DWORD       WINAPI GetPrivateProfileSectionNamesA(LPSTR,DWORD,LPCSTR);
1601 DWORD       WINAPI GetPrivateProfileSectionNamesW(LPWSTR,DWORD,LPCWSTR);
1602 #define     GetPrivateProfileSectionNames WINELIB_NAME_AW(GetPrivateProfileSectionNames)
1603 INT       WINAPI GetPrivateProfileStringA(LPCSTR,LPCSTR,LPCSTR,LPSTR,UINT,LPCSTR);
1604 INT       WINAPI GetPrivateProfileStringW(LPCWSTR,LPCWSTR,LPCWSTR,LPWSTR,UINT,LPCWSTR);
1605 #define     GetPrivateProfileString WINELIB_NAME_AW(GetPrivateProfileString)
1606 BOOL      WINAPI GetPrivateProfileStructA(LPCSTR,LPCSTR,LPVOID,UINT,LPCSTR);
1607 BOOL      WINAPI GetPrivateProfileStructW(LPCWSTR,LPCWSTR,LPVOID,UINT,LPCWSTR);
1608 #define     GetPrivateProfileStruct WINELIB_NAME_AW(GetPrivateProfileStruct)
1609 FARPROC   WINAPI GetProcAddress(HMODULE,LPCSTR);
1610 UINT      WINAPI GetProfileIntA(LPCSTR,LPCSTR,INT);
1611 UINT      WINAPI GetProfileIntW(LPCWSTR,LPCWSTR,INT);
1612 #define     GetProfileInt WINELIB_NAME_AW(GetProfileInt)
1613 INT       WINAPI GetProfileSectionA(LPCSTR,LPSTR,DWORD);
1614 INT       WINAPI GetProfileSectionW(LPCWSTR,LPWSTR,DWORD);
1615 #define     GetProfileSection WINELIB_NAME_AW(GetProfileSection)
1616 INT       WINAPI GetProfileStringA(LPCSTR,LPCSTR,LPCSTR,LPSTR,UINT);
1617 INT       WINAPI GetProfileStringW(LPCWSTR,LPCWSTR,LPCWSTR,LPWSTR,UINT);
1618 #define     GetProfileString WINELIB_NAME_AW(GetProfileString)
1619 VOID        WINAPI GetStartupInfoA(LPSTARTUPINFOA);
1620 VOID        WINAPI GetStartupInfoW(LPSTARTUPINFOW);
1621 #define     GetStartupInfo WINELIB_NAME_AW(GetStartupInfo)
1622 BOOL      WINAPI GetStringTypeA(LCID,DWORD,LPCSTR,INT,LPWORD);
1623 BOOL      WINAPI GetStringTypeW(DWORD,LPCWSTR,INT,LPWORD);
1624 #define     GetStringType WINELIB_NAME_AW(GetStringType)
1625 UINT      WINAPI GetSystemDirectoryA(LPSTR,UINT);
1626 UINT      WINAPI GetSystemDirectoryW(LPWSTR,UINT);
1627 #define     GetSystemDirectory WINELIB_NAME_AW(GetSystemDirectory)
1628 UINT      WINAPI GetTempFileNameA(LPCSTR,LPCSTR,UINT,LPSTR);
1629 UINT      WINAPI GetTempFileNameW(LPCWSTR,LPCWSTR,UINT,LPWSTR);
1630 #define     GetTempFileName WINELIB_NAME_AW(GetTempFileName)
1631 UINT      WINAPI GetTempPathA(UINT,LPSTR);
1632 UINT      WINAPI GetTempPathW(UINT,LPWSTR);
1633 #define     GetTempPath WINELIB_NAME_AW(GetTempPath)
1634 LONG        WINAPI GetVersion(void);
1635 BOOL      WINAPI GetExitCodeProcess(HANDLE,LPDWORD);
1636 BOOL      WINAPI GetVolumeInformationA(LPCSTR,LPSTR,DWORD,LPDWORD,LPDWORD,LPDWORD,LPSTR,DWORD);
1637 BOOL      WINAPI GetVolumeInformationW(LPCWSTR,LPWSTR,DWORD,LPDWORD,LPDWORD,LPDWORD,LPWSTR,DWORD);
1638 #define     GetVolumeInformation WINELIB_NAME_AW(GetVolumeInformation)
1639 UINT      WINAPI GetWindowsDirectoryA(LPSTR,UINT);
1640 UINT      WINAPI GetWindowsDirectoryW(LPWSTR,UINT);
1641 #define     GetWindowsDirectory WINELIB_NAME_AW(GetWindowsDirectory)
1642 HGLOBAL16   WINAPI GlobalAlloc16(UINT16,DWORD);
1643 HGLOBAL   WINAPI GlobalAlloc(UINT,DWORD);
1644 DWORD       WINAPI GlobalCompact(DWORD);
1645 UINT      WINAPI GlobalFlags(HGLOBAL);
1646 HGLOBAL16   WINAPI GlobalFree16(HGLOBAL16);
1647 HGLOBAL   WINAPI GlobalFree(HGLOBAL);
1648 HGLOBAL   WINAPI GlobalHandle(LPCVOID);
1649 WORD        WINAPI GlobalFix16(HGLOBAL16);
1650 VOID        WINAPI GlobalFix(HGLOBAL);
1651 LPVOID      WINAPI GlobalLock16(HGLOBAL16);
1652 LPVOID      WINAPI GlobalLock(HGLOBAL);
1653 HGLOBAL   WINAPI GlobalReAlloc(HGLOBAL,DWORD,UINT);
1654 DWORD       WINAPI GlobalSize16(HGLOBAL16);
1655 DWORD       WINAPI GlobalSize(HGLOBAL);
1656 VOID        WINAPI GlobalUnfix16(HGLOBAL16);
1657 VOID        WINAPI GlobalUnfix(HGLOBAL);
1658 BOOL16      WINAPI GlobalUnlock16(HGLOBAL16);
1659 BOOL      WINAPI GlobalUnlock(HGLOBAL);
1660 BOOL16      WINAPI GlobalUnWire16(HGLOBAL16);
1661 BOOL      WINAPI GlobalUnWire(HGLOBAL);
1662 SEGPTR      WINAPI GlobalWire16(HGLOBAL16);
1663 LPVOID      WINAPI GlobalWire(HGLOBAL);
1664 BOOL      WINAPI InitAtomTable(DWORD);
1665 BOOL      WINAPI IsBadCodePtr(FARPROC);
1666 BOOL      WINAPI IsBadHugeReadPtr(LPCVOID,UINT);
1667 BOOL      WINAPI IsBadHugeWritePtr(LPVOID,UINT);
1668 BOOL      WINAPI IsBadReadPtr(LPCVOID,UINT);
1669 BOOL      WINAPI IsBadStringPtrA(LPCSTR,UINT);
1670 BOOL      WINAPI IsBadStringPtrW(LPCWSTR,UINT);
1671 #define     IsBadStringPtr WINELIB_NAME_AW(IsBadStringPtr)
1672 BOOL      WINAPI IsBadWritePtr(LPVOID,UINT);
1673 BOOL      WINAPI IsDBCSLeadByte(BYTE);
1674 HINSTANCE16 WINAPI LoadLibrary16(LPCSTR);
1675 HMODULE   WINAPI LoadLibraryA(LPCSTR);
1676 HMODULE   WINAPI LoadLibraryW(LPCWSTR);
1677 #define     LoadLibrary WINELIB_NAME_AW(LoadLibrary)
1678 HMODULE   WINAPI LoadLibraryExA(LPCSTR,HFILE,DWORD);
1679 HMODULE   WINAPI LoadLibraryExW(LPCWSTR,HFILE,DWORD);
1680 #define     LoadLibraryEx WINELIB_NAME_AW(LoadLibraryEx)
1681 HINSTANCE16 WINAPI LoadModule16(LPCSTR,LPVOID);
1682 HINSTANCE WINAPI LoadModule(LPCSTR,LPVOID);
1683 HGLOBAL   WINAPI LoadResource(HMODULE,HRSRC);
1684 HLOCAL    WINAPI LocalAlloc(UINT,DWORD);
1685 UINT      WINAPI LocalCompact(UINT);
1686 UINT      WINAPI LocalFlags(HLOCAL);
1687 HLOCAL    WINAPI LocalFree(HLOCAL);
1688 HLOCAL    WINAPI LocalHandle(LPCVOID);
1689 LPVOID      WINAPI LocalLock(HLOCAL);
1690 HLOCAL    WINAPI LocalReAlloc(HLOCAL,DWORD,UINT);
1691 UINT      WINAPI LocalShrink(HGLOBAL,UINT);
1692 UINT      WINAPI LocalSize(HLOCAL);
1693 BOOL      WINAPI LocalUnlock(HLOCAL);
1694 LPVOID      WINAPI LockResource(HGLOBAL);
1695 #define     LockSegment(handle) GlobalFix((HANDLE)(handle))
1696 #define     MakeProcInstance(proc,inst) (proc)
1697 HFILE16     WINAPI OpenFile16(LPCSTR,OFSTRUCT*,UINT16);
1698 HFILE     WINAPI OpenFile(LPCSTR,OFSTRUCT*,UINT);
1699 VOID        WINAPI OutputDebugStringA(LPCSTR);
1700 VOID        WINAPI OutputDebugStringW(LPCWSTR);
1701 #define     OutputDebugString WINELIB_NAME_AW(OutputDebugString)
1702 BOOL      WINAPI RemoveDirectoryA(LPCSTR);
1703 BOOL      WINAPI RemoveDirectoryW(LPCWSTR);
1704 #define     RemoveDirectory WINELIB_NAME_AW(RemoveDirectory)
1705 BOOL      WINAPI SetCurrentDirectoryA(LPCSTR);
1706 BOOL      WINAPI SetCurrentDirectoryW(LPCWSTR);
1707 #define     SetCurrentDirectory WINELIB_NAME_AW(SetCurrentDirectory)
1708 UINT      WINAPI SetErrorMode(UINT);
1709 BOOL      WINAPI SetFileAttributesA(LPCSTR,DWORD);
1710 BOOL      WINAPI SetFileAttributesW(LPCWSTR,DWORD);
1711 #define     SetFileAttributes WINELIB_NAME_AW(SetFileAttributes)
1712 UINT      WINAPI SetHandleCount(UINT);
1713 #define     SetSwapAreaSize(w) (w)
1714 BOOL        WINAPI SetVolumeLabelA(LPCSTR,LPCSTR);
1715 BOOL        WINAPI SetVolumeLabelW(LPCWSTR,LPCWSTR);
1716 #define     SetVolumeLabel WINELIB_NAME_AW(SetVolumeLabel)
1717 DWORD       WINAPI SizeofResource(HMODULE,HRSRC);
1718 #define     UnlockSegment(handle) GlobalUnfix((HANDLE)(handle))
1719 DWORD       WINAPI VerLanguageNameA(UINT,LPSTR,UINT);
1720 DWORD       WINAPI VerLanguageNameW(UINT,LPWSTR,UINT);
1721 #define     VerLanguageName WINELIB_NAME_AW(VerLanguageName)
1722 BOOL      WINAPI WritePrivateProfileSectionA(LPCSTR,LPCSTR,LPCSTR);
1723 BOOL      WINAPI WritePrivateProfileSectionW(LPCWSTR,LPCWSTR,LPCWSTR);
1724 #define     WritePrivateProfileSection WINELIB_NAME_AW(WritePrivateProfileSection)
1725 BOOL      WINAPI WritePrivateProfileStringA(LPCSTR,LPCSTR,LPCSTR,LPCSTR);
1726 BOOL      WINAPI WritePrivateProfileStringW(LPCWSTR,LPCWSTR,LPCWSTR,LPCWSTR);
1727 #define     WritePrivateProfileString WINELIB_NAME_AW(WritePrivateProfileString)
1728 BOOL         WINAPI WriteProfileSectionA(LPCSTR,LPCSTR);
1729 BOOL         WINAPI WriteProfileSectionW(LPCWSTR,LPCWSTR);
1730 #define     WritePrivateProfileSection WINELIB_NAME_AW(WritePrivateProfileSection)
1731 BOOL      WINAPI WritePrivateProfileStructA(LPCSTR,LPCSTR,LPVOID,UINT,LPCSTR);
1732 BOOL      WINAPI WritePrivateProfileStructW(LPCWSTR,LPCWSTR,LPVOID,UINT,LPCWSTR);
1733 #define     WritePrivateProfileStruct WINELIB_NAME_AW(WritePrivateProfileStruct)
1734 BOOL      WINAPI WriteProfileStringA(LPCSTR,LPCSTR,LPCSTR);
1735 BOOL      WINAPI WriteProfileStringW(LPCWSTR,LPCWSTR,LPCWSTR);
1736 #define     WriteProfileString WINELIB_NAME_AW(WriteProfileString)
1737 #define     Yield32()
1738 LPSTR       WINAPI lstrcatA(LPSTR,LPCSTR);
1739 LPWSTR      WINAPI lstrcatW(LPWSTR,LPCWSTR);
1740 #define     lstrcat WINELIB_NAME_AW(lstrcat)
1741 LPSTR       WINAPI lstrcpyA(LPSTR,LPCSTR);
1742 LPWSTR      WINAPI lstrcpyW(LPWSTR,LPCWSTR);
1743 #define     lstrcpy WINELIB_NAME_AW(lstrcpy)
1744 LPSTR       WINAPI lstrcpynA(LPSTR,LPCSTR,INT);
1745 LPWSTR      WINAPI lstrcpynW(LPWSTR,LPCWSTR,INT);
1746 #define     lstrcpyn WINELIB_NAME_AW(lstrcpyn)
1747 INT       WINAPI lstrlenA(LPCSTR);
1748 INT       WINAPI lstrlenW(LPCWSTR);
1749 #define     lstrlen WINELIB_NAME_AW(lstrlen)
1750 HINSTANCE WINAPI WinExec(LPCSTR,UINT);
1751 LONG        WINAPI _hread(HFILE,LPVOID,LONG);
1752 LONG        WINAPI _hwrite(HFILE,LPCSTR,LONG);
1753 HFILE     WINAPI _lcreat(LPCSTR,INT);
1754 HFILE     WINAPI _lclose(HFILE);
1755 LONG        WINAPI _llseek(HFILE,LONG,INT);
1756 HFILE     WINAPI _lopen(LPCSTR,INT);
1757 UINT      WINAPI _lread(HFILE,LPVOID,UINT);
1758 UINT      WINAPI _lwrite(HFILE,LPCSTR,UINT);
1759 SEGPTR      WINAPI WIN16_GlobalLock16(HGLOBAL16);
1760 INT       WINAPI lstrcmpA(LPCSTR,LPCSTR);
1761 INT       WINAPI lstrcmpW(LPCWSTR,LPCWSTR);
1762 #define     lstrcmp WINELIB_NAME_AW(lstrcmp)
1763 INT       WINAPI lstrcmpiA(LPCSTR,LPCSTR);
1764 INT       WINAPI lstrcmpiW(LPCWSTR,LPCWSTR);
1765 #define     lstrcmpi WINELIB_NAME_AW(lstrcmpi)
1766
1767 /* the following may be macros when compiling Wine */
1768 #ifndef SetLastError
1769 VOID WINAPI SetLastError(DWORD);
1770 #endif
1771 #ifndef GetCurrentThreadId
1772 DWORD WINAPI GetCurrentThreadId(void);
1773 #endif
1774
1775 #ifdef __cplusplus
1776 }
1777 #endif
1778
1779 #endif  /* __WINE_WINBASE_H */