MCPcopy Create free account
hub / github.com/360Controller/360Controller / handleReport

Method handleReport

360Controller/ChatPad.cpp:57–72  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

55}
56
57IOReturn ChatPadKeyboardClass::handleReport(IOMemoryDescriptor *report, IOHIDReportType reportType, IOOptionBits options)
58{
59 IOBufferMemoryDescriptor *realReport = OSDynamicCast(IOBufferMemoryDescriptor, report);
60 if (realReport != NULL)
61 {
62 unsigned char *data = (unsigned char*)realReport->getBytesNoCopy();
63 if (data[0] == 0x00)
64 {
65 for (int i = 2; i < 5; i++)
66 {
67 data[i] = ChatPad2USB(data[i]);
68 }
69 }
70 }
71 return IOHIDDevice::handleReport(report, reportType, options);
72}
73
74OSNumber* ChatPadKeyboardClass::newPrimaryUsageNumber() const
75{

Callers 2

ReadCompleteMethod · 0.45
SerialMessageMethod · 0.45

Calls 1

ChatPad2USBFunction · 0.85

Tested by

no test coverage detected