Migrate to .NET 9 (#198)

This commit is contained in:
Marco Carvalho 2024-12-19 21:52:25 -03:00 committed by GitHub
parent 8db5a7e98b
commit ff6628149d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
136 changed files with 278 additions and 270 deletions

View file

@ -1,7 +1,6 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<DefaultItemExcludes>$(DefaultItemExcludes);._*</DefaultItemExcludes>
</PropertyGroup>

View file

@ -4,6 +4,7 @@ using Ryujinx.Common.Logging;
using System;
using System.Collections.Generic;
using System.Numerics;
using System.Threading;
using static SDL2.SDL;
namespace Ryujinx.Input.SDL2
@ -58,7 +59,7 @@ namespace Ryujinx.Input.SDL2
SDL_GameControllerButton.SDL_CONTROLLER_BUTTON_INVALID,
};
private readonly object _userMappingLock = new();
private readonly Lock _userMappingLock = new();
private readonly List<ButtonMappingEntry> _buttonsUserMapping;

View file

@ -1,6 +1,7 @@
using Ryujinx.SDL2.Common;
using System;
using System.Collections.Generic;
using System.Threading;
using static SDL2.SDL;
namespace Ryujinx.Input.SDL2
@ -9,7 +10,7 @@ namespace Ryujinx.Input.SDL2
{
private readonly Dictionary<int, string> _gamepadsInstanceIdsMapping;
private readonly List<string> _gamepadsIds;
private readonly object _lock = new();
private readonly Lock _lock = new();
public ReadOnlySpan<string> GamepadsIds
{

View file

@ -4,6 +4,7 @@ using System;
using System.Collections.Generic;
using System.Numerics;
using System.Runtime.CompilerServices;
using System.Threading;
using static SDL2.SDL;
using ConfigKey = Ryujinx.Common.Configuration.Hid.Key;
@ -17,7 +18,7 @@ namespace Ryujinx.Input.SDL2
public bool IsValid => To is not GamepadButtonInputId.Unbound && From is not Key.Unbound;
}
private readonly object _userMappingLock = new();
private readonly Lock _userMappingLock = new();
#pragma warning disable IDE0052 // Remove unread private member
private readonly SDL2KeyboardDriver _driver;