Track keyboard labels from host layout events

This commit is contained in:
Babib3l
2026-03-18 21:19:35 +01:00
parent 84f3ce2ca5
commit 39f58e453b
3 changed files with 56 additions and 19 deletions

View File

@@ -1,19 +0,0 @@
namespace Ryujinx.Common.Configuration.Hid
{
public static class KeyboardKeyExtensions
{
public static Key ToKey(this PhysicalKey key)
{
return key is >= PhysicalKey.Unknown and < PhysicalKey.Count
? (Key)(int)key
: Key.Unknown;
}
public static PhysicalKey ToPhysicalKey(this Key key)
{
return key is >= Key.Unknown and < Key.Count
? (PhysicalKey)(int)key
: PhysicalKey.Unknown;
}
}
}