On Mon Apr 17 07:07:01 2023 +0000, Rémi Bernon wrote:
Actually only HMONITOR is an issue, and it could be added to the same widl case as HANDLE, then something like that would work:
#ifdef __WIDL__ #pragma winrt ns_prefix #endif import "windows.ui.composition.idl"; import "windows.graphics.capture.idl"; import "sdkddkver.h"; cpp_quote("#if 0") typedef HANDLE HMONITOR; cpp_quote("#endif /* 0 */") [ uuid(3628e81b-3cac-4c60-b7f4-23ce0e0c3356) ] interface IGraphicsCaptureItemInterop : IUnknown { HRESULT CreateForWindow([in] HWND window, [in] REFIID iid, [out, iid_is(iid)] void **result); HRESULT CreateForMonitor([in] HMONITOR monitor, [in] REFIID iid, [out, iid_is(iid)] void **result); }
Looks like there was an issue in my build environment. Thanks, that works with added `HMONITOR` support.