misc: chore: Use collection expressions in Avalonia project

This commit is contained in:
Evan Husted
2025-01-26 15:47:11 -06:00
parent 46a5cafaa8
commit ae90db2040
28 changed files with 114 additions and 112 deletions

View File

@@ -11,7 +11,7 @@ namespace Ryujinx.Ava.Input
{
internal class AvaloniaKeyboardDriver : IGamepadDriver
{
private static readonly string[] _keyboardIdentifers = new string[1] { "0" };
private static readonly string[] _keyboardIdentifers = ["0"];
private readonly Control _control;
private readonly HashSet<AvaKey> _pressedKeys;
@@ -25,7 +25,7 @@ namespace Ryujinx.Ava.Input
public AvaloniaKeyboardDriver(Control control)
{
_control = control;
_pressedKeys = new HashSet<AvaKey>();
_pressedKeys = [];
_control.KeyDown += OnKeyPress;
_control.KeyUp += OnKeyRelease;