📄 nativestructs.cs
字号:
namespace Imps.Utils
{
using System;
using System.Runtime.InteropServices;
internal sealed class NativeStructs
{
[StructLayout(LayoutKind.Sequential, CharSet=CharSet.Unicode)]
internal struct OSVERSIONINFOEX
{
public uint dwOSVersionInfoSize;
public uint dwMajorVersion;
public uint dwMinorVersion;
public uint dwBuildNumber;
public uint dwPlatformId;
[MarshalAs(UnmanagedType.ByValTStr, SizeConst=0x80)]
public string szCSDVersion;
public ushort wServicePackMajor;
public ushort wServicePackMinor;
public ushort wSuiteMask;
public byte wProductType;
public byte wReserved;
public static int SizeOf
{
get
{
return Marshal.SizeOf(typeof(NativeStructs.OSVERSIONINFOEX));
}
}
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -