mirror of
git://source.winehq.org/git/wine.git
synced 2024-09-06 05:40:59 +00:00
hid: Implement HidD_GetAttributes.
This commit is contained in:
parent
eac15cae71
commit
674080da91
|
@ -1,6 +1,6 @@
|
|||
@ stub HidD_FlushQueue
|
||||
@ stdcall HidD_FreePreparsedData(ptr)
|
||||
@ stub HidD_GetAttributes
|
||||
@ stdcall HidD_GetAttributes(long ptr)
|
||||
@ stub HidD_GetConfiguration
|
||||
@ stdcall HidD_GetFeature(long ptr long)
|
||||
@ stdcall HidD_GetHidGuid(ptr)
|
||||
|
|
|
@ -34,7 +34,7 @@
|
|||
|
||||
#include "hidusage.h"
|
||||
#include "ddk/hidclass.h"
|
||||
#include "ddk/hidpi.h"
|
||||
#include "ddk/hidsdi.h"
|
||||
|
||||
WINE_DEFAULT_DEBUG_CHANNEL(hid);
|
||||
|
||||
|
@ -45,6 +45,24 @@ BOOLEAN WINAPI HidD_FreePreparsedData(PHIDP_PREPARSED_DATA PreparsedData)
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
BOOLEAN WINAPI HidD_GetAttributes(HANDLE HidDeviceObject, PHIDD_ATTRIBUTES Attr)
|
||||
{
|
||||
HID_COLLECTION_INFORMATION info;
|
||||
BOOLEAN ret;
|
||||
|
||||
TRACE("(%p %p)\n", HidDeviceObject, Attr);
|
||||
|
||||
ret = DeviceIoControl(HidDeviceObject, IOCTL_HID_GET_COLLECTION_INFORMATION, NULL, 0, &info, sizeof(HID_COLLECTION_INFORMATION), NULL, NULL);
|
||||
|
||||
if (ret)
|
||||
{
|
||||
Attr->VendorID = info.VendorID;
|
||||
Attr->ProductID = info.ProductID;
|
||||
Attr->VersionNumber = info.VersionNumber;
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
||||
BOOLEAN WINAPI HidD_GetFeature(HANDLE HidDeviceObject, PVOID ReportBuffer, ULONG ReportBufferLength)
|
||||
{
|
||||
TRACE("(%p %p %u)\n", HidDeviceObject, ReportBuffer, ReportBufferLength);
|
||||
|
|
|
@ -27,6 +27,13 @@
|
|||
typedef LONG NTSTATUS;
|
||||
#endif
|
||||
|
||||
typedef struct _HIDD_ATTRIBUTES {
|
||||
ULONG Size;
|
||||
USHORT VendorID;
|
||||
USHORT ProductID;
|
||||
USHORT VersionNumber;
|
||||
} HIDD_ATTRIBUTES, *PHIDD_ATTRIBUTES;
|
||||
|
||||
BOOLEAN WINAPI HidD_GetFeature(HANDLE HidDeviceObject, PVOID ReportBuffer, ULONG ReportBufferLength);
|
||||
void WINAPI HidD_GetHidGuid(LPGUID guid);
|
||||
BOOLEAN WINAPI HidD_GetInputReport(HANDLE HidDeviceObject, PVOID ReportBuffer, ULONG ReportBufferLength);
|
||||
|
@ -35,5 +42,6 @@ BOOLEAN WINAPI HidD_GetProductString(HANDLE HidDeviceObject, PVOID Buffer, ULONG
|
|||
BOOLEAN WINAPI HidD_SetFeature(HANDLE HidDeviceObject, PVOID ReportBuffer, ULONG ReportBufferLength);
|
||||
BOOLEAN WINAPI HidD_GetPreparsedData( HANDLE HidDeviceObject, PHIDP_PREPARSED_DATA *PreparsedData);
|
||||
BOOLEAN WINAPI HidD_FreePreparsedData(PHIDP_PREPARSED_DATA PreparsedData);
|
||||
BOOLEAN WINAPI HidD_GetAttributes(HANDLE HidDeviceObject, PHIDD_ATTRIBUTES Attr);
|
||||
|
||||
#endif /* __WINE_HIDSDI_H */
|
||||
|
|
Loading…
Reference in a new issue