Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HidEnumerator: skip HID devices with Apple's other vendor ID #4273

Merged
merged 1 commit into from
Sep 8, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/controllers/hid/hiddenylist.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@ hid_denylist_t hid_denylisted[] = {
{0x1157, 0x300, 0x0, 0x0, 0x3}, // EKS Otus mouse pad (linux)
};

// Apple has two two different vendor IDs which are used for different devices.
constexpr unsigned short kAppleVendorId = 0x5ac;
constexpr unsigned short kAppleIncVendorId = 0x004c;

constexpr unsigned short kGenericDesktopUsagePage = 0x01;

Expand Down
2 changes: 1 addition & 1 deletion src/controllers/hid/hidenumerator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ bool recognizeDevice(const hid_device_info& device_info) {
// these devices in future computers and none of these devices are DJ controllers,
// so skip all Apple HID devices rather than maintaining a list of specific devices
// to skip.
if (device_info.vendor_id == kAppleVendorId) {
if (device_info.vendor_id == kAppleVendorId || device_info.vendor_id == kAppleIncVendorId) {
return false;
}

Expand Down