|
1
|
+diff --git a/mingw-w64-headers/include/weakreference.h b/mingw-w64-headers/include/weakreference.h
|
|
2
|
+new file mode 100644
|
|
3
|
+index 000000000..9776dd194
|
|
4
|
+--- /dev/null
|
|
5
|
++++ b/mingw-w64-headers/include/weakreference.h
|
|
6
|
+@@ -0,0 +1,218 @@
|
|
7
|
++/*** Autogenerated by WIDL 8.0 from include/weakreference.idl - Do not edit ***/
|
|
8
|
++
|
|
9
|
++#ifdef _WIN32
|
|
10
|
++#ifndef __REQUIRED_RPCNDR_H_VERSION__
|
|
11
|
++#define __REQUIRED_RPCNDR_H_VERSION__ 475
|
|
12
|
++#endif
|
|
13
|
++#include <rpc.h>
|
|
14
|
++#include <rpcndr.h>
|
|
15
|
++#endif
|
|
16
|
++
|
|
17
|
++#ifndef COM_NO_WINDOWS_H
|
|
18
|
++#include <windows.h>
|
|
19
|
++#include <ole2.h>
|
|
20
|
++#endif
|
|
21
|
++
|
|
22
|
++#ifndef __weakreference_h__
|
|
23
|
++#define __weakreference_h__
|
|
24
|
++
|
|
25
|
++#ifndef __WIDL_INLINE
|
|
26
|
++#if defined(__cplusplus) || defined(_MSC_VER)
|
|
27
|
++#define __WIDL_INLINE inline
|
|
28
|
++#elif defined(__GNUC__)
|
|
29
|
++#define __WIDL_INLINE __inline__
|
|
30
|
++#endif
|
|
31
|
++#endif
|
|
32
|
++
|
|
33
|
++/* Forward declarations */
|
|
34
|
++
|
|
35
|
++#ifndef __IWeakReference_FWD_DEFINED__
|
|
36
|
++#define __IWeakReference_FWD_DEFINED__
|
|
37
|
++typedef interface IWeakReference IWeakReference;
|
|
38
|
++#ifdef __cplusplus
|
|
39
|
++interface IWeakReference;
|
|
40
|
++#endif /* __cplusplus */
|
|
41
|
++#endif
|
|
42
|
++
|
|
43
|
++#ifndef __IWeakReferenceSource_FWD_DEFINED__
|
|
44
|
++#define __IWeakReferenceSource_FWD_DEFINED__
|
|
45
|
++typedef interface IWeakReferenceSource IWeakReferenceSource;
|
|
46
|
++#ifdef __cplusplus
|
|
47
|
++interface IWeakReferenceSource;
|
|
48
|
++#endif /* __cplusplus */
|
|
49
|
++#endif
|
|
50
|
++
|
|
51
|
++/* Headers for imported files */
|
|
52
|
++
|
|
53
|
++#include <inspectable.h>
|
|
54
|
++
|
|
55
|
++#ifdef __cplusplus
|
|
56
|
++extern "C" {
|
|
57
|
++#endif
|
|
58
|
++
|
|
59
|
++/*****************************************************************************
|
|
60
|
++ * IWeakReference interface
|
|
61
|
++ */
|
|
62
|
++#ifndef __IWeakReference_INTERFACE_DEFINED__
|
|
63
|
++#define __IWeakReference_INTERFACE_DEFINED__
|
|
64
|
++
|
|
65
|
++DEFINE_GUID(IID_IWeakReference, 0x00000037, 0x0000, 0x0000, 0xc0,0x00, 0x00,0x00,0x00,0x00,0x00,0x46);
|
|
66
|
++#if defined(__cplusplus) && !defined(CINTERFACE)
|
|
67
|
++MIDL_INTERFACE("00000037-0000-0000-c000-000000000046")
|
|
68
|
++IWeakReference : public IUnknown
|
|
69
|
++{
|
|
70
|
++ virtual HRESULT STDMETHODCALLTYPE Resolve(
|
|
71
|
++ REFIID riid,
|
|
72
|
++ IInspectable **objectReference) = 0;
|
|
73
|
++
|
|
74
|
++};
|
|
75
|
++#ifdef __CRT_UUID_DECL
|
|
76
|
++__CRT_UUID_DECL(IWeakReference, 0x00000037, 0x0000, 0x0000, 0xc0,0x00, 0x00,0x00,0x00,0x00,0x00,0x46)
|
|
77
|
++#endif
|
|
78
|
++#else
|
|
79
|
++typedef struct IWeakReferenceVtbl {
|
|
80
|
++ BEGIN_INTERFACE
|
|
81
|
++
|
|
82
|
++ /*** IUnknown methods ***/
|
|
83
|
++ HRESULT (STDMETHODCALLTYPE *QueryInterface)(
|
|
84
|
++ IWeakReference *This,
|
|
85
|
++ REFIID riid,
|
|
86
|
++ void **ppvObject);
|
|
87
|
++
|
|
88
|
++ ULONG (STDMETHODCALLTYPE *AddRef)(
|
|
89
|
++ IWeakReference *This);
|
|
90
|
++
|
|
91
|
++ ULONG (STDMETHODCALLTYPE *Release)(
|
|
92
|
++ IWeakReference *This);
|
|
93
|
++
|
|
94
|
++ /*** IWeakReference methods ***/
|
|
95
|
++ HRESULT (STDMETHODCALLTYPE *Resolve)(
|
|
96
|
++ IWeakReference *This,
|
|
97
|
++ REFIID riid,
|
|
98
|
++ IInspectable **objectReference);
|
|
99
|
++
|
|
100
|
++ END_INTERFACE
|
|
101
|
++} IWeakReferenceVtbl;
|
|
102
|
++
|
|
103
|
++interface IWeakReference {
|
|
104
|
++ CONST_VTBL IWeakReferenceVtbl* lpVtbl;
|
|
105
|
++};
|
|
106
|
++
|
|
107
|
++#ifdef COBJMACROS
|
|
108
|
++#ifndef WIDL_C_INLINE_WRAPPERS
|
|
109
|
++/*** IUnknown methods ***/
|
|
110
|
++#define IWeakReference_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
|
|
111
|
++#define IWeakReference_AddRef(This) (This)->lpVtbl->AddRef(This)
|
|
112
|
++#define IWeakReference_Release(This) (This)->lpVtbl->Release(This)
|
|
113
|
++/*** IWeakReference methods ***/
|
|
114
|
++#define IWeakReference_Resolve(This,riid,objectReference) (This)->lpVtbl->Resolve(This,riid,objectReference)
|
|
115
|
++#else
|
|
116
|
++/*** IUnknown methods ***/
|
|
117
|
++static __WIDL_INLINE HRESULT IWeakReference_QueryInterface(IWeakReference* This,REFIID riid,void **ppvObject) {
|
|
118
|
++ return This->lpVtbl->QueryInterface(This,riid,ppvObject);
|
|
119
|
++}
|
|
120
|
++static __WIDL_INLINE ULONG IWeakReference_AddRef(IWeakReference* This) {
|
|
121
|
++ return This->lpVtbl->AddRef(This);
|
|
122
|
++}
|
|
123
|
++static __WIDL_INLINE ULONG IWeakReference_Release(IWeakReference* This) {
|
|
124
|
++ return This->lpVtbl->Release(This);
|
|
125
|
++}
|
|
126
|
++/*** IWeakReference methods ***/
|
|
127
|
++static __WIDL_INLINE HRESULT IWeakReference_Resolve(IWeakReference* This,REFIID riid,IInspectable **objectReference) {
|
|
128
|
++ return This->lpVtbl->Resolve(This,riid,objectReference);
|
|
129
|
++}
|
|
130
|
++#endif
|
|
131
|
++#endif
|
|
132
|
++
|
|
133
|
++#endif
|
|
134
|
++
|
|
135
|
++
|
|
136
|
++#endif /* __IWeakReference_INTERFACE_DEFINED__ */
|
|
137
|
++
|
|
138
|
++/*****************************************************************************
|
|
139
|
++ * IWeakReferenceSource interface
|
|
140
|
++ */
|
|
141
|
++#ifndef __IWeakReferenceSource_INTERFACE_DEFINED__
|
|
142
|
++#define __IWeakReferenceSource_INTERFACE_DEFINED__
|
|
143
|
++
|
|
144
|
++DEFINE_GUID(IID_IWeakReferenceSource, 0x00000038, 0x0000, 0x0000, 0xc0,0x00, 0x00,0x00,0x00,0x00,0x00,0x46);
|
|
145
|
++#if defined(__cplusplus) && !defined(CINTERFACE)
|
|
146
|
++MIDL_INTERFACE("00000038-0000-0000-c000-000000000046")
|
|
147
|
++IWeakReferenceSource : public IUnknown
|
|
148
|
++{
|
|
149
|
++ virtual HRESULT STDMETHODCALLTYPE GetWeakReference(
|
|
150
|
++ IWeakReference **weakReference) = 0;
|
|
151
|
++
|
|
152
|
++};
|
|
153
|
++#ifdef __CRT_UUID_DECL
|
|
154
|
++__CRT_UUID_DECL(IWeakReferenceSource, 0x00000038, 0x0000, 0x0000, 0xc0,0x00, 0x00,0x00,0x00,0x00,0x00,0x46)
|
|
155
|
++#endif
|
|
156
|
++#else
|
|
157
|
++typedef struct IWeakReferenceSourceVtbl {
|
|
158
|
++ BEGIN_INTERFACE
|
|
159
|
++
|
|
160
|
++ /*** IUnknown methods ***/
|
|
161
|
++ HRESULT (STDMETHODCALLTYPE *QueryInterface)(
|
|
162
|
++ IWeakReferenceSource *This,
|
|
163
|
++ REFIID riid,
|
|
164
|
++ void **ppvObject);
|
|
165
|
++
|
|
166
|
++ ULONG (STDMETHODCALLTYPE *AddRef)(
|
|
167
|
++ IWeakReferenceSource *This);
|
|
168
|
++
|
|
169
|
++ ULONG (STDMETHODCALLTYPE *Release)(
|
|
170
|
++ IWeakReferenceSource *This);
|
|
171
|
++
|
|
172
|
++ /*** IWeakReferenceSource methods ***/
|
|
173
|
++ HRESULT (STDMETHODCALLTYPE *GetWeakReference)(
|
|
174
|
++ IWeakReferenceSource *This,
|
|
175
|
++ IWeakReference **weakReference);
|
|
176
|
++
|
|
177
|
++ END_INTERFACE
|
|
178
|
++} IWeakReferenceSourceVtbl;
|
|
179
|
++
|
|
180
|
++interface IWeakReferenceSource {
|
|
181
|
++ CONST_VTBL IWeakReferenceSourceVtbl* lpVtbl;
|
|
182
|
++};
|
|
183
|
++
|
|
184
|
++#ifdef COBJMACROS
|
|
185
|
++#ifndef WIDL_C_INLINE_WRAPPERS
|
|
186
|
++/*** IUnknown methods ***/
|
|
187
|
++#define IWeakReferenceSource_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
|
|
188
|
++#define IWeakReferenceSource_AddRef(This) (This)->lpVtbl->AddRef(This)
|
|
189
|
++#define IWeakReferenceSource_Release(This) (This)->lpVtbl->Release(This)
|
|
190
|
++/*** IWeakReferenceSource methods ***/
|
|
191
|
++#define IWeakReferenceSource_GetWeakReference(This,weakReference) (This)->lpVtbl->GetWeakReference(This,weakReference)
|
|
192
|
++#else
|
|
193
|
++/*** IUnknown methods ***/
|
|
194
|
++static __WIDL_INLINE HRESULT IWeakReferenceSource_QueryInterface(IWeakReferenceSource* This,REFIID riid,void **ppvObject) {
|
|
195
|
++ return This->lpVtbl->QueryInterface(This,riid,ppvObject);
|
|
196
|
++}
|
|
197
|
++static __WIDL_INLINE ULONG IWeakReferenceSource_AddRef(IWeakReferenceSource* This) {
|
|
198
|
++ return This->lpVtbl->AddRef(This);
|
|
199
|
++}
|
|
200
|
++static __WIDL_INLINE ULONG IWeakReferenceSource_Release(IWeakReferenceSource* This) {
|
|
201
|
++ return This->lpVtbl->Release(This);
|
|
202
|
++}
|
|
203
|
++/*** IWeakReferenceSource methods ***/
|
|
204
|
++static __WIDL_INLINE HRESULT IWeakReferenceSource_GetWeakReference(IWeakReferenceSource* This,IWeakReference **weakReference) {
|
|
205
|
++ return This->lpVtbl->GetWeakReference(This,weakReference);
|
|
206
|
++}
|
|
207
|
++#endif
|
|
208
|
++#endif
|
|
209
|
++
|
|
210
|
++#endif
|
|
211
|
++
|
|
212
|
++
|
|
213
|
++#endif /* __IWeakReferenceSource_INTERFACE_DEFINED__ */
|
|
214
|
++
|
|
215
|
++/* Begin additional prototypes for all interfaces */
|
|
216
|
++
|
|
217
|
++
|
|
218
|
++/* End additional prototypes */
|
|
219
|
++
|
|
220
|
++#ifdef __cplusplus
|
|
221
|
++}
|
|
222
|
++#endif
|
|
223
|
++
|
|
224
|
++#endif /* __weakreference_h__ */
|
|
225
|
+diff --git a/mingw-w64-headers/include/weakreference.idl b/mingw-w64-headers/include/weakreference.idl
|
|
226
|
+new file mode 100644
|
|
227
|
+index 000000000..037fce859
|
|
228
|
+--- /dev/null
|
|
229
|
++++ b/mingw-w64-headers/include/weakreference.idl
|
|
230
|
+@@ -0,0 +1,28 @@
|
|
231
|
++import "inspectable.idl";
|
|
232
|
++
|
|
233
|
++[object, uuid(00000037-0000-0000-C000-000000000046), pointer_default (unique)]
|
|
234
|
++interface IWeakReference: IUnknown
|
|
235
|
++{
|
|
236
|
++// cpp_quote("#if (_MSC_VER >= 1600) && defined(__cplusplus) && !defined(CINTERFACE)")
|
|
237
|
++// cpp_quote(" EXTERN_C const IID IID_IWeakReference;")
|
|
238
|
++// cpp_quote(" extern \"C++\"")
|
|
239
|
++// cpp_quote(" {")
|
|
240
|
++// cpp_quote(" MIDL_INTERFACE(\"00000037-0000-0000-C000-000000000046\")")
|
|
241
|
++// cpp_quote(" IWeakReference : public IUnknown {")
|
|
242
|
++// cpp_quote(" public:")
|
|
243
|
++// cpp_quote(" virtual HRESULT STDMETHODCALLTYPE Resolve(REFIID riid, IInspectable **objectReference) = 0;")
|
|
244
|
++// cpp_quote("")
|
|
245
|
++// cpp_quote(" template <typename T>")
|
|
246
|
++// cpp_quote(" HRESULT Resolve(T** objectReference) {")
|
|
247
|
++// cpp_quote(" return 0;")
|
|
248
|
++// cpp_quote(" }")
|
|
249
|
++// cpp_quote(" };")
|
|
250
|
++// cpp_quote(" } // extern C++")
|
|
251
|
++// cpp_quote("#else")
|
|
252
|
++ HRESULT Resolve([in] REFIID riid, [out, retval, iid_is(riid)] IInspectable **objectReference);
|
|
253
|
++}
|
|
254
|
++
|
|
255
|
++[object, uuid(00000038-0000-0000-C000-000000000046), pointer_default (unique)]
|
|
256
|
++interface IWeakReferenceSource : IUnknown {
|
|
257
|
++ HRESULT GetWeakReference([out, retval] IWeakReference **weakReference);
|
|
258
|
++}
|
|
259
|
+diff --git a/mingw-w64-headers/include/windows.graphics.capture.h b/mingw-w64-headers/include/windows.graphics.capture.h
|
|
260
|
+index 203b0f034..4a0c0b546 100644
|
|
261
|
+--- a/mingw-w64-headers/include/windows.graphics.capture.h
|
|
262
|
++++ b/mingw-w64-headers/include/windows.graphics.capture.h
|
|
263
|
+@@ -902,7 +902,7 @@ namespace ABI {
|
|
264
|
+ {
|
|
265
|
+ virtual HRESULT STDMETHODCALLTYPE Recreate(
|
|
266
|
+ ABI::Windows::Graphics::DirectX::Direct3D11::IDirect3DDevice *device,
|
|
267
|
+- enum DirectXPixelFormat pixel_format,
|
|
268
|
++ enum DirectX::DirectXPixelFormat pixel_format,
|
|
269
|
+ INT32 number_of_buffers,
|
|
270
|
+ struct SizeInt32 size) = 0;
|
|
271
|
+
|
|
272
|
+@@ -1100,7 +1100,7 @@ namespace ABI {
|
|
273
|
+ {
|
|
274
|
+ virtual HRESULT STDMETHODCALLTYPE Create(
|
|
275
|
+ ABI::Windows::Graphics::DirectX::Direct3D11::IDirect3DDevice *device,
|
|
276
|
+- enum DirectXPixelFormat pixel_format,
|
|
277
|
++ enum DirectX::DirectXPixelFormat pixel_format,
|
|
278
|
+ INT32 number_of_buffers,
|
|
279
|
+ struct SizeInt32 size,
|
|
280
|
+ ABI::Windows::Graphics::Capture::IDirect3D11CaptureFramePool **result) = 0;
|
|
281
|
+@@ -1236,7 +1236,7 @@ namespace ABI {
|
|
282
|
+ {
|
|
283
|
+ virtual HRESULT STDMETHODCALLTYPE CreateFreeThreaded(
|
|
284
|
+ ABI::Windows::Graphics::DirectX::Direct3D11::IDirect3DDevice *device,
|
|
285
|
+- enum DirectXPixelFormat pixel_format,
|
|
286
|
++ enum DirectX::DirectXPixelFormat pixel_format,
|
|
287
|
+ INT32 number_of_buffers,
|
|
288
|
+ struct SizeInt32 size,
|
|
289
|
+ ABI::Windows::Graphics::Capture::IDirect3D11CaptureFramePool **result) = 0;
|
|
290
|
+diff --git a/mingw-w64-headers/include/windows.graphics.directx.direct3d11.interop.h b/mingw-w64-headers/include/windows.graphics.directx.direct3d11.interop.h
|
|
291
|
+new file mode 100644
|
|
292
|
+index 000000000..7b66f7d16
|
|
293
|
+--- /dev/null
|
|
294
|
++++ b/mingw-w64-headers/include/windows.graphics.directx.direct3d11.interop.h
|
|
295
|
+@@ -0,0 +1,164 @@
|
|
296
|
++/*** Autogenerated by WIDL 8.0 from include/windows.graphics.directx.direct3d11.interop.idl - Do not edit ***/
|
|
297
|
++
|
|
298
|
++#ifdef _WIN32
|
|
299
|
++#ifndef __REQUIRED_RPCNDR_H_VERSION__
|
|
300
|
++#define __REQUIRED_RPCNDR_H_VERSION__ 475
|
|
301
|
++#endif
|
|
302
|
++#include <rpc.h>
|
|
303
|
++#include <rpcndr.h>
|
|
304
|
++#endif
|
|
305
|
++
|
|
306
|
++#ifndef COM_NO_WINDOWS_H
|
|
307
|
++#include <windows.h>
|
|
308
|
++#include <ole2.h>
|
|
309
|
++#endif
|
|
310
|
++
|
|
311
|
++#ifndef __windows_graphics_directx_direct3d11_interop_h__
|
|
312
|
++#define __windows_graphics_directx_direct3d11_interop_h__
|
|
313
|
++
|
|
314
|
++#ifndef __WIDL_INLINE
|
|
315
|
++#if defined(__cplusplus) || defined(_MSC_VER)
|
|
316
|
++#define __WIDL_INLINE inline
|
|
317
|
++#elif defined(__GNUC__)
|
|
318
|
++#define __WIDL_INLINE __inline__
|
|
319
|
++#endif
|
|
320
|
++#endif
|
|
321
|
++
|
|
322
|
++/* Forward declarations */
|
|
323
|
++
|
|
324
|
++#ifndef ____x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess_FWD_DEFINED__
|
|
325
|
++#define ____x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess_FWD_DEFINED__
|
|
326
|
++typedef interface __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess;
|
|
327
|
++#ifdef __cplusplus
|
|
328
|
++#define __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess ABI::Windows::Graphics::DirectX::Direct3D11::IDirect3DDxgiInterfaceAccess
|
|
329
|
++namespace ABI {
|
|
330
|
++ namespace Windows {
|
|
331
|
++ namespace Graphics {
|
|
332
|
++ namespace DirectX {
|
|
333
|
++ namespace Direct3D11 {
|
|
334
|
++ interface IDirect3DDxgiInterfaceAccess;
|
|
335
|
++ }
|
|
336
|
++ }
|
|
337
|
++ }
|
|
338
|
++ }
|
|
339
|
++}
|
|
340
|
++#endif /* __cplusplus */
|
|
341
|
++#endif
|
|
342
|
++
|
|
343
|
++/* Headers for imported files */
|
|
344
|
++
|
|
345
|
++#include <windows.graphics.directx.direct3d11.h>
|
|
346
|
++
|
|
347
|
++#ifdef __cplusplus
|
|
348
|
++extern "C" {
|
|
349
|
++#endif
|
|
350
|
++
|
|
351
|
++/*****************************************************************************
|
|
352
|
++ * IDirect3DDxgiInterfaceAccess interface
|
|
353
|
++ */
|
|
354
|
++#ifndef ____x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess_INTERFACE_DEFINED__
|
|
355
|
++#define ____x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess_INTERFACE_DEFINED__
|
|
356
|
++
|
|
357
|
++DEFINE_GUID(IID___x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess, 0xa9b3d012, 0x3df2, 0x4ee3, 0xb8,0xd1, 0x86,0x95,0xf4,0x57,0xd3,0xc1);
|
|
358
|
++#if defined(__cplusplus) && !defined(CINTERFACE)
|
|
359
|
++} /* extern "C" */
|
|
360
|
++namespace ABI {
|
|
361
|
++ namespace Windows {
|
|
362
|
++ namespace Graphics {
|
|
363
|
++ namespace DirectX {
|
|
364
|
++ namespace Direct3D11 {
|
|
365
|
++ MIDL_INTERFACE("a9b3d012-3df2-4ee3-b8d1-8695f457d3c1")
|
|
366
|
++ IDirect3DDxgiInterfaceAccess : public IUnknown
|
|
367
|
++ {
|
|
368
|
++ virtual HRESULT STDMETHODCALLTYPE GetInterface(
|
|
369
|
++ REFIID iid,
|
|
370
|
++ void **object) = 0;
|
|
371
|
++
|
|
372
|
++ };
|
|
373
|
++ }
|
|
374
|
++ }
|
|
375
|
++ }
|
|
376
|
++ }
|
|
377
|
++}
|
|
378
|
++extern "C" {
|
|
379
|
++#ifdef __CRT_UUID_DECL
|
|
380
|
++__CRT_UUID_DECL(__x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess, 0xa9b3d012, 0x3df2, 0x4ee3, 0xb8,0xd1, 0x86,0x95,0xf4,0x57,0xd3,0xc1)
|
|
381
|
++#endif
|
|
382
|
++#else
|
|
383
|
++typedef struct __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccessVtbl {
|
|
384
|
++ BEGIN_INTERFACE
|
|
385
|
++
|
|
386
|
++ /*** IUnknown methods ***/
|
|
387
|
++ HRESULT (STDMETHODCALLTYPE *QueryInterface)(
|
|
388
|
++ __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess *This,
|
|
389
|
++ REFIID riid,
|
|
390
|
++ void **ppvObject);
|
|
391
|
++
|
|
392
|
++ ULONG (STDMETHODCALLTYPE *AddRef)(
|
|
393
|
++ __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess *This);
|
|
394
|
++
|
|
395
|
++ ULONG (STDMETHODCALLTYPE *Release)(
|
|
396
|
++ __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess *This);
|
|
397
|
++
|
|
398
|
++ /*** IDirect3DDxgiInterfaceAccess methods ***/
|
|
399
|
++ HRESULT (STDMETHODCALLTYPE *GetInterface)(
|
|
400
|
++ __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess *This,
|
|
401
|
++ REFIID iid,
|
|
402
|
++ void **object);
|
|
403
|
++
|
|
404
|
++ END_INTERFACE
|
|
405
|
++} __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccessVtbl;
|
|
406
|
++
|
|
407
|
++interface __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess {
|
|
408
|
++ CONST_VTBL __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccessVtbl* lpVtbl;
|
|
409
|
++};
|
|
410
|
++
|
|
411
|
++#ifdef COBJMACROS
|
|
412
|
++#ifndef WIDL_C_INLINE_WRAPPERS
|
|
413
|
++/*** IUnknown methods ***/
|
|
414
|
++#define __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
|
|
415
|
++#define __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess_AddRef(This) (This)->lpVtbl->AddRef(This)
|
|
416
|
++#define __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess_Release(This) (This)->lpVtbl->Release(This)
|
|
417
|
++/*** IDirect3DDxgiInterfaceAccess methods ***/
|
|
418
|
++#define __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess_GetInterface(This,iid,object) (This)->lpVtbl->GetInterface(This,iid,object)
|
|
419
|
++#else
|
|
420
|
++/*** IUnknown methods ***/
|
|
421
|
++static __WIDL_INLINE HRESULT __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess_QueryInterface(__x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess* This,REFIID riid,void **ppvObject) {
|
|
422
|
++ return This->lpVtbl->QueryInterface(This,riid,ppvObject);
|
|
423
|
++}
|
|
424
|
++static __WIDL_INLINE ULONG __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess_AddRef(__x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess* This) {
|
|
425
|
++ return This->lpVtbl->AddRef(This);
|
|
426
|
++}
|
|
427
|
++static __WIDL_INLINE ULONG __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess_Release(__x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess* This) {
|
|
428
|
++ return This->lpVtbl->Release(This);
|
|
429
|
++}
|
|
430
|
++/*** IDirect3DDxgiInterfaceAccess methods ***/
|
|
431
|
++static __WIDL_INLINE HRESULT __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess_GetInterface(__x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess* This,REFIID iid,void **object) {
|
|
432
|
++ return This->lpVtbl->GetInterface(This,iid,object);
|
|
433
|
++}
|
|
434
|
++#endif
|
|
435
|
++#ifdef WIDL_using_Windows_Graphics_DirectX_Direct3D11
|
|
436
|
++#define IID_IDirect3DDxgiInterfaceAccess IID___x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess
|
|
437
|
++#define IDirect3DDxgiInterfaceAccessVtbl __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccessVtbl
|
|
438
|
++#define IDirect3DDxgiInterfaceAccess __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess
|
|
439
|
++#define IDirect3DDxgiInterfaceAccess_QueryInterface __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess_QueryInterface
|
|
440
|
++#define IDirect3DDxgiInterfaceAccess_AddRef __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess_AddRef
|
|
441
|
++#define IDirect3DDxgiInterfaceAccess_Release __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess_Release
|
|
442
|
++#define IDirect3DDxgiInterfaceAccess_GetInterface __x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess_GetInterface
|
|
443
|
++#endif /* WIDL_using_Windows_Graphics_DirectX_Direct3D11 */
|
|
444
|
++#endif
|
|
445
|
++
|
|
446
|
++#endif
|
|
447
|
++
|
|
448
|
++#endif /* ____x_ABI_CWindows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDxgiInterfaceAccess_INTERFACE_DEFINED__ */
|
|
449
|
++
|
|
450
|
++/* Begin additional prototypes for all interfaces */
|
|
451
|
++
|
|
452
|
++
|
|
453
|
++/* End additional prototypes */
|
|
454
|
++
|
|
455
|
++#ifdef __cplusplus
|
|
456
|
++}
|
|
457
|
++#endif
|
|
458
|
++
|
|
459
|
++#endif /* __windows_graphics_directx_direct3d11_interop_h__ */
|
|
460
|
+diff --git a/mingw-w64-headers/include/windows.graphics.directx.direct3d11.interop.idl b/mingw-w64-headers/include/windows.graphics.directx.direct3d11.interop.idl
|
|
461
|
+new file mode 100644
|
|
462
|
+index 000000000..51e2845ea
|
|
463
|
+--- /dev/null
|
|
464
|
++++ b/mingw-w64-headers/include/windows.graphics.directx.direct3d11.interop.idl
|
|
465
|
+@@ -0,0 +1,14 @@
|
|
466
|
++#ifdef __WIDL__
|
|
467
|
++#pragma winrt ns_prefix
|
|
468
|
++#endif
|
|
469
|
++
|
|
470
|
++import "windows.graphics.directx.direct3d11.idl";
|
|
471
|
++
|
|
472
|
++namespace Windows.Graphics.DirectX.Direct3D11 {
|
|
473
|
++ [
|
|
474
|
++ uuid(A9B3D012-3DF2-4EE3-B8D1-8695F457D3C1)
|
|
475
|
++ ]
|
|
476
|
++ interface IDirect3DDxgiInterfaceAccess : IUnknown {
|
|
477
|
++ HRESULT GetInterface([in] REFIID iid, [out, iid_is(iid)] void **object);
|
|
478
|
++ };
|
|
479
|
++}
|
|
480
|
+diff --git a/mingw-w64-headers/include/windows.ui.core.h b/mingw-w64-headers/include/windows.ui.core.h
|
|
481
|
+index 5eb820b33..8a2e93ce4 100644
|
|
482
|
+--- a/mingw-w64-headers/include/windows.ui.core.h
|
|
483
|
++++ b/mingw-w64-headers/include/windows.ui.core.h
|
|
484
|
+@@ -1602,7 +1602,7 @@ namespace ABI {
|
|
485
|
+ namespace Core {
|
|
486
|
+ struct CoreProximityEvaluation {
|
|
487
|
+ INT32 Score;
|
|
488
|
+- struct Point AdjustedPoint;
|
|
489
|
++ struct Foundation::Point AdjustedPoint;
|
|
490
|
+ };
|
|
491
|
+ }
|
|
492
|
+ }
|
|
493
|
+@@ -2759,11 +2759,11 @@ namespace ABI {
|
|
494
|
+ ) = 0;
|
|
495
|
+
|
|
496
|
+ virtual HRESULT STDMETHODCALLTYPE GetAsyncKeyState(
|
|
497
|
+- enum VirtualKey key,
|
|
498
|
++ enum System::VirtualKey key,
|
|
499
|
+ enum CoreVirtualKeyStates *state) = 0;
|
|
500
|
+
|
|
501
|
+ virtual HRESULT STDMETHODCALLTYPE GetKeyState(
|
|
502
|
+- enum VirtualKey key,
|
|
503
|
++ enum System::VirtualKey key,
|
|
504
|
+ enum CoreVirtualKeyStates *state) = 0;
|
|
505
|
+
|
|
506
|
+ virtual HRESULT STDMETHODCALLTYPE ReleasePointerCapture(
|
|
507
|
+@@ -3491,7 +3491,7 @@ namespace ABI {
|
|
508
|
+ ICoreWindow2 : public IInspectable
|
|
509
|
+ {
|
|
510
|
+ virtual HRESULT STDMETHODCALLTYPE put_PointerPosition(
|
|
511
|
+- struct Point value) = 0;
|
|
512
|
++ struct Foundation::Point value) = 0;
|
|
513
|
+
|
|
514
|
+ };
|
|
515
|
+ }
|
|
516
|
+@@ -4605,7 +4605,7 @@ namespace ABI {
|
|
517
|
+ IKeyEventArgs : public IInspectable
|
|
518
|
+ {
|
|
519
|
+ virtual HRESULT STDMETHODCALLTYPE get_VirtualKey(
|
|
520
|
+- enum VirtualKey *value) = 0;
|
|
521
|
++ enum System::VirtualKey *value) = 0;
|
|
522
|
+
|
|
523
|
+ virtual HRESULT STDMETHODCALLTYPE get_KeyStatus(
|
|
524
|
+ struct CorePhysicalKeyStatus *value) = 0;
|
|
525
|
+@@ -4876,7 +4876,7 @@ namespace ABI {
|
|
526
|
+ ABI::Windows::UI::Input::IPointerPoint **value) = 0;
|
|
527
|
+
|
|
528
|
+ virtual HRESULT STDMETHODCALLTYPE get_KeyModifiers(
|
|
529
|
+- enum VirtualKeyModifiers *value) = 0;
|
|
530
|
++ enum System::VirtualKeyModifiers *value) = 0;
|
|
531
|
+
|
|
532
|
+ virtual HRESULT STDMETHODCALLTYPE GetIntermediatePoints(
|
|
533
|
+ ABI::Windows::Foundation::Collections::IVector<ABI::Windows::UI::Input::PointerPoint* > **value) = 0;
|
|
534
|
+diff --git a/mingw-w64-headers/include/wrl/client.h b/mingw-w64-headers/include/wrl/client.h
|
|
535
|
+index aeb886ea8..4fcadc7fc 100644
|
|
536
|
+--- a/mingw-w64-headers/include/wrl/client.h
|
|
537
|
++++ b/mingw-w64-headers/include/wrl/client.h
|
|
538
|
+@@ -9,12 +9,15 @@
|
|
539
|
+
|
|
540
|
+ #include <stddef.h>
|
|
541
|
+ #include <unknwn.h>
|
|
542
|
+-/* #include <weakreference.h> */
|
|
543
|
++#include <weakreference.h>
|
|
544
|
+ #include <roapi.h>
|
|
545
|
+
|
|
546
|
+ /* #include <wrl/def.h> */
|
|
547
|
+ #include <wrl/internal.h>
|
|
548
|
+
|
|
549
|
++#define WrlFinal final
|
|
550
|
++#define WrlSealed sealed
|
|
551
|
++
|
|
552
|
+ namespace Microsoft {
|
|
553
|
+ namespace WRL {
|
|
554
|
+ namespace Details {
|
|
555
|
+diff --git a/mingw-w64-headers/include/wrl/event.h b/mingw-w64-headers/include/wrl/event.h
|
|
556
|
+new file mode 100644
|
|
557
|
+index 000000000..2e883e241
|
|
558
|
+--- /dev/null
|
|
559
|
++++ b/mingw-w64-headers/include/wrl/event.h
|
|
560
|
+@@ -0,0 +1,368 @@
|
|
561
|
++#ifndef _WRL_EVENT_H_
|
|
562
|
++#define _WRL_EVENT_H_
|
|
563
|
++
|
|
564
|
++// #include <wrl/def.h>
|
|
565
|
++#include <wrl/internal.h>
|
|
566
|
++#include <wrl/client.h>
|
|
567
|
++#include <wrl/implements.h>
|
|
568
|
++#include <wrl/wrappers/corewrappers.h>
|
|
569
|
++#include <eventtoken.h>
|
|
570
|
++// #include <roerrorapi.h>
|
|
571
|
++
|
|
572
|
++#include <pshpack8.h>
|
|
573
|
++
|
|
574
|
++namespace Microsoft {
|
|
575
|
++ namespace WRL {
|
|
576
|
++ enum DelegateCheckMode {
|
|
577
|
++ NoCheck = 1
|
|
578
|
++ };
|
|
579
|
++
|
|
580
|
++ template<DelegateCheckMode delegateCheckMode> struct DelegateTraits;
|
|
581
|
++
|
|
582
|
++ template<> struct DelegateTraits<NoCheck> {
|
|
583
|
++ static HRESULT CheckReturn(HRESULT hr) {
|
|
584
|
++ return 0;
|
|
585
|
++ }
|
|
586
|
++ };
|
|
587
|
++
|
|
588
|
++ extern __declspec(selectany) const DelegateCheckMode DefaultDelegateCheckMode = NoCheck;
|
|
589
|
++
|
|
590
|
++ enum InvokeMode {
|
|
591
|
++ StopOnFirstError = 1,
|
|
592
|
++ FireAll = 2,
|
|
593
|
++ };
|
|
594
|
++
|
|
595
|
++ template<InvokeMode invokeModeValue> struct InvokeModeOptions {
|
|
596
|
++ static const InvokeMode invokeMode = invokeModeValue;
|
|
597
|
++ };
|
|
598
|
++
|
|
599
|
++ template<InvokeMode invokeMode> struct InvokeTraits;
|
|
600
|
++
|
|
601
|
++ template<typename TDelegateInterface, typename EventSourceOptions>
|
|
602
|
++ class EventSource;
|
|
603
|
++
|
|
604
|
++ namespace Details {
|
|
605
|
++ template<typename TDelegateInterface>
|
|
606
|
++ void* GetDelegateBucketAssist(TDelegateInterface *pDelegate) {
|
|
607
|
++ return nullptr;
|
|
608
|
++ }
|
|
609
|
++
|
|
610
|
++ template<typename TMemberFunction> struct ArgTraits {
|
|
611
|
++ static const int args = -1;
|
|
612
|
++ };
|
|
613
|
++
|
|
614
|
++ template<typename TDelegateInterface>
|
|
615
|
++ struct ArgTraits<HRESULT(STDMETHODCALLTYPE TDelegateInterface::*)(void)> {
|
|
616
|
++ static const int args = 0;
|
|
617
|
++ };
|
|
618
|
++
|
|
619
|
++ template<typename TDelegateInterface, typename TArg1>
|
|
620
|
++ struct ArgTraits<HRESULT(STDMETHODCALLTYPE TDelegateInterface::*)(TArg1)> {
|
|
621
|
++ static const int args = 1;
|
|
622
|
++ typedef TArg1 Arg1Type;
|
|
623
|
++ };
|
|
624
|
++
|
|
625
|
++ template<typename TDelegateInterface, typename TArg1, typename TArg2>
|
|
626
|
++ struct ArgTraits<HRESULT(STDMETHODCALLTYPE TDelegateInterface::*)(TArg1, TArg2)>
|
|
627
|
++ {
|
|
628
|
++ static const int args = 2;
|
|
629
|
++ typedef TArg1 Arg1Type;
|
|
630
|
++ typedef TArg2 Arg2Type;
|
|
631
|
++ };
|
|
632
|
++
|
|
633
|
++ template<typename TDelegateInterface, typename TArg1, typename TArg2, typename TArg3>
|
|
634
|
++ struct ArgTraits<HRESULT(STDMETHODCALLTYPE TDelegateInterface::*)(TArg1, TArg2, TArg3)>
|
|
635
|
++ {
|
|
636
|
++ static const int args = 3;
|
|
637
|
++ typedef TArg1 Arg1Type;
|
|
638
|
++ typedef TArg2 Arg2Type;
|
|
639
|
++ typedef TArg3 Arg3Type;
|
|
640
|
++ };
|
|
641
|
++
|
|
642
|
++ template<typename TDelegateInterface, typename TArg1, typename TArg2, typename TArg3, typename TArg4>
|
|
643
|
++ struct ArgTraits<HRESULT(STDMETHODCALLTYPE TDelegateInterface::*)(TArg1, TArg2, TArg3, TArg4)>
|
|
644
|
++ {
|
|
645
|
++ static const int args = 4;
|
|
646
|
++ typedef TArg1 Arg1Type;
|
|
647
|
++ typedef TArg2 Arg2Type;
|
|
648
|
++ typedef TArg3 Arg3Type;
|
|
649
|
++ typedef TArg4 Arg4Type;
|
|
650
|
++ };
|
|
651
|
++
|
|
652
|
++ template<typename TDelegateInterface, typename TArg1, typename TArg2, typename TArg3, typename TArg4, typename TArg5>
|
|
653
|
++ struct ArgTraits<HRESULT(STDMETHODCALLTYPE TDelegateInterface::*)(TArg1, TArg2, TArg3, TArg4, TArg5)>
|
|
654
|
++ {
|
|
655
|
++ static const int args = 5;
|
|
656
|
++ typedef TArg1 Arg1Type;
|
|
657
|
++ typedef TArg2 Arg2Type;
|
|
658
|
++ typedef TArg3 Arg3Type;
|
|
659
|
++ typedef TArg4 Arg4Type;
|
|
660
|
++ typedef TArg5 Arg5Type;
|
|
661
|
++ };
|
|
662
|
++
|
|
663
|
++ template<typename TDelegateInterface, typename TArg1, typename TArg2, typename TArg3, typename TArg4, typename TArg5, typename TArg6>
|
|
664
|
++ struct ArgTraits<HRESULT(STDMETHODCALLTYPE TDelegateInterface::*)(TArg1, TArg2, TArg3, TArg4, TArg5, TArg6)>
|
|
665
|
++ {
|
|
666
|
++ static const int args = 6;
|
|
667
|
++ typedef TArg1 Arg1Type;
|
|
668
|
++ typedef TArg2 Arg2Type;
|
|
669
|
++ typedef TArg3 Arg3Type;
|
|
670
|
++ typedef TArg4 Arg4Type;
|
|
671
|
++ typedef TArg5 Arg5Type;
|
|
672
|
++ typedef TArg6 Arg6Type;
|
|
673
|
++ };
|
|
674
|
++
|
|
675
|
++ template<typename TDelegateInterface, typename TArg1, typename TArg2, typename TArg3, typename TArg4, typename TArg5, typename TArg6, typename TArg7>
|
|
676
|
++ struct ArgTraits<HRESULT(STDMETHODCALLTYPE TDelegateInterface::*)(TArg1, TArg2, TArg3, TArg4, TArg5, TArg6, TArg7)>
|
|
677
|
++ {
|
|
678
|
++ static const int args = 7;
|
|
679
|
++ typedef TArg1 Arg1Type;
|
|
680
|
++ typedef TArg2 Arg2Type;
|
|
681
|
++ typedef TArg3 Arg3Type;
|
|
682
|
++ typedef TArg4 Arg4Type;
|
|
683
|
++ typedef TArg5 Arg5Type;
|
|
684
|
++ typedef TArg6 Arg6Type;
|
|
685
|
++ typedef TArg7 Arg7Type;
|
|
686
|
++ };
|
|
687
|
++
|
|
688
|
++ template<typename TDelegateInterface, typename TArg1, typename TArg2, typename TArg3, typename TArg4, typename TArg5, typename TArg6, typename TArg7, typename TArg8>
|
|
689
|
++ struct ArgTraits<HRESULT(STDMETHODCALLTYPE TDelegateInterface::*)(TArg1, TArg2, TArg3, TArg4, TArg5, TArg6, TArg7, TArg8)>
|
|
690
|
++ {
|
|
691
|
++ static const int args = 8;
|
|
692
|
++ typedef TArg1 Arg1Type;
|
|
693
|
++ typedef TArg2 Arg2Type;
|
|
694
|
++ typedef TArg3 Arg3Type;
|
|
695
|
++ typedef TArg4 Arg4Type;
|
|
696
|
++ typedef TArg5 Arg5Type;
|
|
697
|
++ typedef TArg6 Arg6Type;
|
|
698
|
++ typedef TArg7 Arg7Type;
|
|
699
|
++ typedef TArg8 Arg8Type;
|
|
700
|
++ };
|
|
701
|
++
|
|
702
|
++ template<typename TDelegateInterface, typename TArg1, typename TArg2, typename TArg3, typename TArg4, typename TArg5, typename TArg6, typename TArg7, typename TArg8, typename TArg9>
|
|
703
|
++ struct ArgTraits<HRESULT(STDMETHODCALLTYPE TDelegateInterface::*)(TArg1, TArg2, TArg3, TArg4, TArg5, TArg6, TArg7, TArg8, TArg9)>
|
|
704
|
++ {
|
|
705
|
++ static const int args = 9;
|
|
706
|
++ typedef TArg1 Arg1Type;
|
|
707
|
++ typedef TArg2 Arg2Type;
|
|
708
|
++ typedef TArg3 Arg3Type;
|
|
709
|
++ typedef TArg4 Arg4Type;
|
|
710
|
++ typedef TArg5 Arg5Type;
|
|
711
|
++ typedef TArg6 Arg6Type;
|
|
712
|
++ typedef TArg7 Arg7Type;
|
|
713
|
++ typedef TArg8 Arg8Type;
|
|
714
|
++ typedef TArg9 Arg9Type;
|
|
715
|
++ };
|
|
716
|
++
|
|
717
|
++ template<typename TDelegateInterface, bool isImplements = __is_base_of(ImplementsBase, TDelegateInterface)>
|
|
718
|
++ struct ArgTraitsHelper;
|
|
719
|
++
|
|
720
|
++ template<typename TDelegateInterface>
|
|
721
|
++ struct ArgTraitsHelper<TDelegateInterface, false>
|
|
722
|
++ {
|
|
723
|
++ typedef decltype(&TDelegateInterface::Invoke) methodType;
|
|
724
|
++ typedef ArgTraits<methodType> Traits;
|
|
725
|
++ static const int args = Traits::args;
|
|
726
|
++ typedef TDelegateInterface Interface;
|
|
727
|
++ };
|
|
728
|
++
|
|
729
|
++ template<typename TDelegateInterface>
|
|
730
|
++ struct ArgTraitsHelper<TDelegateInterface, true> {};
|
|
731
|
++
|
|
732
|
++ template<typename TDelegateInterface> class DelegateArgTraits {};
|
|
733
|
++
|
|
734
|
++ template<typename TDelegateInterface, typename ...TArgs>
|
|
735
|
++ class DelegateArgTraits<HRESULT (STDMETHODCALLTYPE TDelegateInterface::*)(TArgs...)>
|
|
736
|
++ {
|
|
737
|
++ template<typename TCallback, DelegateCheckMode checkMode>
|
|
738
|
++ struct DelegateInvokeHelper WrlSealed : public ::Microsoft::WRL::RuntimeClass<RuntimeClassFlags<Delegate>, TDelegateInterface>, RemoveReference<TCallback>::Type {
|
|
739
|
++ DelegateInvokeHelper(TCallback&& callback) noexcept {}
|
|
740
|
++
|
|
741
|
++ HRESULT STDMETHODCALLTYPE Invoke(TArgs... args) noexcept override {
|
|
742
|
++ return 0;
|
|
743
|
++ }
|
|
744
|
++ };
|
|
745
|
++
|
|
746
|
++ public:
|
|
747
|
++ template<typename TImplements, DelegateCheckMode checkMode = DefaultDelegateCheckMode, typename TLambda>
|
|
748
|
++ static ComPtr<TImplements> Callback(TLambda&& callback) noexcept {
|
|
749
|
++ ComPtr<TImplements> empty;
|
|
750
|
++ return empty;
|
|
751
|
++ }
|
|
752
|
++ };
|
|
753
|
++
|
|
754
|
++ template<typename TDelegateInterface, bool isImplements = __is_base_of(ImplementsBase, TDelegateInterface)>
|
|
755
|
++ struct DelegateArgTraitsHelper;
|
|
756
|
++
|
|
757
|
++ template<typename TDelegateInterface>
|
|
758
|
++ struct DelegateArgTraitsHelper<TDelegateInterface, false> {
|
|
759
|
++ typedef TDelegateInterface Interface;
|
|
760
|
++ typedef DelegateArgTraits<decltype(&TDelegateInterface::Invoke)> Traits;
|
|
761
|
++ };
|
|
762
|
++
|
|
763
|
++ template<typename TDelegateInterface>
|
|
764
|
++ struct DelegateArgTraitsHelper<TDelegateInterface, true> {};
|
|
765
|
++
|
|
766
|
++ template<typename TDelegateInterface>
|
|
767
|
++ HRESULT CreateAgileHelper(TDelegateInterface* delegateInterface, TDelegateInterface** wrapper) {
|
|
768
|
++ return 0;
|
|
769
|
++ }
|
|
770
|
++ }
|
|
771
|
++
|
|
772
|
++ template<typename TDelegateInterface, typename TLambda>
|
|
773
|
++ ComPtr<typename Details::DelegateArgTraitsHelper<TDelegateInterface>::Interface> Callback(TLambda&& callback) noexcept {
|
|
774
|
++ return 0;
|
|
775
|
++ }
|
|
776
|
++
|
|
777
|
++ template<typename TDelegateInterface, typename TFunc>
|
|
778
|
++ ComPtr<typename Details::DelegateArgTraitsHelper<TDelegateInterface>::Interface> Callback(TFunc* callback) noexcept {
|
|
779
|
++ return 0;
|
|
780
|
++ };
|
|
781
|
++
|
|
782
|
++ template<typename TDelegateInterface, typename TCallbackObject, typename... TArgs>
|
|
783
|
++ ComPtr<typename Details::DelegateArgTraitsHelper<TDelegateInterface>::Interface> Callback(TCallbackObject *object, HRESULT(TCallbackObject::* method)(TArgs...)) noexcept {
|
|
784
|
++ return 0;
|
|
785
|
++ }
|
|
786
|
++
|
|
787
|
++ template<typename TDelegateInterface>
|
|
788
|
++ HRESULT WeakReferenceCallback(IWeakReferenceSource* innerCallback, TDelegateInterface** callback) {
|
|
789
|
++ return 0;
|
|
790
|
++ }
|
|
791
|
++
|
|
792
|
++ template<typename TDelegateInterface>
|
|
793
|
++ HRESULT WeakReferenceCallback(TDelegateInterface* innerCallback, TDelegateInterface** callback) {
|
|
794
|
++ return 0;
|
|
795
|
++ }
|
|
796
|
++
|
|
797
|
++ template<typename T, typename TDelegateInterface, typename ...TArgs>
|
|
798
|
++ HRESULT WeakReferenceCallback(T* targetObject, HRESULT (T::*targetMethod)(TArgs... args), TDelegateInterface** callback) {
|
|
799
|
++ return 0;
|
|
800
|
++ }
|
|
801
|
++
|
|
802
|
++ template<typename T, typename TDelegateInterface, typename ...TArgs>
|
|
803
|
++ HRESULT WeakReferenceCallback(T* targetObject, HRESULT(T::*targetMethod)(TArgs... args), ::Microsoft::WRL::Details::ComPtrRef< ::Microsoft::WRL::ComPtr<TDelegateInterface>> callback) {
|
|
804
|
++ return 0;
|
|
805
|
++ }
|
|
806
|
++
|
|
807
|
++ namespace Details {
|
|
808
|
++
|
|
809
|
++ class EventTargetArray WrlSealed : public ::Microsoft::WRL::RuntimeClass< ::Microsoft::WRL::RuntimeClassFlags<ClassicCom>, IUnknown > {
|
|
810
|
++ public:
|
|
811
|
++ EventTargetArray() noexcept {}
|
|
812
|
++
|
|
813
|
++ HRESULT RuntimeClassInitialize(size_t items) noexcept {
|
|
814
|
++ return 0;
|
|
815
|
++ }
|
|
816
|
++
|
|
817
|
++ ~EventTargetArray() noexcept
|
|
818
|
++ {
|
|
819
|
++ delete[] begin_;
|
|
820
|
++ delete[] bucketAssists_;
|
|
821
|
++ }
|
|
822
|
++
|
|
823
|
++ ComPtr<IUnknown>* Begin() noexcept {
|
|
824
|
++ return nullptr;
|
|
825
|
++ }
|
|
826
|
++
|
|
827
|
++ ComPtr<IUnknown>* End() noexcept {
|
|
828
|
++ return nullptr;
|
|
829
|
++ }
|
|
830
|
++
|
|
831
|
++ void AddTail(IUnknown* element) noexcept {
|
|
832
|
++ }
|
|
833
|
++
|
|
834
|
++ void AddTail(IUnknown* element, void *bucketAssist) noexcept {
|
|
835
|
++ }
|
|
836
|
++
|
|
837
|
++ size_t Length() noexcept {
|
|
838
|
++ return 0;
|
|
839
|
++ }
|
|
840
|
++
|
|
841
|
++ void **Begin_BucketAssists() {
|
|
842
|
++ return nullptr;
|
|
843
|
++ }
|
|
844
|
++
|
|
845
|
++ void **End_BucketAssists() {
|
|
846
|
++ return nullptr;
|
|
847
|
++ }
|
|
848
|
++
|
|
849
|
++ private:
|
|
850
|
++ ComPtr<IUnknown>* begin_;
|
|
851
|
++
|
|
852
|
++ ComPtr<IUnknown>* end_;
|
|
853
|
++
|
|
854
|
++ void **bucketAssists_;
|
|
855
|
++ };
|
|
856
|
++ }
|
|
857
|
++
|
|
858
|
++ template<>
|
|
859
|
++ struct InvokeTraits<FireAll>
|
|
860
|
++ {
|
|
861
|
++ template<typename TInvokeMethod, typename TDelegateInterface>
|
|
862
|
++ static HRESULT InvokeDelegates(TInvokeMethod invokeOne, Details::EventTargetArray *targetArray, EventSource<TDelegateInterface, InvokeModeOptions<FireAll>>* pEvent) {
|
|
863
|
++ return 0;
|
|
864
|
++ }
|
|
865
|
++ };
|
|
866
|
++
|
|
867
|
++ template<>
|
|
868
|
++ struct InvokeTraits<StopOnFirstError>
|
|
869
|
++ {
|
|
870
|
++ template<typename TInvokeMethod, typename TDelegateInterface>
|
|
871
|
++ static HRESULT InvokeDelegates(TInvokeMethod invokeOne, Details::EventTargetArray *targetArray, EventSource<TDelegateInterface, InvokeModeOptions<StopOnFirstError>>* pEvent) {
|
|
872
|
++ return 0;
|
|
873
|
++ }
|
|
874
|
++ };
|
|
875
|
++
|
|
876
|
++ template<typename TDelegateInterface, typename TEventSourceOptions>
|
|
877
|
++ class EventSource {
|
|
878
|
++ public:
|
|
879
|
++ EventSource() noexcept {}
|
|
880
|
++
|
|
881
|
++ HRESULT Add(TDelegateInterface* delegateInterface, EventRegistrationToken* token) noexcept {
|
|
882
|
++ return 0;
|
|
883
|
++ }
|
|
884
|
++
|
|
885
|
++ HRESULT Remove(EventRegistrationToken token) noexcept {
|
|
886
|
++ return 0;
|
|
887
|
++ }
|
|
888
|
++
|
|
889
|
++ protected:
|
|
890
|
++
|
|
891
|
++ HRESULT Add(TDelegateInterface* delegateInterface, void *bucketAssist, EventRegistrationToken* token) noexcept {
|
|
892
|
++ return 0;
|
|
893
|
++ }
|
|
894
|
++
|
|
895
|
++ private:
|
|
896
|
++
|
|
897
|
++ HRESULT AddInternal(TDelegateInterface* delegateInterface, void *bucketAssist, EventRegistrationToken* token) noexcept {
|
|
898
|
++ return 0;
|
|
899
|
++ }
|
|
900
|
++
|
|
901
|
++ template <typename TInvokeMethod>
|
|
902
|
++ HRESULT DoInvoke(TInvokeMethod invokeOne) noexcept {
|
|
903
|
++ return 0;
|
|
904
|
++ }
|
|
905
|
++
|
|
906
|
++ public:
|
|
907
|
++ template<typename ...TArgs>
|
|
908
|
++ HRESULT InvokeAll(TArgs... args) noexcept {
|
|
909
|
++ return 0;
|
|
910
|
++ }
|
|
911
|
++
|
|
912
|
++ size_t GetSize() const noexcept {
|
|
913
|
++ return 0;
|
|
914
|
++ }
|
|
915
|
++
|
|
916
|
++ protected:
|
|
917
|
++ ComPtr<Details::EventTargetArray> targets_;
|
|
918
|
++
|
|
919
|
++ mutable Wrappers::SRWLock targetsPointerLock_;
|
|
920
|
++
|
|
921
|
++ Wrappers::SRWLock addRemoveLock_;
|
|
922
|
++ };
|
|
923
|
++ }
|
|
924
|
++}
|
|
925
|
++
|
|
926
|
++#include <poppack.h>
|
|
927
|
++
|
|
928
|
++#endif
|
|
929
|
+diff --git a/mingw-w64-headers/include/wrl/implements.h b/mingw-w64-headers/include/wrl/implements.h
|
|
930
|
+new file mode 100644
|
|
931
|
+index 000000000..9d5fe962f
|
|
932
|
+--- /dev/null
|
|
933
|
++++ b/mingw-w64-headers/include/wrl/implements.h
|
|
934
|
+@@ -0,0 +1,619 @@
|
|
935
|
++#ifndef _WRL_IMPLEMENTS_H_
|
|
936
|
++#define _WRL_IMPLEMENTS_H_
|
|
937
|
++
|
|
938
|
++#include <weakreference.h>
|
|
939
|
++
|
|
940
|
++#include <wrl\client.h>
|
|
941
|
++
|
|
942
|
++#include <pshpack8.h>
|
|
943
|
++
|
|
944
|
++
|
|
945
|
++namespace Microsoft {
|
|
946
|
++ namespace WRL {
|
|
947
|
++ template<typename T>
|
|
948
|
++ struct CloakedIid : T {};
|
|
949
|
++
|
|
950
|
++ enum RuntimeClassType {
|
|
951
|
++ WinRt = 0x0001,
|
|
952
|
++ ClassicCom = 0x0002,
|
|
953
|
++ WinRtClassicComMix = WinRt | ClassicCom,
|
|
954
|
++ InhibitWeakReference = 0x0004,
|
|
955
|
++ Delegate = ClassicCom,
|
|
956
|
++ InhibitFtmBase = 0x0008,
|
|
957
|
++ InhibitRoOriginateError = 0x0010
|
|
958
|
++ };
|
|
959
|
++
|
|
960
|
++ template <unsigned int flags>
|
|
961
|
++ struct RuntimeClassFlags {
|
|
962
|
++ static const unsigned int value = flags;
|
|
963
|
++ };
|
|
964
|
++
|
|
965
|
++ namespace Details {
|
|
966
|
++ struct ImplementsBase {};
|
|
967
|
++ }
|
|
968
|
++
|
|
969
|
++ template<typename Derived, typename MixInType, bool hasImplements>
|
|
970
|
++ struct MixIn {};
|
|
971
|
++
|
|
972
|
++ template <typename FactoryInterface>
|
|
973
|
++ class ComposableBase {};
|
|
974
|
++
|
|
975
|
++ typedef RuntimeClassFlags<WinRt | InhibitWeakReference> InhibitWeakReferencePolicy;
|
|
976
|
++
|
|
977
|
++ namespace Details {
|
|
978
|
++
|
|
979
|
++ class Nil {};
|
|
980
|
++
|
|
981
|
++ class DontUseNewUseMake {
|
|
982
|
++ private:
|
|
983
|
++ void* operator new(size_t) throw() {
|
|
984
|
++ return nullptr;
|
|
985
|
++ }
|
|
986
|
++
|
|
987
|
++ public:
|
|
988
|
++ void* operator new(size_t, void* placement) throw() {
|
|
989
|
++ return nullptr;
|
|
990
|
++ }
|
|
991
|
++ };
|
|
992
|
++
|
|
993
|
++ class RuntimeClassBase {};
|
|
994
|
++
|
|
995
|
++ template <unsigned int RuntimeClassTypeT>
|
|
996
|
++ class RuntimeClassBaseT : private RuntimeClassBase {
|
|
997
|
++ protected:
|
|
998
|
++ template<typename T>
|
|
999
|
++ static HRESULT AsIID(T* implements, REFIID riid, void **ppvObject) throw() {
|
|
1000
|
++ return 0;
|
|
1001
|
++ }
|
|
1002
|
++
|
|
1003
|
++ template<typename T>
|
|
1004
|
++ static HRESULT GetImplementedIIDS(T* implements, ULONG *iidCount, IID **iids) throw() {
|
|
1005
|
++ return 0;
|
|
1006
|
++ }
|
|
1007
|
++
|
|
1008
|
++ public:
|
|
1009
|
++ HRESULT RuntimeClassInitialize() throw() {
|
|
1010
|
++ return 0;
|
|
1011
|
++ }
|
|
1012
|
++ };
|
|
1013
|
++
|
|
1014
|
++ class FtmBaseMarker {};
|
|
1015
|
++
|
|
1016
|
++ template <typename I, typename Base>
|
|
1017
|
++ struct VerifyInheritanceHelper {
|
|
1018
|
++ static void Verify() throw() {}
|
|
1019
|
++ };
|
|
1020
|
++
|
|
1021
|
++ template <typename I>
|
|
1022
|
++ struct VerifyInheritanceHelper<I, Nil> {
|
|
1023
|
++ static void Verify() throw() {}
|
|
1024
|
++ };
|
|
1025
|
++ }
|
|
1026
|
++
|
|
1027
|
++ template <typename I0, typename I1, typename I2 = Details::Nil, typename I3 = Details::Nil,
|
|
1028
|
++ typename I4 = Details::Nil, typename I5 = Details::Nil, typename I6 = Details::Nil,
|
|
1029
|
++ typename I7 = Details::Nil, typename I8 = Details::Nil, typename I9 = Details::Nil>
|
|
1030
|
++ struct ChainInterfaces : I0
|
|
1031
|
++ {
|
|
1032
|
++ protected:
|
|
1033
|
++ template<unsigned int ClassType>
|
|
1034
|
++ static void Verify() throw() {}
|
|
1035
|
++
|
|
1036
|
++ HRESULT CanCastTo(REFIID riid, void **ppv) throw() {
|
|
1037
|
++ return 0;
|
|
1038
|
++ }
|
|
1039
|
++
|
|
1040
|
++ IUnknown* CastToUnknown() throw() {
|
|
1041
|
++ return nullptr;
|
|
1042
|
++ }
|
|
1043
|
++
|
|
1044
|
++ static const unsigned long IidCount;
|
|
1045
|
++
|
|
1046
|
++ static void FillArrayWithIid(unsigned long *index, IID* iids) throw() {}
|
|
1047
|
++ };
|
|
1048
|
++
|
|
1049
|
++ template <typename DerivedType, typename BaseType, bool hasImplements, typename I1, typename I2, typename I3,
|
|
1050
|
++ typename I4, typename I5, typename I6,
|
|
1051
|
++ typename I7, typename I8, typename I9>
|
|
1052
|
++ struct ChainInterfaces<MixIn<DerivedType, BaseType, hasImplements>, I1, I2, I3, I4, I5, I6, I7, I8, I9>
|
|
1053
|
++ {
|
|
1054
|
++ protected:
|
|
1055
|
++ template<unsigned int ClassType>
|
|
1056
|
++ static void Verify() throw() {}
|
|
1057
|
++
|
|
1058
|
++ HRESULT CanCastTo(REFIID riid, void **ppv) throw() {
|
|
1059
|
++ return 0;
|
|
1060
|
++ }
|
|
1061
|
++
|
|
1062
|
++ IUnknown* CastToUnknown() throw() {
|
|
1063
|
++ return nullptr;
|
|
1064
|
++ }
|
|
1065
|
++
|
|
1066
|
++ static const unsigned long IidCount;
|
|
1067
|
++
|
|
1068
|
++ static void FillArrayWithIid(unsigned long *index, IID* iids) throw() {}
|
|
1069
|
++ };
|
|
1070
|
++
|
|
1071
|
++ namespace Details {
|
|
1072
|
++ template <typename RuntimeClassFlagsT, bool doStrictCheck, typename ...TInterfaces>
|
|
1073
|
++ struct __declspec(novtable) ImplementsHelper;
|
|
1074
|
++
|
|
1075
|
++ template <typename RuntimeClassFlagsT, bool doStrictCheck, typename I0, typename ...TInterfaces>
|
|
1076
|
++ struct __declspec(novtable) ImplementsHelper<RuntimeClassFlagsT, doStrictCheck, I0, TInterfaces...> : I0, ImplementsHelper<RuntimeClassFlagsT, true, TInterfaces...> {
|
|
1077
|
++ protected:
|
|
1078
|
++ template <unsigned int RuntimeClassTypeT> friend class Details::RuntimeClassBaseT;
|
|
1079
|
++
|
|
1080
|
++ template <bool IsDelegateToClass>
|
|
1081
|
++ HRESULT CanCastToHelper(REFIID riid, void **ppv, bool *pRefDelegated) throw();
|
|
1082
|
++
|
|
1083
|
++ template <>
|
|
1084
|
++ HRESULT inline CanCastToHelper<true>(REFIID riid, void **ppv, bool *pRefDelegated) throw() {
|
|
1085
|
++ return 0;
|
|
1086
|
++ }
|
|
1087
|
++
|
|
1088
|
++ template <>
|
|
1089
|
++ HRESULT inline CanCastToHelper<false>(REFIID riid, void **ppv, bool *pRefDelegated) throw() {
|
|
1090
|
++ return 0;
|
|
1091
|
++ }
|
|
1092
|
++
|
|
1093
|
++ HRESULT CanCastTo(REFIID riid, void **ppv, bool *pRefDelegated) throw() {
|
|
1094
|
++ return 0;
|
|
1095
|
++ }
|
|
1096
|
++
|
|
1097
|
++ template <bool IsDelegateToClass> IUnknown* CastToUnknownHelper() throw();
|
|
1098
|
++
|
|
1099
|
++ template <> inline IUnknown* CastToUnknownHelper<true>() throw() {
|
|
1100
|
++ return nullptr;
|
|
1101
|
++ }
|
|
1102
|
++
|
|
1103
|
++ template <> inline IUnknown* CastToUnknownHelper<false>() throw() {
|
|
1104
|
++ return nullptr;
|
|
1105
|
++ }
|
|
1106
|
++
|
|
1107
|
++ IUnknown* CastToUnknown() throw() {
|
|
1108
|
++ return nullptr;
|
|
1109
|
++ }
|
|
1110
|
++
|
|
1111
|
++ template <bool IsDelegateToClass> long GetIidCountHelper() throw();
|
|
1112
|
++
|
|
1113
|
++ template <> inline long GetIidCountHelper<true>() throw() {
|
|
1114
|
++ return 0;
|
|
1115
|
++ }
|
|
1116
|
++
|
|
1117
|
++ template <> inline long GetIidCountHelper<false>() throw() {
|
|
1118
|
++ return 0;
|
|
1119
|
++ }
|
|
1120
|
++
|
|
1121
|
++ unsigned long GetIidCount() throw() {
|
|
1122
|
++ return 0;
|
|
1123
|
++ }
|
|
1124
|
++
|
|
1125
|
++ template <bool IsDelegateToClass> void FillArrayWithIidHelper(unsigned long *index, IID* iids) throw();
|
|
1126
|
++
|
|
1127
|
++ template <> inline void FillArrayWithIidHelper<true>(unsigned long *index, IID* iids) throw() {}
|
|
1128
|
++
|
|
1129
|
++ template <> inline void FillArrayWithIidHelper<false>(unsigned long *index, IID* iids) throw() {}
|
|
1130
|
++
|
|
1131
|
++ void FillArrayWithIid(unsigned long *index, IID* iids) throw() {}
|
|
1132
|
++ };
|
|
1133
|
++
|
|
1134
|
++ template <typename RuntimeClassFlagsT, bool doStrictCheck, typename ...TInterfaces>
|
|
1135
|
++ struct __declspec(novtable) ImplementsHelper<RuntimeClassFlagsT, doStrictCheck, Details::Nil, TInterfaces...> : ImplementsHelper<RuntimeClassFlagsT, doStrictCheck, TInterfaces...> {
|
|
1136
|
++ protected:
|
|
1137
|
++ template <unsigned int RuntimeClassTypeT> friend class Details::RuntimeClassBaseT;
|
|
1138
|
++
|
|
1139
|
++ HRESULT CanCastTo(REFIID riid, void **ppv, bool * pRefDelegated) throw() {
|
|
1140
|
++ return 0;
|
|
1141
|
++ }
|
|
1142
|
++
|
|
1143
|
++ unsigned long GetIidCount() throw() {
|
|
1144
|
++ return 0;
|
|
1145
|
++ }
|
|
1146
|
++
|
|
1147
|
++ void FillArrayWithIid(unsigned long *index, IID* iids) throw() {}
|
|
1148
|
++ };
|
|
1149
|
++
|
|
1150
|
++ template <typename RuntimeClassFlagsT, bool doStrictCheck>
|
|
1151
|
++ struct __declspec(novtable) ImplementsHelper<RuntimeClassFlagsT, doStrictCheck>
|
|
1152
|
++ {
|
|
1153
|
++ protected:
|
|
1154
|
++ template <unsigned int RuntimeClassTypeT> friend class Details::RuntimeClassBaseT;
|
|
1155
|
++
|
|
1156
|
++ HRESULT CanCastTo(REFIID, void **, bool*) throw() {
|
|
1157
|
++ return 0;
|
|
1158
|
++ }
|
|
1159
|
++
|
|
1160
|
++ unsigned long GetIidCount() throw() {
|
|
1161
|
++ return 0;
|
|
1162
|
++ }
|
|
1163
|
++
|
|
1164
|
++ void FillArrayWithIid(unsigned long*, IID*) throw() {}
|
|
1165
|
++ };
|
|
1166
|
++
|
|
1167
|
++ template <typename RuntimeClassFlagsT, bool doStrictCheck, typename I0, typename ...TInterfaces>
|
|
1168
|
++ struct __declspec(novtable) ImplementsHelper<RuntimeClassFlagsT, doStrictCheck, CloakedIid<I0>, TInterfaces...> : ImplementsHelper<RuntimeClassFlagsT, doStrictCheck, I0>, ImplementsHelper<RuntimeClassFlagsT, true, TInterfaces...> {
|
|
1169
|
++ protected:
|
|
1170
|
++ template <unsigned int RuntimeClassTypeT> friend class Details::RuntimeClassBaseT;
|
|
1171
|
++
|
|
1172
|
++ HRESULT CanCastTo(REFIID riid, void **ppv, bool *pRefDelegated) throw() {
|
|
1173
|
++ return 0;
|
|
1174
|
++ }
|
|
1175
|
++
|
|
1176
|
++ IUnknown* CastToUnknown() throw() {
|
|
1177
|
++ return 0;
|
|
1178
|
++ }
|
|
1179
|
++
|
|
1180
|
++ unsigned long GetIidCount() throw() {
|
|
1181
|
++ return 0;
|
|
1182
|
++ }
|
|
1183
|
++
|
|
1184
|
++ void FillArrayWithIid(unsigned long *index, IID* iids) throw() {}
|
|
1185
|
++ };
|
|
1186
|
++
|
|
1187
|
++ template <typename RuntimeClassFlagsT, bool doStrictCheck, typename C0, typename C1, typename C2, typename C3, typename C4, typename C5, typename C6, typename C7, typename C8, typename C9, typename ...TInterfaces>
|
|
1188
|
++ struct __declspec(novtable) ImplementsHelper<RuntimeClassFlagsT, doStrictCheck, ChainInterfaces<C0, C1, C2, C3, C4, C5, C6, C7, C8, C9>, TInterfaces...> : ChainInterfaces<C0, C1, C2, C3, C4, C5, C6, C7, C8, C9>, ImplementsHelper<RuntimeClassFlagsT, true, TInterfaces...> {
|
|
1189
|
++ protected:
|
|
1190
|
++ template <unsigned int RuntimeClassTypeT> friend class Details::RuntimeClassBaseT;
|
|
1191
|
++
|
|
1192
|
++ HRESULT CanCastTo(REFIID riid, void **ppv, bool *pRefDelegated) throw() {
|
|
1193
|
++ return 0;
|
|
1194
|
++ }
|
|
1195
|
++
|
|
1196
|
++ IUnknown* CastToUnknown() throw() {
|
|
1197
|
++ return nullptr;
|
|
1198
|
++ }
|
|
1199
|
++
|
|
1200
|
++ unsigned long GetIidCount() throw() {
|
|
1201
|
++ return 0;
|
|
1202
|
++ }
|
|
1203
|
++
|
|
1204
|
++ void FillArrayWithIid(unsigned long *index, IID* iids) throw() {}
|
|
1205
|
++ };
|
|
1206
|
++
|
|
1207
|
++ template <typename RuntimeClassFlagsT, typename DerivedType, typename BaseType, bool hasImplements, typename ...TInterfaces, bool doStrictCheck>
|
|
1208
|
++ struct __declspec(novtable) ImplementsHelper<RuntimeClassFlagsT, doStrictCheck, MixIn<DerivedType, BaseType, hasImplements>, TInterfaces...> : ImplementsHelper<RuntimeClassFlagsT, true, TInterfaces...> {
|
|
1209
|
++ protected:
|
|
1210
|
++ template <unsigned int RuntimeClassTypeT> friend class Details::RuntimeClassBaseT;
|
|
1211
|
++
|
|
1212
|
++ HRESULT CanCastTo(REFIID riid, void **ppv, bool *pRefDelegated) throw() {
|
|
1213
|
++ return 0;
|
|
1214
|
++ }
|
|
1215
|
++
|
|
1216
|
++ IUnknown* CastToUnknown() throw() {
|
|
1217
|
++ return nullptr;
|
|
1218
|
++ }
|
|
1219
|
++
|
|
1220
|
++ unsigned long GetIidCount() throw() {
|
|
1221
|
++ return 0;
|
|
1222
|
++ }
|
|
1223
|
++
|
|
1224
|
++ void FillArrayWithIid(unsigned long *index, IID* iids) throw() {}
|
|
1225
|
++ };
|
|
1226
|
++
|
|
1227
|
++ template <typename I0, typename ...>
|
|
1228
|
++ struct AreAllNil {
|
|
1229
|
++ static const bool value = false;
|
|
1230
|
++ };
|
|
1231
|
++
|
|
1232
|
++ template <typename ...TInterfaces>
|
|
1233
|
++ struct AreAllNil<Microsoft::WRL::Details::Nil, TInterfaces...> {
|
|
1234
|
++ static const bool value = AreAllNil<TInterfaces...>::value;
|
|
1235
|
++ };
|
|
1236
|
++
|
|
1237
|
++ template <>
|
|
1238
|
++ struct AreAllNil<Microsoft::WRL::Details::Nil> {
|
|
1239
|
++ static const bool value = true;
|
|
1240
|
++ };
|
|
1241
|
++
|
|
1242
|
++ template <typename RuntimeClassFlagsT, typename FactoryInterface, bool doStrictCheck, typename ...TInterfaces>
|
|
1243
|
++ struct __declspec(novtable) ImplementsHelper<RuntimeClassFlagsT, doStrictCheck, ComposableBase<FactoryInterface>, TInterfaces...> : ImplementsHelper<RuntimeClassFlagsT, true, ComposableBase<FactoryInterface>> {
|
|
1244
|
++ protected:
|
|
1245
|
++ template <unsigned int RuntimeClassTypeT> friend class Details::RuntimeClassBaseT;
|
|
1246
|
++
|
|
1247
|
++ typedef ImplementsHelper<RuntimeClassFlagsT, true, ComposableBase<FactoryInterface>> Base;
|
|
1248
|
++
|
|
1249
|
++ HRESULT CanCastTo(REFIID riid, void **ppv, bool *pRefDelegated) throw() {
|
|
1250
|
++ return 0;
|
|
1251
|
++ }
|
|
1252
|
++
|
|
1253
|
++ IUnknown* CastToUnknown() throw() {
|
|
1254
|
++ return 0;
|
|
1255
|
++ }
|
|
1256
|
++
|
|
1257
|
++ unsigned long GetIidCount() throw() {
|
|
1258
|
++ return 0;
|
|
1259
|
++ }
|
|
1260
|
++
|
|
1261
|
++ void FillArrayWithIid(unsigned long *index, IID* iids) throw() {}
|
|
1262
|
++ };
|
|
1263
|
++
|
|
1264
|
++ template <typename RuntimeClassFlagsT, typename FactoryInterface, bool doStrictCheck>
|
|
1265
|
++ struct __declspec(novtable) ImplementsHelper<RuntimeClassFlagsT, doStrictCheck, ComposableBase<FactoryInterface>> {
|
|
1266
|
++ protected:
|
|
1267
|
++ template <unsigned int RuntimeClassTypeT> friend class Details::RuntimeClassBaseT;
|
|
1268
|
++
|
|
1269
|
++ HRESULT CanCastTo(REFIID riid, void **ppv, bool *pRefDelegated) throw() {
|
|
1270
|
++ return 0;
|
|
1271
|
++ }
|
|
1272
|
++
|
|
1273
|
++ IUnknown* CastToUnknown() throw() {
|
|
1274
|
++ return nullptr;
|
|
1275
|
++ }
|
|
1276
|
++
|
|
1277
|
++ unsigned long GetIidCount() throw() {
|
|
1278
|
++ return 0;
|
|
1279
|
++ }
|
|
1280
|
++
|
|
1281
|
++ void FillArrayWithIid(unsigned long *index, IID* iids) throw() {}
|
|
1282
|
++
|
|
1283
|
++ ImplementsHelper() throw() {}
|
|
1284
|
++
|
|
1285
|
++ ~ImplementsHelper() throw() {}
|
|
1286
|
++
|
|
1287
|
++ public:
|
|
1288
|
++ HRESULT SetComposableBasePointers(IInspectable* base, FactoryInterface* baseFactory) throw() {
|
|
1289
|
++ return 0;
|
|
1290
|
++ }
|
|
1291
|
++
|
|
1292
|
++ ComPtr<IInspectable> GetComposableBase() throw() {
|
|
1293
|
++ return composableBase_;
|
|
1294
|
++ }
|
|
1295
|
++
|
|
1296
|
++ ComPtr<FactoryInterface> GetComposableBaseFactory() throw() {
|
|
1297
|
++ return composableBaseFactory_;
|
|
1298
|
++ }
|
|
1299
|
++
|
|
1300
|
++ private:
|
|
1301
|
++ ComPtr<IInspectable> composableBase_;
|
|
1302
|
++
|
|
1303
|
++ ComPtr<FactoryInterface> composableBaseFactory_;
|
|
1304
|
++
|
|
1305
|
++ IID *iidsCached_;
|
|
1306
|
++
|
|
1307
|
++ unsigned long iidCount_;
|
|
1308
|
++ };
|
|
1309
|
++
|
|
1310
|
++ }
|
|
1311
|
++
|
|
1312
|
++ template <typename I0, typename ...TInterfaces>
|
|
1313
|
++ struct __declspec(novtable) Implements : Details::ImplementsHelper<RuntimeClassFlags<WinRt>, true, I0, TInterfaces...>, Details::ImplementsBase {
|
|
1314
|
++ public:
|
|
1315
|
++ typedef RuntimeClassFlags<WinRt> ClassFlags;
|
|
1316
|
++
|
|
1317
|
++ typedef I0 FirstInterface;
|
|
1318
|
++
|
|
1319
|
++ protected:
|
|
1320
|
++ HRESULT CanCastTo(REFIID riid, void **ppv) throw() {
|
|
1321
|
++ return 0;
|
|
1322
|
++ }
|
|
1323
|
++
|
|
1324
|
++ IUnknown* CastToUnknown() throw() {
|
|
1325
|
++ return nullptr;
|
|
1326
|
++ }
|
|
1327
|
++
|
|
1328
|
++ unsigned long GetIidCount() throw() {
|
|
1329
|
++ return 0;
|
|
1330
|
++ }
|
|
1331
|
++
|
|
1332
|
++ void FillArrayWithIid(unsigned long *index, IID* iids) throw() {}
|
|
1333
|
++ };
|
|
1334
|
++
|
|
1335
|
++ template <int flags, typename I0, typename ...TInterfaces>
|
|
1336
|
++ struct __declspec(novtable) Implements<RuntimeClassFlags<flags>, I0, TInterfaces...> : Details::ImplementsHelper<RuntimeClassFlags<flags>, true, I0, TInterfaces...>, Details::ImplementsBase {
|
|
1337
|
++ public:
|
|
1338
|
++ typedef RuntimeClassFlags<flags> ClassFlags;
|
|
1339
|
++
|
|
1340
|
++ typedef I0 FirstInterface;
|
|
1341
|
++
|
|
1342
|
++ protected:
|
|
1343
|
++ HRESULT CanCastTo(REFIID riid, void **ppv) throw() {
|
|
1344
|
++ return 0;
|
|
1345
|
++ }
|
|
1346
|
++
|
|
1347
|
++ IUnknown* CastToUnknown() throw() {
|
|
1348
|
++ return nullptr;
|
|
1349
|
++ }
|
|
1350
|
++
|
|
1351
|
++ unsigned long GetIidCount() throw() {
|
|
1352
|
++ return 0;
|
|
1353
|
++ }
|
|
1354
|
++
|
|
1355
|
++ void FillArrayWithIid(unsigned long *index, IID* iids) throw() {}
|
|
1356
|
++ };
|
|
1357
|
++
|
|
1358
|
++ class FtmBase : public Implements< ::Microsoft::WRL::RuntimeClassFlags<WinRtClassicComMix>, ::Microsoft::WRL::CloakedIid< ::IMarshal> >, private ::Microsoft::WRL::Details::FtmBaseMarker {
|
|
1359
|
++ protected:
|
|
1360
|
++ template <typename RuntimeClassFlagsT, bool doStrictCheck, typename ...TInterfaces> friend struct Details::ImplementsHelper;
|
|
1361
|
++
|
|
1362
|
++ HRESULT CanCastTo(REFIID riid, void **ppv) throw() {
|
|
1363
|
++ return 0;
|
|
1364
|
++ }
|
|
1365
|
++
|
|
1366
|
++ public:
|
|
1367
|
++ FtmBase() throw() {}
|
|
1368
|
++
|
|
1369
|
++ STDMETHOD(GetUnmarshalClass)(REFIID riid, void *pv, DWORD dwDestContext, void *pvDestContext, DWORD mshlflags, CLSID *pCid) override {
|
|
1370
|
++ return 0;
|
|
1371
|
++ }
|
|
1372
|
++
|
|
1373
|
++ STDMETHOD(GetMarshalSizeMax)(REFIID riid, void *pv, DWORD dwDestContext, void *pvDestContext, DWORD mshlflags, DWORD *pSize) override {
|
|
1374
|
++ return 0;
|
|
1375
|
++ }
|
|
1376
|
++
|
|
1377
|
++ STDMETHOD(MarshalInterface)(IStream *pStm, REFIID riid, void *pv, DWORD dwDestContext, void *pvDestContext, DWORD mshlflags) override {
|
|
1378
|
++ return 0;
|
|
1379
|
++ }
|
|
1380
|
++
|
|
1381
|
++ STDMETHOD(UnmarshalInterface)(IStream *pStm, REFIID riid, void **ppv) override {
|
|
1382
|
++ return 0;
|
|
1383
|
++ }
|
|
1384
|
++
|
|
1385
|
++ STDMETHOD(ReleaseMarshalData)(IStream *pStm) override {
|
|
1386
|
++ return 0;
|
|
1387
|
++ }
|
|
1388
|
++
|
|
1389
|
++ STDMETHOD(DisconnectObject)(DWORD dwReserved) override {
|
|
1390
|
++ return 0;
|
|
1391
|
++ }
|
|
1392
|
++
|
|
1393
|
++ static HRESULT CreateGlobalInterfaceTable(IGlobalInterfaceTable **git) throw() {
|
|
1394
|
++ return 0;
|
|
1395
|
++ }
|
|
1396
|
++
|
|
1397
|
++ ::Microsoft::WRL::ComPtr<IMarshal> marshaller_;
|
|
1398
|
++ };
|
|
1399
|
++
|
|
1400
|
++ namespace Details {
|
|
1401
|
++ #define DETAILS_RTCLASS_FLAGS_ARGUMENTS(RuntimeClassFlagsT) \
|
|
1402
|
++ RuntimeClassFlagsT, \
|
|
1403
|
++ (RuntimeClassFlagsT::value & InhibitWeakReference) == 0, \
|
|
1404
|
++ (RuntimeClassFlagsT::value & WinRt) == WinRt, \
|
|
1405
|
++ __WRL_IMPLEMENTS_FTM_BASE__(RuntimeClassFlagsT::value) \
|
|
1406
|
++
|
|
1407
|
++ template <class RuntimeClassFlagsT, bool implementsWeakReferenceSource, bool implementsInspectable, bool implementsFtmBase, typename ...TInterfaces>
|
|
1408
|
++ class __declspec(novtable) RuntimeClassImpl;
|
|
1409
|
++
|
|
1410
|
++ template <class RuntimeClassFlagsT, bool implementsWeakReferenceSource, bool implementsFtmBase, typename ...TInterfaces>
|
|
1411
|
++ class __declspec(novtable) RuntimeClassImpl<RuntimeClassFlagsT, implementsWeakReferenceSource, false, implementsFtmBase, TInterfaces...> : public Details::ImplementsHelper<RuntimeClassFlagsT, false, TInterfaces...>, public RuntimeClassBaseT<RuntimeClassFlagsT::value>, protected RuntimeClassFlags<InhibitWeakReference>, public DontUseNewUseMake {
|
|
1412
|
++ public:
|
|
1413
|
++ typedef RuntimeClassFlagsT ClassFlags;
|
|
1414
|
++
|
|
1415
|
++ STDMETHOD(QueryInterface)(REFIID riid, void **ppvObject) {
|
|
1416
|
++ return 0;
|
|
1417
|
++ }
|
|
1418
|
++
|
|
1419
|
++ STDMETHOD_(ULONG, AddRef)() {
|
|
1420
|
++ return 0;
|
|
1421
|
++ }
|
|
1422
|
++
|
|
1423
|
++ STDMETHOD_(ULONG, Release)() {
|
|
1424
|
++ return 0;
|
|
1425
|
++ }
|
|
1426
|
++
|
|
1427
|
++ protected:
|
|
1428
|
++ RuntimeClassImpl() throw() {}
|
|
1429
|
++
|
|
1430
|
++ virtual ~RuntimeClassImpl() throw() {}
|
|
1431
|
++
|
|
1432
|
++ unsigned long InternalAddRef() throw() {
|
|
1433
|
++ return 0;
|
|
1434
|
++ }
|
|
1435
|
++
|
|
1436
|
++ unsigned long InternalRelease() throw() {
|
|
1437
|
++ return 0;
|
|
1438
|
++ }
|
|
1439
|
++
|
|
1440
|
++ unsigned long GetRefCount() const throw() {
|
|
1441
|
++ return 0;
|
|
1442
|
++ }
|
|
1443
|
++
|
|
1444
|
++ friend class WeakReferenceImpl;
|
|
1445
|
++
|
|
1446
|
++ private:
|
|
1447
|
++ volatile long refcount_;
|
|
1448
|
++ };
|
|
1449
|
++
|
|
1450
|
++ template<typename I, bool isImplementsBased = __is_base_of(ImplementsBase, I)>
|
|
1451
|
++ struct HasIInspectable;
|
|
1452
|
++
|
|
1453
|
++ template<typename I>
|
|
1454
|
++ struct HasIInspectable<I, false> {
|
|
1455
|
++ static const bool isIInspectable;
|
|
1456
|
++ };
|
|
1457
|
++
|
|
1458
|
++ template<typename I>
|
|
1459
|
++ struct HasIInspectable<I, true> {
|
|
1460
|
++ static const bool isIInspectable;
|
|
1461
|
++ };
|
|
1462
|
++
|
|
1463
|
++ template<typename I0, bool isIInspectable = true>
|
|
1464
|
++ struct IInspectableInjector;
|
|
1465
|
++
|
|
1466
|
++ template<typename I0>
|
|
1467
|
++ struct IInspectableInjector<I0, true> {
|
|
1468
|
++ typedef Details::Nil InspectableIfNeeded;
|
|
1469
|
++ };
|
|
1470
|
++
|
|
1471
|
++ template<typename I0>
|
|
1472
|
++ struct IInspectableInjector<I0, false> {
|
|
1473
|
++ typedef IInspectable InspectableIfNeeded;
|
|
1474
|
++ };
|
|
1475
|
++
|
|
1476
|
++ template <class RuntimeClassFlagsT, typename I0, typename ...TInterfaces>
|
|
1477
|
++ class __declspec(novtable) RuntimeClassImpl<RuntimeClassFlagsT, false, true, false, I0, TInterfaces...> : public Details::ImplementsHelper<RuntimeClassFlagsT, false, typename IInspectableInjector<I0>::InspectableIfNeeded, I0, TInterfaces...>, public RuntimeClassBaseT<RuntimeClassFlagsT::value>, protected RuntimeClassFlags<InhibitWeakReference>, public DontUseNewUseMake {
|
|
1478
|
++ public:
|
|
1479
|
++ typedef RuntimeClassFlagsT ClassFlags;
|
|
1480
|
++
|
|
1481
|
++ STDMETHOD(QueryInterface)(REFIID riid, void **ppvObject) {
|
|
1482
|
++ return 0;
|
|
1483
|
++ }
|
|
1484
|
++
|
|
1485
|
++ STDMETHOD_(ULONG, AddRef)() {
|
|
1486
|
++ return 0;
|
|
1487
|
++ }
|
|
1488
|
++
|
|
1489
|
++ STDMETHOD_(ULONG, Release)() {
|
|
1490
|
++ return 0;
|
|
1491
|
++ }
|
|
1492
|
++
|
|
1493
|
++ STDMETHOD(GetIids)(ULONG *iidCount, IID **iids) {
|
|
1494
|
++ return 0;
|
|
1495
|
++ }
|
|
1496
|
++
|
|
1497
|
++ protected:
|
|
1498
|
++ RuntimeClassImpl() throw() {}
|
|
1499
|
++
|
|
1500
|
++ virtual ~RuntimeClassImpl() throw() {}
|
|
1501
|
++
|
|
1502
|
++ unsigned long InternalAddRef() throw() {
|
|
1503
|
++ return 0;
|
|
1504
|
++ }
|
|
1505
|
++
|
|
1506
|
++ unsigned long InternalRelease() throw() {
|
|
1507
|
++ return 0;
|
|
1508
|
++ }
|
|
1509
|
++
|
|
1510
|
++ unsigned long GetRefCount() const throw() {
|
|
1511
|
++ return 0;
|
|
1512
|
++ }
|
|
1513
|
++
|
|
1514
|
++ private:
|
|
1515
|
++ volatile long refcount_;
|
|
1516
|
++ };
|
|
1517
|
++
|
|
1518
|
++ template <class RuntimeClassFlagsT, typename I0, typename ...TInterfaces>
|
|
1519
|
++ class __declspec(novtable) RuntimeClassImpl<RuntimeClassFlagsT, false, true, true, I0, TInterfaces...> : public RuntimeClassImpl<RuntimeClassFlagsT, false, true, false, I0, TInterfaces...> {};
|
|
1520
|
++
|
|
1521
|
++ template <class RuntimeClassFlagsT, typename I0, typename ...TInterfaces>
|
|
1522
|
++ class __declspec(novtable) RuntimeClassImpl<RuntimeClassFlagsT, true, true, true, I0, TInterfaces...> : public RuntimeClassImpl<RuntimeClassFlagsT, true, true, false, I0, FtmBase, TInterfaces...> {};
|
|
1523
|
++ }
|
|
1524
|
++
|
|
1525
|
++ template <typename ...TInterfaces>
|
|
1526
|
++ class RuntimeClass : public Details::RuntimeClassImpl<DETAILS_RTCLASS_FLAGS_ARGUMENTS(RuntimeClassFlags<WinRt>), TInterfaces...> {
|
|
1527
|
++ RuntimeClass(const RuntimeClass&);
|
|
1528
|
++
|
|
1529
|
++ RuntimeClass& operator=(const RuntimeClass&);
|
|
1530
|
++
|
|
1531
|
++ public:
|
|
1532
|
++ RuntimeClass() throw() {}
|
|
1533
|
++
|
|
1534
|
++ typedef RuntimeClass RuntimeClassT;
|
|
1535
|
++ };
|
|
1536
|
++
|
|
1537
|
++ template <unsigned int classFlags, typename ...TInterfaces>
|
|
1538
|
++ class RuntimeClass<RuntimeClassFlags<classFlags>, TInterfaces...> : public Details::RuntimeClassImpl<DETAILS_RTCLASS_FLAGS_ARGUMENTS(RuntimeClassFlags<classFlags>), TInterfaces...> {
|
|
1539
|
++ RuntimeClass(const RuntimeClass&);
|
|
1540
|
++
|
|
1541
|
++ RuntimeClass& operator=(const RuntimeClass&);
|
|
1542
|
++
|
|
1543
|
++ public:
|
|
1544
|
++ RuntimeClass() throw() {}
|
|
1545
|
++
|
|
1546
|
++ typedef RuntimeClass RuntimeClassT;
|
|
1547
|
++ };
|
|
1548
|
++ }
|
|
1549
|
++}
|
|
1550
|
++
|
|
1551
|
++#include <poppack.h>
|
|
1552
|
++
|
|
1553
|
++#endif
|
|
1554
|
+diff --git a/mingw-w64-headers/include/wrl/internal.h b/mingw-w64-headers/include/wrl/internal.h
|
|
1555
|
+index 715ef74e3..dffa7153d 100644
|
|
1556
|
+--- a/mingw-w64-headers/include/wrl/internal.h
|
|
1557
|
++++ b/mingw-w64-headers/include/wrl/internal.h
|
|
1558
|
+@@ -7,6 +7,8 @@
|
|
1559
|
+ #ifndef _WRL_INTERNAL_H_
|
|
1560
|
+ #define _WRL_INTERNAL_H_
|
|
1561
|
+
|
|
1562
|
++#define __WRL_IMPLEMENTS_FTM_BASE__(flags) (false)
|
|
1563
|
++
|
|
1564
|
+ #include <windows.h>
|
|
1565
|
+
|
|
1566
|
+ namespace Microsoft {
|
|
1567
|
+@@ -29,6 +31,26 @@ namespace Microsoft {
|
|
1568
|
+ struct EnableIf<true, T> {
|
|
1569
|
+ typedef T type;
|
|
1570
|
+ };
|
|
1571
|
++
|
|
1572
|
++ template<class T>
|
|
1573
|
++ struct RemoveReference {
|
|
1574
|
++ typedef T Type;
|
|
1575
|
++ };
|
|
1576
|
++
|
|
1577
|
++ template<class T>
|
|
1578
|
++ struct RemoveReference<T&> {
|
|
1579
|
++ typedef T Type;
|
|
1580
|
++ };
|
|
1581
|
++
|
|
1582
|
++ template<class T>
|
|
1583
|
++ struct RemoveReference<T&&> {
|
|
1584
|
++ typedef T Type;
|
|
1585
|
++ };
|
|
1586
|
++
|
|
1587
|
++ template<class T>
|
|
1588
|
++ inline typename RemoveReference<T>::Type&& Move(T&& arg) throw() {
|
|
1589
|
++ return nullptr;
|
|
1590
|
++ }
|
|
1591
|
+ }
|
|
1592
|
+ }
|
|
1593
|
+ }
|
|
1594
|
+diff --git a/mingw-w64-headers/include/wrl/wrappers/corewrappers.h b/mingw-w64-headers/include/wrl/wrappers/corewrappers.h
|
|
1595
|
+index 221d9cc8f..4b15f43ec 100644
|
|
1596
|
+--- a/mingw-w64-headers/include/wrl/wrappers/corewrappers.h
|
|
1597
|
++++ b/mingw-w64-headers/include/wrl/wrappers/corewrappers.h
|
|
1598
|
+@@ -22,6 +22,129 @@ namespace Microsoft {
|
|
1599
|
+ }
|
|
1600
|
+
|
|
1601
|
+ namespace Wrappers {
|
|
1602
|
++ namespace HandleTraits {
|
|
1603
|
++ struct SRWLockSharedTraits {
|
|
1604
|
++ typedef SRWLOCK* Type;
|
|
1605
|
++
|
|
1606
|
++ inline static Type GetInvalidValue() throw() {
|
|
1607
|
++ return nullptr;
|
|
1608
|
++ }
|
|
1609
|
++
|
|
1610
|
++ inline static void Unlock(Type srwlock) throw() {}
|
|
1611
|
++ };
|
|
1612
|
++
|
|
1613
|
++ struct SRWLockExclusiveTraits {
|
|
1614
|
++ typedef SRWLOCK* Type;
|
|
1615
|
++
|
|
1616
|
++ inline static Type GetInvalidValue() throw() {
|
|
1617
|
++ return nullptr;
|
|
1618
|
++ }
|
|
1619
|
++
|
|
1620
|
++ inline static void Unlock(Type srwlock) throw() {}
|
|
1621
|
++ };
|
|
1622
|
++ }
|
|
1623
|
++
|
|
1624
|
++ class SRWLock;
|
|
1625
|
++
|
|
1626
|
++ namespace Details {
|
|
1627
|
++ class SyncLockExclusive {
|
|
1628
|
++ public:
|
|
1629
|
++ SyncLockExclusive(SyncLockExclusive&& other) throw() {}
|
|
1630
|
++
|
|
1631
|
++ SyncLockExclusive(const SyncLockExclusive&);
|
|
1632
|
++ SyncLockExclusive& operator=(const SyncLockExclusive&);
|
|
1633
|
++
|
|
1634
|
++ ~SyncLockExclusive() throw() {}
|
|
1635
|
++
|
|
1636
|
++ void Unlock() throw() {}
|
|
1637
|
++
|
|
1638
|
++ bool IsLocked() const throw() {
|
|
1639
|
++ return 0;
|
|
1640
|
++ }
|
|
1641
|
++
|
|
1642
|
++ friend class Wrappers::SRWLock;
|
|
1643
|
++
|
|
1644
|
++ protected:
|
|
1645
|
++ explicit SyncLockExclusive(SRWLOCK* sync) throw() {}
|
|
1646
|
++
|
|
1647
|
++ SRWLOCK* sync_;
|
|
1648
|
++
|
|
1649
|
++ private:
|
|
1650
|
++ void InternalUnlock() throw() {}
|
|
1651
|
++ };
|
|
1652
|
++
|
|
1653
|
++ class SyncLockShared {
|
|
1654
|
++ public:
|
|
1655
|
++ SyncLockShared(SyncLockShared&& other) throw() {}
|
|
1656
|
++
|
|
1657
|
++ SyncLockShared(const SyncLockShared&);
|
|
1658
|
++ SyncLockShared& operator=(const SyncLockShared&);
|
|
1659
|
++
|
|
1660
|
++ ~SyncLockShared() throw() {}
|
|
1661
|
++
|
|
1662
|
++ void Unlock() throw() {}
|
|
1663
|
++
|
|
1664
|
++ bool IsLocked() const throw() {
|
|
1665
|
++ return 0;
|
|
1666
|
++ }
|
|
1667
|
++
|
|
1668
|
++ friend class Wrappers::SRWLock;
|
|
1669
|
++
|
|
1670
|
++ protected:
|
|
1671
|
++ explicit SyncLockShared(SRWLOCK* sync) throw() {}
|
|
1672
|
++
|
|
1673
|
++ SRWLOCK* sync_;
|
|
1674
|
++
|
|
1675
|
++ private:
|
|
1676
|
++ void InternalUnlock() throw() {}
|
|
1677
|
++ };
|
|
1678
|
++ }
|
|
1679
|
++
|
|
1680
|
++ class SRWLock {
|
|
1681
|
++ public:
|
|
1682
|
++ SRWLock() throw() {}
|
|
1683
|
++
|
|
1684
|
++ SRWLock(const SRWLock&) = delete;
|
|
1685
|
++ SRWLock& operator=(const SRWLock&) = delete;
|
|
1686
|
++
|
|
1687
|
++ ~SRWLock() throw() {}
|
|
1688
|
++
|
|
1689
|
++ Details::SyncLockExclusive LockExclusive() throw() {
|
|
1690
|
++ return Details::SyncLockExclusive(nullptr);
|
|
1691
|
++ }
|
|
1692
|
++
|
|
1693
|
++ static Details::SyncLockExclusive LockExclusive(SRWLOCK* lock) throw() {
|
|
1694
|
++ return Details::SyncLockExclusive(nullptr);
|
|
1695
|
++ }
|
|
1696
|
++
|
|
1697
|
++ Details::SyncLockExclusive TryLockExclusive() throw() {
|
|
1698
|
++ return Details::SyncLockExclusive(nullptr);
|
|
1699
|
++ }
|
|
1700
|
++
|
|
1701
|
++ static Details::SyncLockExclusive TryLockExclusive(SRWLOCK* lock) throw() {
|
|
1702
|
++ return Details::SyncLockExclusive(nullptr);
|
|
1703
|
++ }
|
|
1704
|
++
|
|
1705
|
++ Details::SyncLockShared LockShared() throw() {
|
|
1706
|
++ return Details::SyncLockShared(nullptr);
|
|
1707
|
++ }
|
|
1708
|
++
|
|
1709
|
++ static Details::SyncLockShared LockShared(SRWLOCK* lock) throw() {
|
|
1710
|
++ return Details::SyncLockShared(nullptr);
|
|
1711
|
++ }
|
|
1712
|
++
|
|
1713
|
++ Details::SyncLockShared TryLockShared() throw() {
|
|
1714
|
++ return Details::SyncLockShared(nullptr);
|
|
1715
|
++ }
|
|
1716
|
++
|
|
1717
|
++ static Details::SyncLockShared TryLockShared(SRWLOCK* lock) throw() {
|
|
1718
|
++ return Details::SyncLockShared(nullptr);
|
|
1719
|
++ }
|
|
1720
|
++
|
|
1721
|
++ protected:
|
|
1722
|
++ SRWLOCK SRWLock_;
|
|
1723
|
++ };
|
|
1724
|
++
|
|
1725
|
+ class HStringReference {
|
|
1726
|
+ private:
|
|
1727
|
+ void Init(const wchar_t* str, unsigned int len) { |