From 78ef8404255124680c12b611244b5c0ad53f963e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Bernon?= Date: Tue, 1 Mar 2022 09:32:34 +0100 Subject: [PATCH] include: Add Windows.Gaming.Input.HidGameControllerProvider runtimeclass definition. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: RĂ©mi Bernon Signed-off-by: Alexandre Julliard --- include/windows.gaming.input.custom.idl | 31 +++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/include/windows.gaming.input.custom.idl b/include/windows.gaming.input.custom.idl index 637e1d4abcf..acc15955368 100644 --- a/include/windows.gaming.input.custom.idl +++ b/include/windows.gaming.input.custom.idl @@ -35,10 +35,12 @@ namespace Windows.Gaming.Input.Custom { interface IGameControllerInputSink; interface IGameControllerProvider; interface IHidGameControllerInputSink; + interface IHidGameControllerProvider; interface ICustomGameControllerFactory; interface IGameControllerFactoryManagerStatics; interface IGameControllerFactoryManagerStatics2; runtimeclass GameControllerFactoryManager; + runtimeclass HidGameControllerProvider; [contract(Windows.Foundation.UniversalApiContract, 3.0)] enum XusbDeviceSubtype @@ -106,6 +108,24 @@ namespace Windows.Gaming.Input.Custom { [in, size_is(report_len)] BYTE *report_buf); } + [ + contract(Windows.Foundation.UniversalApiContract, 4.0), + exclusiveto(Windows.Gaming.Input.Custom.HidGameControllerProvider), + uuid(95ce3af4-abf0-4b68-a081-3b7de73ff0e7) + ] + interface IHidGameControllerProvider : IInspectable + requires Windows.Gaming.Input.Custom.IGameControllerProvider + { + [propget] HRESULT UsageId([out, retval] UINT16 *value); + [propget] HRESULT UsagePage([out, retval] UINT16 *value); + HRESULT GetFeatureReport([in] BYTE id, [in] UINT32 report_len, + [out, size_is(report_len)] BYTE *report_buf); + HRESULT SendFeatureReport([in] BYTE id, [in] UINT32 report_len, + [in, size_is(report_len)] BYTE *report_buf); + HRESULT SendOutputReport([in] BYTE id, [in] UINT32 report_len, + [in, size_is(report_len)] BYTE *report_buf); + } + [ contract(Windows.Foundation.UniversalApiContract, 3.0), uuid(69a0ae5e-758e-4cbe-ace6-62155fe9126f) @@ -157,4 +177,15 @@ namespace Windows.Gaming.Input.Custom { runtimeclass GameControllerFactoryManager { } + + [ + contract(Windows.Foundation.UniversalApiContract, 4.0), + marshaling_behavior(agile), + threading(both) + ] + runtimeclass HidGameControllerProvider + { + [default] interface Windows.Gaming.Input.Custom.IHidGameControllerProvider; + interface Windows.Gaming.Input.Custom.IGameControllerProvider; + } }