mirror of
https://github.com/DarthAffe/RGB.NET.git
synced 2025-12-13 01:58:30 +00:00
Merge pull request #405 from DarthAffe/LogitechMultipleDevicesFix
Fixed crash in logitech device provider, when multiple lightspeed dev…
This commit is contained in:
commit
a0198e3991
@ -104,7 +104,9 @@ public sealed class LightspeedHIDLoader<TLed, TData> : IEnumerable<HIDDeviceDefi
|
||||
Dictionary<byte, HidDevice> deviceUsages = DeviceList.Local
|
||||
.GetHidDevices(VendorId, pid)
|
||||
.Where(d => d.DevicePath.Contains("mi_02"))
|
||||
.ToDictionary(x => (byte)x.GetUsage(), x => x);
|
||||
.Select(x => ((byte)x.GetUsage(), x))
|
||||
.DistinctBy(x => x.Item1)
|
||||
.ToDictionary(x => x.Item1, x => x.x);
|
||||
|
||||
foreach ((int wirelessPid, byte _) in GetWirelessDevices(deviceUsages))
|
||||
yield return wirelessPid;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user