mirror of
https://git.ryujinx.app/ryubing/ryujinx.git
synced 2026-05-03 11:55:46 +00:00
Structural and Memory Safety Improvements, Analyzer Cleanup (ryubing/ryujinx!47)
See merge request ryubing/ryujinx!47
This commit is contained in:
@@ -2,7 +2,7 @@ using System.Runtime.InteropServices;
|
||||
|
||||
namespace Ryujinx.HLE.HOS.Applets
|
||||
{
|
||||
#pragma warning disable CS0649 // Field is never assigned to
|
||||
|
||||
[StructLayout(LayoutKind.Sequential, Pack = 1)]
|
||||
struct ControllerSupportArgHeader
|
||||
{
|
||||
@@ -14,5 +14,4 @@ namespace Ryujinx.HLE.HOS.Applets
|
||||
public byte EnableSingleMode;
|
||||
public byte EnableIdentificationColor;
|
||||
}
|
||||
#pragma warning restore CS0649
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
namespace Ryujinx.HLE.HOS.Applets
|
||||
{
|
||||
#pragma warning disable CS0649 // Field is never assigned to
|
||||
|
||||
struct ControllerSupportArgPrivate
|
||||
{
|
||||
public uint PrivateSize;
|
||||
@@ -12,5 +12,4 @@ namespace Ryujinx.HLE.HOS.Applets
|
||||
public uint NpadStyleSet;
|
||||
public uint NpadJoyHoldType;
|
||||
}
|
||||
#pragma warning restore CS0649
|
||||
}
|
||||
|
||||
@@ -4,7 +4,7 @@ using System.Runtime.InteropServices;
|
||||
|
||||
namespace Ryujinx.HLE.HOS.Applets
|
||||
{
|
||||
#pragma warning disable CS0649 // Field is never assigned to
|
||||
|
||||
// (8.0.0+ version)
|
||||
[StructLayout(LayoutKind.Sequential, Pack = 1)]
|
||||
struct ControllerSupportArgV7
|
||||
@@ -22,5 +22,4 @@ namespace Ryujinx.HLE.HOS.Applets
|
||||
public Span<byte> AsSpan() => MemoryMarshal.CreateSpan(ref element, 8 * 0x81);
|
||||
}
|
||||
}
|
||||
#pragma warning restore CS0649
|
||||
}
|
||||
|
||||
@@ -4,7 +4,7 @@ using System.Runtime.InteropServices;
|
||||
|
||||
namespace Ryujinx.HLE.HOS.Applets
|
||||
{
|
||||
#pragma warning disable CS0649 // Field is never assigned to
|
||||
|
||||
// (1.0.0+ version)
|
||||
[StructLayout(LayoutKind.Sequential, Pack = 1)]
|
||||
struct ControllerSupportArgVPre7
|
||||
@@ -22,5 +22,4 @@ namespace Ryujinx.HLE.HOS.Applets
|
||||
public Span<byte> AsSpan() => MemoryMarshal.CreateSpan(ref element, 4 * 0x81);
|
||||
}
|
||||
}
|
||||
#pragma warning restore CS0649
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@ using System.Runtime.InteropServices;
|
||||
|
||||
namespace Ryujinx.HLE.HOS.Applets
|
||||
{
|
||||
#pragma warning disable CS0649 // Field is never assigned to
|
||||
|
||||
[StructLayout(LayoutKind.Sequential, Pack = 1)]
|
||||
struct ControllerSupportResultInfo
|
||||
{
|
||||
@@ -12,5 +12,4 @@ namespace Ryujinx.HLE.HOS.Applets
|
||||
public uint SelectedId;
|
||||
public uint Result;
|
||||
}
|
||||
#pragma warning restore CS0649
|
||||
}
|
||||
|
||||
@@ -78,7 +78,7 @@ namespace Ryujinx.HLE.HOS.Applets.Error
|
||||
{
|
||||
return systemLanguage switch
|
||||
{
|
||||
#pragma warning disable IDE0055 // Disable formatting
|
||||
#pragma warning disable IDE0055 // Disable formatting
|
||||
SystemLanguage.Japanese => "ja",
|
||||
SystemLanguage.AmericanEnglish => "en-US",
|
||||
SystemLanguage.French => "fr",
|
||||
|
||||
@@ -12,9 +12,8 @@ namespace Ryujinx.HLE.HOS.Applets
|
||||
private readonly Horizon _system;
|
||||
|
||||
private AppletSession _normalSession;
|
||||
#pragma warning disable IDE0052 // Remove unread private member
|
||||
|
||||
private AppletSession _interactiveSession;
|
||||
#pragma warning restore IDE0052
|
||||
|
||||
public event EventHandler AppletStateChanged;
|
||||
|
||||
|
||||
@@ -43,11 +43,11 @@ namespace Ryujinx.HLE.HOS.Applets
|
||||
private SoftwareKeyboardConfig _keyboardForegroundConfig;
|
||||
|
||||
// Configuration for background (inline) mode.
|
||||
#pragma warning disable IDE0052 // Remove unread private member
|
||||
|
||||
private SoftwareKeyboardInitialize _keyboardBackgroundInitialize;
|
||||
private SoftwareKeyboardCustomizeDic _keyboardBackgroundDic;
|
||||
private SoftwareKeyboardDictSet _keyboardBackgroundDictSet;
|
||||
#pragma warning restore IDE0052
|
||||
|
||||
private SoftwareKeyboardUserWord[] _keyboardBackgroundUserWords;
|
||||
|
||||
private byte[] _transferMemory;
|
||||
|
||||
Reference in New Issue
Block a user