mirror of
https://github.com/DarthAffe/RGB.NET.git
synced 2025-12-12 17:48:31 +00:00
use serial number hash as update trigger id
This commit is contained in:
parent
34b04523de
commit
dc6715b236
@ -71,7 +71,6 @@ public sealed class WootingGrpcDeviceProvider : AbstractRGBDeviceProvider
|
|||||||
{
|
{
|
||||||
ArgumentNullException.ThrowIfNull(_client, nameof(_client));
|
ArgumentNullException.ThrowIfNull(_client, nameof(_client));
|
||||||
|
|
||||||
int i = 0;
|
|
||||||
foreach (RgbGetConnectedDevicesResponse.Types.RgbDevice? device in _client.GetConnectedDevices(new()).Devices)
|
foreach (RgbGetConnectedDevicesResponse.Types.RgbDevice? device in _client.GetConnectedDevices(new()).Devices)
|
||||||
{
|
{
|
||||||
if (device.DeviceType == RgbDeviceType.None)
|
if (device.DeviceType == RgbDeviceType.None)
|
||||||
@ -79,7 +78,7 @@ public sealed class WootingGrpcDeviceProvider : AbstractRGBDeviceProvider
|
|||||||
|
|
||||||
_client.Initialize(new RgbInitializeRequest { Id = device.Id });
|
_client.Initialize(new RgbInitializeRequest { Id = device.Id });
|
||||||
|
|
||||||
WootingGrpcUpdateQueue updateQueue = new(GetUpdateTrigger(i++), device, _client);
|
WootingGrpcUpdateQueue updateQueue = new(GetUpdateTrigger(device.SerialNumber.GetHashCode()), device, _client);
|
||||||
|
|
||||||
WootingDeviceType deviceType = device.DeviceType switch
|
WootingDeviceType deviceType = device.DeviceType switch
|
||||||
{
|
{
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user