winbase.h
上传用户:kjfoods
上传日期:2020-07-06
资源大小:29949k
文件大小:71k
源码类别:

midi

开发平台:

Unix_Linux

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