mirror of
https://git.ryujinx.app/ryubing/ryujinx.git
synced 2026-06-04 11:29:14 +00:00
Cache Avalonia keyboard LED state
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
using Ryujinx.Common.Configuration.Hid;
|
||||
using Ryujinx.Common.Configuration.Hid.Keyboard;
|
||||
using Ryujinx.Common.Logging;
|
||||
using Ryujinx.Input;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
@@ -15,6 +16,7 @@ namespace Ryujinx.Ava.Input
|
||||
private readonly List<ButtonMappingEntry> _buttonsUserMapping;
|
||||
private readonly AvaloniaKeyboardDriver _driver;
|
||||
private StandardKeyboardInputConfig _configuration;
|
||||
private uint _ledValue;
|
||||
|
||||
private readonly Lock _userMappingLock = new();
|
||||
|
||||
@@ -145,6 +147,15 @@ namespace Ryujinx.Ava.Input
|
||||
|
||||
public void SetLed(uint packedRgb)
|
||||
{
|
||||
if (_ledValue == packedRgb)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
_ledValue = packedRgb;
|
||||
|
||||
Logger.Info?.Print(LogClass.UI, "SetLed called on an AvaloniaKeyboard");
|
||||
|
||||
// Keyboard LED is not supported by this backend.
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user