source: Daodan/MSYS2/mingw32/i686-w64-mingw32/include/wtypes.idl

Last change on this file was 1166, checked in by rossy, 3 years ago

Daodan: Replace MinGW build env with an up-to-date MSYS2 env

File size: 14.1 KB
Line 
1cpp_quote("/**")
2cpp_quote(" * This file is part of the mingw-w64 runtime package.")
3cpp_quote(" * No warranty is given; refer to the file DISCLAIMER within this package.")
4cpp_quote(" */")
5cpp_quote("")
6
7import "wtypesbase.idl";
8
9cpp_quote("")
10[uuid (D3980A60-910c-1068-9341-00dd010f2f1c), version (0.1), pointer_default (unique)]
11interface IWinTypes {
12 typedef struct tagRemHGLOBAL {
13 long fNullHGlobal;
14 unsigned long cbData;
15 [size_is (cbData)] byte data[];
16 } RemHGLOBAL;
17
18cpp_quote("")
19 typedef struct tagRemHMETAFILEPICT {
20 long mm;
21 long xExt;
22 long yExt;
23 unsigned long cbData;
24 [size_is (cbData)] byte data[];
25 } RemHMETAFILEPICT;
26
27cpp_quote("")
28 typedef struct tagRemHENHMETAFILE {
29 unsigned long cbData;
30 [size_is (cbData)] byte data[];
31 } RemHENHMETAFILE;
32 typedef struct tagRemHBITMAP {
33 unsigned long cbData;
34 [size_is (cbData)] byte data[];
35 } RemHBITMAP;
36
37cpp_quote("")
38 typedef struct tagRemHPALETTE {
39 unsigned long cbData;
40 [size_is (cbData)] byte data[];
41 } RemHPALETTE;
42
43cpp_quote("")
44 typedef struct tagRemBRUSH {
45 unsigned long cbData;
46 [size_is (cbData)] byte data[];
47 } RemHBRUSH;
48
49 cpp_quote("#if 0")
50 typedef UINT_PTR WPARAM;
51 typedef LONG_PTR LPARAM;
52 typedef LONG_PTR LRESULT;
53
54#define DECLARE_WIREM_HANDLE(name) typedef [wire_marshal (wire ## name)] void *name
55#define DECLARE_HANDLE(name) typedef void *name
56
57 DECLARE_HANDLE (HMODULE);
58 DECLARE_HANDLE (HINSTANCE);
59 DECLARE_HANDLE (HTASK);
60 DECLARE_HANDLE (HKEY);
61 DECLARE_HANDLE (HDESK);
62 DECLARE_HANDLE (HMF);
63 DECLARE_HANDLE (HEMF);
64 DECLARE_HANDLE (HPEN);
65 DECLARE_HANDLE (HRSRC);
66 DECLARE_HANDLE (HSTR);
67 DECLARE_HANDLE (HWINSTA);
68 DECLARE_HANDLE (HKL);
69 DECLARE_HANDLE (HGDIOBJ);
70 typedef HANDLE HDWP;
71 typedef INT HFILE;
72
73 typedef DWORD COLORREF;
74 typedef DWORD *LPCOLORREF;
75
76 typedef struct _RECTL {
77 LONG left;
78 LONG top;
79 LONG right;
80 LONG bottom;
81 } RECTL,*PRECTL,*LPRECTL;
82
83 typedef struct tagPOINT {
84 LONG x;
85 LONG y;
86 } POINT,*PPOINT,*LPPOINT;
87
88 typedef struct _POINTL {
89 LONG x;
90 LONG y;
91 } POINTL,*PPOINTL;
92
93 typedef struct tagSIZE {
94 LONG cx;
95 LONG cy;
96 } SIZE,*PSIZE,*LPSIZE;
97
98 typedef struct tagSIZEL {
99 LONG cx;
100 LONG cy;
101 } SIZEL,*PSIZEL,*LPSIZEL;
102
103 cpp_quote("#endif")
104
105cpp_quote("")
106 cpp_quote("#ifndef _PALETTEENTRY_DEFINED")
107 cpp_quote("#define _PALETTEENTRY_DEFINED")
108 cpp_quote("")
109 typedef struct tagPALETTEENTRY {
110 BYTE peRed;
111 BYTE peGreen;
112 BYTE peBlue;
113 BYTE peFlags;
114 } PALETTEENTRY,*PPALETTEENTRY,*LPPALETTEENTRY;
115 cpp_quote("#endif")
116 cpp_quote("")
117 cpp_quote("#ifndef _LOGPALETTE_DEFINED")
118 cpp_quote("#define _LOGPALETTE_DEFINED")
119 cpp_quote("")
120 typedef struct tagLOGPALETTE {
121 WORD palVersion;
122 WORD palNumEntries;
123 [size_is (palNumEntries)] PALETTEENTRY palPalEntry[];
124 } LOGPALETTE,*PLOGPALETTE,*LPLOGPALETTE;
125 cpp_quote("#endif")
126 cpp_quote("")
127 cpp_quote("#ifndef _WINDEF_")
128 typedef const RECTL *LPCRECTL;
129 typedef struct tagRECT {
130 LONG left;
131 LONG top;
132 LONG right;
133 LONG bottom;
134 } RECT,*PRECT,*LPRECT;
135 typedef const RECT *LPCRECT;
136 cpp_quote("#endif")
137
138cpp_quote("")
139 cpp_quote("#if 0")
140 typedef FMTID *REFFMTID;
141 cpp_quote("#endif")
142
143cpp_quote("")
144 cpp_quote("#ifndef _ROTFLAGS_DEFINED")
145 cpp_quote("#define _ROTFLAGS_DEFINED")
146 cpp_quote("#define ROTFLAGS_REGISTRATIONKEEPSALIVE 0x1")
147 cpp_quote("#define ROTFLAGS_ALLOWANYCLIENT 0x2")
148 cpp_quote("#endif")
149
150cpp_quote("")
151 cpp_quote("#ifndef _ROT_COMPARE_MAX_DEFINED")
152 cpp_quote("#define _ROT_COMPARE_MAX_DEFINED")
153 cpp_quote("#define ROT_COMPARE_MAX 2048")
154 cpp_quote("#endif")
155
156cpp_quote("")
157 typedef enum tagDVASPECT {
158 DVASPECT_CONTENT = 1,
159 DVASPECT_THUMBNAIL = 2,
160 DVASPECT_ICON = 4,
161 DVASPECT_DOCPRINT = 8
162 } DVASPECT;
163
164 cpp_quote("")
165 typedef enum tagSTGC {
166 STGC_DEFAULT = 0,
167 STGC_OVERWRITE = 1,
168 STGC_ONLYIFCURRENT = 2,
169 STGC_DANGEROUSLYCOMMITMERELYTODISKCACHE = 4,
170 STGC_CONSOLIDATE = 8
171 } STGC;
172
173cpp_quote("")
174 typedef enum tagSTGMOVE {
175 STGMOVE_MOVE = 0,
176 STGMOVE_COPY = 1,
177 STGMOVE_SHALLOWCOPY = 2
178 } STGMOVE;
179
180cpp_quote("")
181 typedef enum tagSTATFLAG {
182 STATFLAG_DEFAULT = 0,
183 STATFLAG_NONAME = 1,
184 STATFLAG_NOOPEN = 2
185 } STATFLAG;
186 typedef [context_handle] void *HCONTEXT;
187cpp_quote("")
188 cpp_quote("#ifndef _LCID_DEFINED")
189 cpp_quote("#define _LCID_DEFINED")
190 typedef DWORD LCID;
191 cpp_quote("#endif")
192
193cpp_quote("")
194 cpp_quote("#ifndef _LANGID_DEFINED")
195 cpp_quote("#define _LANGID_DEFINED")
196 typedef USHORT LANGID;
197 cpp_quote("#endif")
198
199cpp_quote("")
200 const unsigned long WDT_INPROC_CALL = 0x48746457;
201 const unsigned long WDT_REMOTE_CALL = 0x52746457;
202 const unsigned long WDT_INPROC64_CALL = 0x50746457;
203
204cpp_quote("")
205 typedef union _userCLIPFORMAT switch (long fContext) u {
206 case WDT_INPROC_CALL: DWORD dwValue;
207 case WDT_REMOTE_CALL: [string] wchar_t *pwszName;
208 } userCLIPFORMAT;
209cpp_quote("")
210 typedef [unique] userCLIPFORMAT *wireCLIPFORMAT;
211 typedef [wire_marshal (wireCLIPFORMAT)] WORD CLIPFORMAT;
212cpp_quote("")
213 typedef union _GDI_NONREMOTE switch (long fContext) u {
214 case WDT_INPROC_CALL: long hInproc;
215 case WDT_REMOTE_CALL: DWORD_BLOB *hRemote;
216 } GDI_NONREMOTE;
217cpp_quote("")
218 typedef union _userHGLOBAL switch (long fContext) u {
219 case WDT_INPROC_CALL: long hInproc;
220 case WDT_REMOTE_CALL: FLAGGED_BYTE_BLOB *hRemote;
221 case WDT_INPROC64_CALL: __int64 hInproc64;
222 } userHGLOBAL;
223cpp_quote("")
224 typedef [unique] userHGLOBAL *wireHGLOBAL;
225cpp_quote("")
226 typedef union _userHMETAFILE switch (long fContext) u {
227 case WDT_INPROC_CALL: long hInproc;
228 case WDT_REMOTE_CALL: BYTE_BLOB *hRemote;
229 case WDT_INPROC64_CALL: __int64 hInproc64;
230 } userHMETAFILE;
231cpp_quote("")
232 typedef struct _remoteMETAFILEPICT {
233 long mm;
234 long xExt;
235 long yExt;
236 userHMETAFILE *hMF;
237 } remoteMETAFILEPICT;
238cpp_quote("")
239 typedef union _userHMETAFILEPICT switch (long fContext) u {
240 case WDT_INPROC_CALL: long hInproc;
241 case WDT_REMOTE_CALL: remoteMETAFILEPICT *hRemote;
242 case WDT_INPROC64_CALL: __int64 hInproc64;
243 } userHMETAFILEPICT;
244cpp_quote("")
245 typedef union _userHENHMETAFILE switch (long fContext) u {
246 case WDT_INPROC_CALL: long hInproc;
247 case WDT_REMOTE_CALL: BYTE_BLOB *hRemote;
248 case WDT_INPROC64_CALL: __int64 hInproc64;
249 } userHENHMETAFILE;
250cpp_quote("")
251 typedef struct _userBITMAP {
252 LONG bmType;
253 LONG bmWidth;
254 LONG bmHeight;
255 LONG bmWidthBytes;
256 WORD bmPlanes;
257 WORD bmBitsPixel;
258 ULONG cbSize;
259 [size_is (cbSize)] byte pBuffer[];
260 } userBITMAP;
261cpp_quote("")
262 typedef union _userHBITMAP switch (long fContext) u {
263 case WDT_INPROC_CALL: long hInproc;
264 case WDT_REMOTE_CALL: userBITMAP *hRemote;
265 case WDT_INPROC64_CALL: __int64 hInproc64;
266 } userHBITMAP;
267cpp_quote("")
268 typedef union _userHPALETTE switch (long fContext) u {
269 case WDT_INPROC_CALL: long hInproc;
270 case WDT_REMOTE_CALL: LOGPALETTE *hRemote;
271 case WDT_INPROC64_CALL: __int64 hInproc64;
272 } userHPALETTE;
273cpp_quote("")
274 typedef union _RemotableHandle switch (long fContext) u {
275 case WDT_INPROC_CALL: long hInproc;
276 case WDT_REMOTE_CALL: long hRemote;
277 } RemotableHandle;
278cpp_quote("")
279 typedef [unique] RemotableHandle *wireHWND;
280 typedef [unique] RemotableHandle *wireHMENU;
281 typedef [unique] RemotableHandle *wireHACCEL;
282 typedef [unique] RemotableHandle *wireHBRUSH;
283 typedef [unique] RemotableHandle *wireHFONT;
284 typedef [unique] RemotableHandle *wireHDC;
285 typedef [unique] RemotableHandle *wireHICON;
286 typedef [unique] RemotableHandle *wireHRGN;
287 typedef [unique] RemotableHandle *wireHMONITOR;
288cpp_quote("")
289 cpp_quote("#if 0")
290#ifndef _MIDL_DECLARE_WIREM_HANDLE
291 DECLARE_WIREM_HANDLE (HWND);
292 DECLARE_WIREM_HANDLE (HMENU);
293 DECLARE_WIREM_HANDLE (HACCEL);
294 DECLARE_WIREM_HANDLE (HBRUSH);
295 DECLARE_WIREM_HANDLE (HFONT);
296 DECLARE_WIREM_HANDLE (HDC);
297 DECLARE_WIREM_HANDLE (HICON);
298 DECLARE_WIREM_HANDLE (HRGN);
299 DECLARE_WIREM_HANDLE (HMONITOR);
300#endif
301
302cpp_quote("")
303 cpp_quote("#ifndef _HCURSOR_DEFINED")
304 cpp_quote("#define _HCURSOR_DEFINED")
305 typedef HICON HCURSOR;
306 cpp_quote("#endif")
307 cpp_quote("")
308 cpp_quote("#endif")
309
310cpp_quote("")
311 cpp_quote("#ifndef _TEXTMETRIC_DEFINED")
312 cpp_quote("#define _TEXTMETRIC_DEFINED")
313cpp_quote("")
314 typedef struct tagTEXTMETRICW {
315 LONG tmHeight;
316 LONG tmAscent;
317 LONG tmDescent;
318 LONG tmInternalLeading;
319 LONG tmExternalLeading;
320 LONG tmAveCharWidth;
321 LONG tmMaxCharWidth;
322 LONG tmWeight;
323 LONG tmOverhang;
324 LONG tmDigitizedAspectX;
325 LONG tmDigitizedAspectY;
326 WCHAR tmFirstChar;
327 WCHAR tmLastChar;
328 WCHAR tmDefaultChar;
329 WCHAR tmBreakChar;
330 BYTE tmItalic;
331 BYTE tmUnderlined;
332 BYTE tmStruckOut;
333 BYTE tmPitchAndFamily;
334 BYTE tmCharSet;
335 } TEXTMETRICW,*PTEXTMETRICW,*LPTEXTMETRICW;
336 cpp_quote("#endif")
337
338cpp_quote("")
339 cpp_quote("#ifndef _WIN32")
340 cpp_quote("#ifndef WINAPI")
341 typedef struct tagMSG {
342 HWND hwnd;
343 UINT message;
344 WPARAM wParam;
345 LPARAM lParam;
346 DWORD time;
347 POINT pt;
348 } MSG,*PMSG,*NPMSG,*LPMSG;
349 cpp_quote("#endif")
350 cpp_quote("#endif")
351
352cpp_quote("")
353 typedef [unique] userHBITMAP *wireHBITMAP;
354 typedef [unique] userHPALETTE *wireHPALETTE;
355 typedef [unique] userHENHMETAFILE *wireHENHMETAFILE;
356 typedef [unique] userHMETAFILE *wireHMETAFILE;
357 typedef [unique] userHMETAFILEPICT *wireHMETAFILEPICT;
358cpp_quote("")
359 cpp_quote("#if 0")
360 DECLARE_WIREM_HANDLE (HGLOBAL);
361 typedef HGLOBAL HLOCAL;
362 DECLARE_WIREM_HANDLE (HBITMAP);
363 DECLARE_WIREM_HANDLE (HPALETTE);
364 DECLARE_WIREM_HANDLE (HENHMETAFILE);
365 DECLARE_WIREM_HANDLE (HMETAFILE);
366 cpp_quote("#endif")
367cpp_quote("")
368 DECLARE_WIREM_HANDLE (HMETAFILEPICT);
369}
370
371cpp_quote("")
372typedef double DATE;
373cpp_quote("")
374cpp_quote("#ifndef _tagCY_DEFINED")
375cpp_quote("#define _tagCY_DEFINED")
376cpp_quote("#define _CY_DEFINED")
377cpp_quote("")
378cpp_quote("#if 0")
379typedef struct tagCY {
380 LONGLONG int64;
381} CY;
382cpp_quote("#else")
383cpp_quote("typedef union tagCY {")
384cpp_quote(" __C89_NAMELESS struct {")
385cpp_quote(" unsigned __LONG32 Lo;")
386cpp_quote(" __LONG32 Hi;")
387cpp_quote(" } DUMMYSTRUCTNAME;")
388cpp_quote(" LONGLONG int64;")
389cpp_quote("} CY;")
390cpp_quote("#endif")
391cpp_quote("#endif")
392
393cpp_quote("")
394typedef CY *LPCY;
395cpp_quote("")
396cpp_quote("#if 0")
397typedef struct tagDEC {
398 USHORT wReserved;
399 BYTE scale;
400 BYTE sign;
401 ULONG Hi32;
402 ULONGLONG Lo64;
403} DECIMAL;
404cpp_quote("#else")
405cpp_quote("typedef struct tagDEC {")
406cpp_quote(" USHORT wReserved;")
407cpp_quote(" __C89_NAMELESS union {")
408cpp_quote(" __C89_NAMELESS struct {")
409cpp_quote(" BYTE scale;")
410cpp_quote(" BYTE sign;")
411cpp_quote(" } DUMMYSTRUCTNAME;")
412cpp_quote(" USHORT signscale;")
413cpp_quote(" } DUMMYUNIONNAME;")
414cpp_quote(" ULONG Hi32;")
415cpp_quote(" __C89_NAMELESS union {")
416cpp_quote(" __C89_NAMELESS struct {")
417cpp_quote(" ULONG Lo32;")
418cpp_quote(" ULONG Mid32;")
419cpp_quote(" } DUMMYSTRUCTNAME2;")
420cpp_quote(" ULONGLONG Lo64;")
421cpp_quote(" } DUMMYUNIONNAME2;")
422cpp_quote("} DECIMAL;")
423
424cpp_quote("")
425cpp_quote("#define DECIMAL_NEG ((BYTE)0x80)")
426cpp_quote("#define DECIMAL_SETZERO(dec) { (dec).Lo64 = 0; (dec).Hi32 = 0; (dec).signscale = 0; }")
427cpp_quote("#endif")
428
429cpp_quote("")
430typedef DECIMAL *LPDECIMAL;
431
432cpp_quote("")
433typedef [unique] FLAGGED_WORD_BLOB *wireBSTR;
434typedef [wire_marshal (wireBSTR)] OLECHAR *BSTR;
435cpp_quote("")
436typedef BSTR *LPBSTR;
437cpp_quote("")
438typedef short VARIANT_BOOL;
439cpp_quote("#if 0")
440typedef VARIANT_BOOL _VARIANT_BOOL;
441cpp_quote("#else")
442cpp_quote("#define _VARIANT_BOOL /##/")
443cpp_quote("#endif")
444
445cpp_quote("")
446cpp_quote("#ifndef _tagBSTRBLOB_DEFINED")
447cpp_quote("#define _tagBSTRBLOB_DEFINED")
448cpp_quote("")
449typedef struct tagBSTRBLOB {
450 ULONG cbSize;
451 [size_is (cbSize)] BYTE *pData;
452} BSTRBLOB,*LPBSTRBLOB;
453cpp_quote("#endif")
454cpp_quote("")
455
456cpp_quote("#define VARIANT_TRUE ((VARIANT_BOOL)-1)")
457cpp_quote("#define VARIANT_FALSE ((VARIANT_BOOL)0)")
458
459cpp_quote("")
460typedef struct tagCLIPDATA {
461 ULONG cbSize;
462 long ulClipFmt;
463 [size_is (cbSize-4)] BYTE *pClipData;
464} CLIPDATA;
465cpp_quote("")
466cpp_quote("#define CBPCLIPDATA(clipdata) ((clipdata).cbSize - sizeof((clipdata).ulClipFmt))")
467
468cpp_quote("")
469typedef unsigned short VARTYPE;
470
471cpp_quote("")
472enum VARENUM {
473 VT_EMPTY = 0,
474 VT_NULL = 1,
475 VT_I2 = 2,
476 VT_I4 = 3,
477 VT_R4 = 4,
478 VT_R8 = 5,
479 VT_CY = 6,
480 VT_DATE = 7,
481 VT_BSTR = 8,
482 VT_DISPATCH = 9,
483 VT_ERROR = 10,
484 VT_BOOL = 11,
485 VT_VARIANT = 12,
486 VT_UNKNOWN = 13,
487 VT_DECIMAL = 14,
488 VT_I1 = 16,
489 VT_UI1 = 17,
490 VT_UI2 = 18,
491 VT_UI4 = 19,
492 VT_I8 = 20,
493 VT_UI8 = 21,
494 VT_INT = 22,
495 VT_UINT = 23,
496 VT_VOID = 24,
497 VT_HRESULT = 25,
498 VT_PTR = 26,
499 VT_SAFEARRAY = 27,
500 VT_CARRAY = 28,
501 VT_USERDEFINED = 29,
502 VT_LPSTR = 30,
503 VT_LPWSTR = 31,
504 VT_RECORD = 36,
505 VT_INT_PTR = 37,
506 VT_UINT_PTR = 38,
507 VT_FILETIME = 64,
508 VT_BLOB = 65,
509 VT_STREAM = 66,
510 VT_STORAGE = 67,
511 VT_STREAMED_OBJECT = 68,
512 VT_STORED_OBJECT = 69,
513 VT_BLOB_OBJECT = 70,
514 VT_CF = 71,
515 VT_CLSID = 72,
516 VT_VERSIONED_STREAM= 73,
517 VT_BSTR_BLOB = 0x0fff,
518 VT_VECTOR = 0x1000,
519 VT_ARRAY = 0x2000,
520 VT_BYREF = 0x4000,
521 VT_RESERVED = 0x8000,
522 VT_ILLEGAL = 0xffff,
523 VT_ILLEGALMASKED = 0x0fff,
524 VT_TYPEMASK = 0x0fff
525};
526cpp_quote("")
527typedef ULONG PROPID;
528cpp_quote("")
529cpp_quote("#ifndef PROPERTYKEY_DEFINED")
530cpp_quote("#define PROPERTYKEY_DEFINED")
531cpp_quote("")
532typedef struct _tagpropertykey {
533 GUID fmtid;
534 DWORD pid;
535} PROPERTYKEY;
536cpp_quote("#endif")
537
538cpp_quote("")
539typedef struct tagCSPLATFORM {
540 DWORD dwPlatformId;
541 DWORD dwVersionHi;
542 DWORD dwVersionLo;
543 DWORD dwProcessorArch;
544} CSPLATFORM;
545
546cpp_quote("")
547typedef struct tagQUERYCONTEXT {
548 DWORD dwContext;
549 CSPLATFORM Platform;
550 LCID Locale;
551 DWORD dwVersionHi;
552 DWORD dwVersionLo;
553} QUERYCONTEXT;
554
555cpp_quote("")
556typedef [v1_enum] enum tagTYSPEC {
557 TYSPEC_CLSID,
558 TYSPEC_FILEEXT,
559 TYSPEC_MIMETYPE,
560 TYSPEC_FILENAME,
561 TYSPEC_PROGID,
562 TYSPEC_PACKAGENAME,
563 TYSPEC_OBJECTID
564} TYSPEC;
565
566cpp_quote("")
567typedef union switch (DWORD tyspec) {
568 case TYSPEC_CLSID: CLSID clsid;
569 case TYSPEC_FILEEXT: LPOLESTR pFileExt;
570 case TYSPEC_MIMETYPE: LPOLESTR pMimeType;
571 case TYSPEC_PROGID: LPOLESTR pProgId;
572 case TYSPEC_FILENAME: LPOLESTR pFileName;
573 case TYSPEC_PACKAGENAME: struct {
574 LPOLESTR pPackageName;
575 GUID PolicyId;
576 } ByName;
577 case TYSPEC_OBJECTID: struct {
578 GUID ObjectId;
579 GUID PolicyId;
580 } ByObjectId;
581} uCLSSPEC;
Note: See TracBrowser for help on using the repository browser.