Release 960131
[wine/multimedia.git] / include / kernel32.h
blob12e5761785ee4ff1cfe2b2b58b3b9e82cd3d970f
1 /* kernel32.h - 95-09-14 Cameron Heide
3 * Win32 functions, structures, and types related to kernel functions
4 */
5 #ifndef __WINE_KERNEL32_H
6 #define __WINE_KERNEL32_H
8 #include <stddef.h>
10 int KERN32_Init(void);
11 void SetLastError(DWORD error);
12 DWORD ErrnoToLastError(int errno_num);
14 /* Code page information.
16 typedef struct {
17 DWORD MaxCharSize;
18 BYTE DefaultChar[2];
19 BYTE LeadBytes[5];
20 } CPINFO, *LPCPINFO;
22 /* The 'overlapped' data structure used by async I/O functions.
24 typedef struct {
25 DWORD Internal;
26 DWORD InternalHigh;
27 DWORD Offset;
28 DWORD OffsetHigh;
29 HANDLE hEvent;
30 } OVERLAPPED, *LPOVERLAPPED;
32 /* Process startup information.
34 typedef struct {
35 DWORD cb;
36 LPSTR lpReserved;
37 LPSTR lpDesktop;
38 LPSTR lpTitle;
39 DWORD dwX;
40 DWORD dwY;
41 DWORD dwXSize;
42 DWORD dwYSize;
43 DWORD dwXCountChars;
44 DWORD dwYCountChars;
45 DWORD dwFillAttribute;
46 DWORD dwFlags;
47 WORD wShowWindow;
48 WORD cbReserved2;
49 BYTE *lpReserved2;
50 HANDLE hStdInput;
51 HANDLE hStdOutput;
52 HANDLE hStdError;
53 } STARTUPINFO, *LPSTARTUPINFO;
55 typedef struct {
56 LONG Bias;
57 WCHAR StandardName[32];
58 SYSTEMTIME StandardDate;
59 LONG StandardBias;
60 WCHAR DaylightName[32];
61 SYSTEMTIME DaylightDate;
62 LONG DaylightBias;
63 } TIME_ZONE_INFORMATION, *LPTIME_ZONE_INFORMATION;
65 #define TIME_ZONE_ID_UNKNOWN 0
66 #define TIME_ZONE_ID_STANDARD 1
67 #define TIME_ZONE_ID_DAYLIGHT 2
70 /* File object type definitions
72 #define FILE_TYPE_UNKNOWN 0
73 #define FILE_TYPE_DISK 1
74 #define FILE_TYPE_CHAR 2
75 #define FILE_TYPE_PIPE 3
76 #define FILE_TYPE_REMOTE 32768
78 /* File creation flags
80 #define GENERIC_READ 0x80000000L
81 #define GENERIC_WRITE 0x40000000L
82 #define CREATE_NEW 1
83 #define CREATE_ALWAYS 2
84 #define OPEN_EXISTING 3
85 #define OPEN_ALWAYS 4
86 #define TRUNCATE_EXISTING 5
88 /* Standard handle identifiers
90 #define STD_INPUT_HANDLE ((DWORD) -10)
91 #define STD_OUTPUT_HANDLE ((DWORD) -11)
92 #define STD_ERROR_HANDLE ((DWORD) -12)
94 /* The security attributes structure
96 typedef struct {
97 DWORD nLength;
98 void *lpSecurityDescriptor;
99 BOOL bInheritHandle;
100 } SECURITY_ATTRIBUTES, *LPSECURITY_ATTRIBUTES;
102 typedef struct
104 int dwLowDateTime;
105 int dwHighDateTime;
106 } FILETIME;
108 typedef struct
110 int dwFileAttributes;
111 FILETIME ftCreationTime;
112 FILETIME ftLastAccessTime;
113 FILETIME ftLastWriteTime;
114 int dwVolumeSerialNumber;
115 int nFileSizeHigh;
116 int nFileSizeLow;
117 int nNumberOfLinks;
118 int nFileIndexHigh;
119 int nFileIndexLow;
120 } BY_HANDLE_FILE_INFORMATION ;
122 /* File attribute flags
124 #define FILE_ATTRIBUTE_ARCHIVE 0x0020
125 #define FILE_ATTRIBUTE_COMPRESSED 0x0800
126 #define FILE_ATTRIBUTE_DIRECTORY 0x0010
127 #define FILE_ATTRIBUTE_HIDDEN 0x0002
128 #define FILE_ATTRIBUTE_NORMAL 0x0080
129 #define FILE_ATTRIBUTE_READONLY 0x0001
130 #define FILE_ATTRIBUTE_SYSTEM 0x0004
131 #define FILE_ATTRIBUTE_TEMPORARY 0x0100
132 #define FILE_ATTRIBUTE_ATOMIC_WRITE 0x0200
133 #define FILE_ATTRIBUTE_XACTION_WRITE 0x0400
135 #endif /* __WINE_KERNEL32_H */