misc: Migrate usage of RuntimeInformation to OperatingSystem (#2901)
Very basic migration across the codebase.
This commit is contained in:
parent
7c9360d393
commit
f39fce8f54
17 changed files with 77 additions and 68 deletions
|
@ -2,9 +2,11 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.Versioning;
|
||||
|
||||
namespace Ryujinx.Memory
|
||||
{
|
||||
[SupportedOSPlatform("windows")]
|
||||
static class MemoryManagementWindows
|
||||
{
|
||||
private static readonly IntPtr InvalidHandleValue = new IntPtr(-1);
|
||||
|
@ -59,9 +61,7 @@ namespace Ryujinx.Memory
|
|||
|
||||
static MemoryManagementWindows()
|
||||
{
|
||||
Version version = Environment.OSVersion.Version;
|
||||
|
||||
UseWin10Placeholders = (version.Major == 10 && version.Build >= 17134) || version.Major > 10;
|
||||
UseWin10Placeholders = OperatingSystem.IsWindowsVersionAtLeast(10, 0, 17134);
|
||||
}
|
||||
|
||||
public static IntPtr Allocate(IntPtr size)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue