mirror of
https://github.com/ChrisTitusTech/winutil.git
synced 2024-11-14 22:55:52 -06:00
16 lines
526 B
PowerShell
16 lines
526 B
PowerShell
|
Function Get-WinUtilDarkMode {
|
||
|
<#
|
||
|
|
||
|
.DESCRIPTION
|
||
|
Meant to pull the registry keys responsible for Dark Mode and returns true or false
|
||
|
|
||
|
#>
|
||
|
$app = (Get-ItemProperty -path 'HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Themes\Personalize').AppsUseLightTheme
|
||
|
$system = (Get-ItemProperty -path 'HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Themes\Personalize').SystemUsesLightTheme
|
||
|
if($app -eq 0 -and $system -eq 0){
|
||
|
return $true
|
||
|
}
|
||
|
else{
|
||
|
return $false
|
||
|
}
|
||
|
}
|