1
0

Refactored class name

This commit is contained in:
Benjamin Höglinger-Stelzer 2018-11-12 02:17:32 +01:00
parent 43216b4d92
commit ae6eee2a5b
2 changed files with 13 additions and 13 deletions

View File

@ -45,13 +45,13 @@ namespace DerpingDrivers
/// <summary>
/// Gets Boot mode (Legacy BIOS, UEFI).
/// </summary>
public string BootMode => UEFIHelper.IsRunningInUEFIMode ? "UEFI" : "Legacy BIOS";
public string BootMode => UefiHelper.IsRunningInUefiMode ? "UEFI" : "Legacy BIOS";
/// <summary>
/// Gets Secure Boot status.
/// </summary>
public string SecureBootEnabled => UEFIHelper.IsRunningInUEFIMode
? (UEFIHelper.IsSecureBootEnabled ? "Enabled" : "Disabled")
public string SecureBootEnabled => UefiHelper.IsRunningInUefiMode
? (UefiHelper.IsSecureBootEnabled ? "Enabled" : "Disabled")
: "Not available";
/// <summary>
@ -104,23 +104,23 @@ namespace DerpingDrivers
if (OsVersionInfo.IsWindows10
&& OsVersionInfo.OsBits == OsVersionInfo.SoftwareArchitecture.Bit64)
{
if (UEFIHelper.IsRunningInUEFIMode
&& !UEFIHelper.IsSecureBootEnabled
if (UefiHelper.IsRunningInUefiMode
&& !UefiHelper.IsSecureBootEnabled
&& !OsUpgradeDetection.IsGrandfathered)
return Encoding.UTF8.GetString(Properties.Resources.win10_x64_uefi_clean);
if (UEFIHelper.IsRunningInUEFIMode
&& UEFIHelper.IsSecureBootEnabled
if (UefiHelper.IsRunningInUefiMode
&& UefiHelper.IsSecureBootEnabled
&& !OsUpgradeDetection.IsGrandfathered)
return Encoding.UTF8.GetString(Properties.Resources.win10_x64_uefi_secure_clean);
if (UEFIHelper.IsRunningInUEFIMode
&& UEFIHelper.IsSecureBootEnabled
if (UefiHelper.IsRunningInUefiMode
&& UefiHelper.IsSecureBootEnabled
&& OsUpgradeDetection.IsGrandfathered)
return Encoding.UTF8.GetString(Properties.Resources.win10_x64_uefi_secure_upgraded);
if (UEFIHelper.IsRunningInUEFIMode
&& !UEFIHelper.IsSecureBootEnabled
if (UefiHelper.IsRunningInUefiMode
&& !UefiHelper.IsSecureBootEnabled
&& OsUpgradeDetection.IsGrandfathered)
return Encoding.UTF8.GetString(Properties.Resources.win10_x64_uefi_upgraded);
}

View File

@ -4,7 +4,7 @@ using Microsoft.Win32;
namespace DerpingDrivers.Util
{
public class UEFIHelper
public class UefiHelper
{
/// <summary>
/// Checks if Secure Boot is enabled.
@ -26,7 +26,7 @@ namespace DerpingDrivers.Util
/// Checks if the current system is running in UEFI or Legacy BIOS mode.
/// </summary>
/// <remarks>https://theroadtodelphi.com/2013/02/19/how-distinguish-when-windows-was-installed-in-legacy-bios-or-uefi-mode-using-delphi/</remarks>
public static bool IsRunningInUEFIMode
public static bool IsRunningInUefiMode
{
get
{