Add CF_UNICODETEXT as primary text clipboard format.
[wine.git] / include / wtypes.h
blobb8f792345a022f84587a9c25381e4eb9d55ae17d
1 /*
2 * Defines the basic types used by COM interfaces.
3 */
5 #ifndef __WINE_WTYPES_H
6 #define __WINE_WTYPES_H
8 #include "basetsd.h"
9 #include "guiddef.h"
10 #include "rpc.h"
11 #include "rpcndr.h"
13 typedef WORD CLIPFORMAT, *LPCLIPFORMAT;
15 /* FIXME: does not belong here */
16 typedef CHAR OLECHAR16;
17 typedef LPSTR LPOLESTR16;
18 typedef LPCSTR LPCOLESTR16;
19 typedef OLECHAR16 *BSTR16;
20 typedef BSTR16 *LPBSTR16;
21 #define OLESTR16(x) x
23 typedef WCHAR OLECHAR;
24 typedef LPWSTR LPOLESTR;
25 typedef LPCWSTR LPCOLESTR;
26 typedef OLECHAR *BSTR;
27 typedef BSTR *LPBSTR;
29 #ifndef _DWORDLONG_
30 #define _DWORDLONG_
31 typedef __uint64 DWORDLONG, *PDWORDLONG;
32 #endif
34 #ifndef _ULONGLONG_
35 #define _ULONGLONG_
36 typedef __int64 LONGLONG, *PLONGLONG;
37 typedef __uint64 ULONGLONG, *PULONGLONG;
38 #endif
40 #define OLESTR(x) L##x
42 typedef enum tagDVASPECT
44 DVASPECT_CONTENT = 1,
45 DVASPECT_THUMBNAIL = 2,
46 DVASPECT_ICON = 4,
47 DVASPECT_DOCPRINT = 8
48 } DVASPECT;
50 typedef enum tagSTGC
52 STGC_DEFAULT = 0,
53 STGC_OVERWRITE = 1,
54 STGC_ONLYIFCURRENT = 2,
55 STGC_DANGEROUSLYCOMMITMERELYTODISKCACHE = 4,
56 STGC_CONSOLIDATE = 8
57 } STGC;
59 typedef enum tagSTGMOVE
61 STGMOVE_MOVE = 0,
62 STGMOVE_COPY = 1,
63 STGMOVE_SHALLOWCOPY = 2
64 } STGMOVE;
67 typedef struct _COAUTHIDENTITY
69 USHORT* User;
70 ULONG UserLength;
71 USHORT* Domain;
72 ULONG DomainLength;
73 USHORT* Password;
74 ULONG PasswordLength;
75 ULONG Flags;
76 } COAUTHIDENTITY;
78 typedef struct _COAUTHINFO
80 DWORD dwAuthnSvc;
81 DWORD dwAuthzSvc;
82 LPWSTR pwszServerPrincName;
83 DWORD dwAuthnLevel;
84 DWORD dwImpersonationLevel;
85 COAUTHIDENTITY* pAuthIdentityData;
86 DWORD dwCapabilities;
87 } COAUTHINFO;
89 typedef struct _COSERVERINFO
91 DWORD dwReserved1;
92 LPWSTR pwszName;
93 COAUTHINFO* pAuthInfo;
94 DWORD dwReserved2;
95 } COSERVERINFO;
97 typedef enum tagCLSCTX
99 CLSCTX_INPROC_SERVER = 0x1,
100 CLSCTX_INPROC_HANDLER = 0x2,
101 CLSCTX_LOCAL_SERVER = 0x4,
102 CLSCTX_INPROC_SERVER16 = 0x8,
103 CLSCTX_REMOTE_SERVER = 0x10,
104 CLSCTX_INPROC_HANDLER16 = 0x20,
105 CLSCTX_INPROC_SERVERX86 = 0x40,
106 CLSCTX_INPROC_HANDLERX86 = 0x80,
107 CLSCTX_ESERVER_HANDLER = 0x100
108 } CLSCTX;
110 #define CLSCTX_INPROC (CLSCTX_INPROC_SERVER | CLSCTX_INPROC_HANDLER)
111 #define CLSCTX_ALL (CLSCTX_INPROC_SERVER | CLSCTX_INPROC_HANDLER | CLSCTX_LOCAL_SERVER | CLSCTX_REMOTE_SERVER)
112 #define CLSCTX_SERVER (CLSCTX_INPROC_SERVER | CLSCTX_LOCAL_SERVER | CLSCTX_REMOTE_SERVER)
114 typedef enum tagMSHLFLAGS
116 MSHLFLAGS_NORMAL = 0,
117 MSHLFLAGS_TABLESTRONG = 1,
118 MSHLFLAGS_TABLEWEAK = 2,
119 MSHLFLAGS_NOPING = 4
120 } MSHLFLAGS;
122 typedef enum tagMSHCTX
124 MSHCTX_LOCAL = 0,
125 MSHCTX_NOSHAREDMEM = 1,
126 MSHCTX_DIFFERENTMACHINE = 2,
127 MSHCTX_INPROC = 3
128 } MSHCTX;
130 typedef unsigned short VARTYPE;
132 typedef ULONG PROPID;
134 #ifndef _tagBLOB_DEFINED
135 #define _tagBLOB_DEFINED
136 #define _BLOB_DEFINED
137 #define _LPBLOB_DEFINED
138 typedef struct tagBLOB
140 ULONG cbSize;
141 BYTE *pBlobData;
142 } BLOB, *LPBLOB;
143 #endif
145 #ifndef _tagCY_DEFINED
146 #define _tagCY_DEFINED
148 typedef union tagCY {
149 struct {
150 #ifdef BIG_ENDIAN
151 LONG Hi;
152 LONG Lo;
153 #else /* defined(BIG_ENDIAN) */
154 ULONG Lo;
155 LONG Hi;
156 #endif /* defined(BIG_ENDIAN) */
157 } DUMMYSTRUCTNAME;
158 LONGLONG int64;
159 } CY;
161 #endif /* _tagCY_DEFINED */
164 * 0 == FALSE and -1 == TRUE
166 #define VARIANT_TRUE ((VARIANT_BOOL)0xFFFF)
167 #define VARIANT_FALSE ((VARIANT_BOOL)0x0000)
168 typedef short VARIANT_BOOL,_VARIANT_BOOL;
170 typedef struct tagCLIPDATA
172 ULONG cbSize;
173 long ulClipFmt;
174 BYTE *pClipData;
175 } CLIPDATA;
177 /* Macro to calculate the size of the above pClipData */
178 #define CBPCLIPDATA(clipdata) ( (clipdata).cbSize - sizeof((clipdata).ulClipFmt) )
180 typedef LONG SCODE;
182 #ifndef _FILETIME_
183 #define _FILETIME_
184 /* 64 bit number of 100 nanoseconds intervals since January 1, 1601 */
185 typedef struct
187 DWORD dwLowDateTime;
188 DWORD dwHighDateTime;
189 } FILETIME, *LPFILETIME;
190 #endif /* _FILETIME_ */
192 #ifndef _SECURITY_DEFINED
193 #define _SECURITY_DEFINED
195 typedef struct {
196 BYTE Value[6];
197 } SID_IDENTIFIER_AUTHORITY,*PSID_IDENTIFIER_AUTHORITY;
199 typedef struct _SID {
200 BYTE Revision;
201 BYTE SubAuthorityCount;
202 SID_IDENTIFIER_AUTHORITY IdentifierAuthority;
203 DWORD SubAuthority[1];
204 } SID,*PSID;
207 * ACL
210 typedef struct _ACL {
211 BYTE AclRevision;
212 BYTE Sbz1;
213 WORD AclSize;
214 WORD AceCount;
215 WORD Sbz2;
216 } ACL, *PACL;
218 typedef DWORD SECURITY_INFORMATION;
219 typedef WORD SECURITY_DESCRIPTOR_CONTROL, *PSECURITY_DESCRIPTOR_CONTROL;
220 typedef DWORD ACCESS_MASK, *PACCESS_MASK;
222 typedef PVOID PGENERIC_MAPPING;
224 /* The security descriptor structure */
225 typedef struct {
226 BYTE Revision;
227 BYTE Sbz1;
228 SECURITY_DESCRIPTOR_CONTROL Control;
229 PSID Owner;
230 PSID Group;
231 PACL Sacl;
232 PACL Dacl;
233 } SECURITY_DESCRIPTOR, *PSECURITY_DESCRIPTOR;
235 #endif /* _SECURITY_DEFINED */
237 #ifndef _ROTFLAGS_DEFINED
238 #define _ROTFLAGS_DEFINED
239 #define ROTFLAGS_REGISTRATIONKEEPSALIVE 0x1
240 #define ROTFLAGS_ALLOWANYCLIENT 0x2
241 #endif /* !defined(_ROTFLAGS_DEFINED) */
243 #endif /* __WINE_WTYPES_H */