mirror of
https://github.com/ChrisTitusTech/winutil.git
synced 2025-01-18 10:47:44 -06:00
dd70526731
* Added Applications AFFiNE: Open source Notion alternative with selfhostable option for syncing. Wazuh Agent: Adgent for open-source security monitoring platform * Change layout of toggles Change the layout of the toggles to first show toggles and then the content (text). - testet, works * added snap related toggles - disable snapping entirely (requires relogin of windows user) - disable suggestion to snap other windows next to the snapped window -tested * Layouted Checkboxes, redesigned Toggles & renamed RDCMan - Removed text inside toggle as it can be confusing because it sais "enable" while enabled and "disable" if disabled. The coloring should be enough to know in what state that setting is. - without the text i could make it a little bit smaller while still letting it look good. - Renamed "Remote Desktop Connection Manager (RDCMan)" to "RDCMan" because that name is shorter and also mostly used by the linked site. - layouted checkboxes so they are not more left than the title and look tidy. - tested * Disable Acrobat auto-updates - added script & undoscript to disable automatic downloads & installation of acrobat reader. The user gets a notified if there is an update available. I put some info to that inside the code * edited AFFiNE description * Tweak Adobe Debloater -disable Adobe Desktop Service by getting ownership and renaming it. - added AGMService service - disable AGMService and AGSService entirely * Block Adobe Network, Debloat Adobe & Compile - fixes order of tweaks to always run "WPFTweaksRestorePoint" first. Before it was only the case because if was one of the first letter0s of the alphabet - Fixed some stuff at Debloat Adobe & added Adobe Reader update stopper & "deactivated" Adobe Desktop Service. - Added Blocking of Adobe Servers (as of your suggestion) to it's own Tweak. - ran compile for testing & showing * undo compilation * added Note to AcrobatUpdates Management in Tweak "Debloat Adobe" * Fix Right Click Method to use accurate names * fixed my mistake in README --------- Co-authored-by: Chris Titus <contact@christitus.com>
120 lines
3.8 KiB
PowerShell
120 lines
3.8 KiB
PowerShell
Function Get-WinUtilToggleStatus {
|
|
<#
|
|
|
|
.SYNOPSIS
|
|
Pulls the registry keys for the given toggle switch and checks whether the toggle should be checked or unchecked
|
|
|
|
.PARAMETER ToggleSwitch
|
|
The name of the toggle to check
|
|
|
|
.OUTPUTS
|
|
Boolean to set the toggle's status to
|
|
|
|
#>
|
|
|
|
Param($ToggleSwitch)
|
|
if($ToggleSwitch -eq "WPFToggleDarkMode"){
|
|
$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
|
|
}
|
|
}
|
|
if($ToggleSwitch -eq "WPFToggleBingSearch"){
|
|
$bingsearch = (Get-ItemProperty -path 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Search').BingSearchEnabled
|
|
if($bingsearch -eq 0){
|
|
return $false
|
|
}
|
|
else{
|
|
return $true
|
|
}
|
|
}
|
|
if($ToggleSwitch -eq "WPFToggleNumLock"){
|
|
$numlockvalue = (Get-ItemProperty -path 'HKCU:\Control Panel\Keyboard').InitialKeyboardIndicators
|
|
if($numlockvalue -eq 2){
|
|
return $true
|
|
}
|
|
else{
|
|
return $false
|
|
}
|
|
}
|
|
if($ToggleSwitch -eq "WPFToggleVerboseLogon"){
|
|
$VerboseStatusvalue = (Get-ItemProperty -path 'HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System').VerboseStatus
|
|
if($VerboseStatusvalue -eq 1){
|
|
return $true
|
|
}
|
|
else{
|
|
return $false
|
|
}
|
|
}
|
|
if($ToggleSwitch -eq "WPFToggleShowExt"){
|
|
$hideextvalue = (Get-ItemProperty -path 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced').HideFileExt
|
|
if($hideextvalue -eq 0){
|
|
return $true
|
|
}
|
|
else{
|
|
return $false
|
|
}
|
|
}
|
|
if($ToggleSwitch -eq "WPFToggleSnapWindow"){
|
|
$hidesnap = (Get-ItemProperty -path 'HKCU:\Control Panel\Desktop').WindowArrangementActive
|
|
if($hidesnap -eq 0){
|
|
return $false
|
|
}
|
|
else{
|
|
return $true
|
|
}
|
|
}
|
|
if($ToggleSwitch -eq "WPFToggleSnapFlyout"){
|
|
$hidesnap = (Get-ItemProperty -path 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced').EnableSnapAssistFlyout
|
|
if($hidesnap -eq 0){
|
|
return $false
|
|
}
|
|
else{
|
|
return $true
|
|
}
|
|
}
|
|
if($ToggleSwitch -eq "WPFToggleSnapSuggestion"){
|
|
$hidesnap = (Get-ItemProperty -path 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced').SnapAssist
|
|
if($hidesnap -eq 0){
|
|
return $false
|
|
}
|
|
else{
|
|
return $true
|
|
}
|
|
}
|
|
if($ToggleSwitch -eq "WPFToggleMouseAcceleration"){
|
|
$MouseSpeed = (Get-ItemProperty -path 'HKCU:\Control Panel\Mouse').MouseSpeed
|
|
$MouseThreshold1 = (Get-ItemProperty -path 'HKCU:\Control Panel\Mouse').MouseThreshold1
|
|
$MouseThreshold2 = (Get-ItemProperty -path 'HKCU:\Control Panel\Mouse').MouseThreshold2
|
|
|
|
if($MouseSpeed -eq 1 -and $MouseThreshold1 -eq 6 -and $MouseThreshold2 -eq 10){
|
|
return $true
|
|
}
|
|
else{
|
|
return $false
|
|
}
|
|
}
|
|
if ($ToggleSwitch -eq "WPFToggleStickyKeys") {
|
|
$StickyKeys = (Get-ItemProperty -path 'HKCU:\Control Panel\Accessibility\StickyKeys').Flags
|
|
if($StickyKeys -eq 58){
|
|
return $false
|
|
}
|
|
else{
|
|
return $true
|
|
}
|
|
}
|
|
if ($ToggleSwitch -eq "WPFToggleTaskbarWidgets") {
|
|
$TaskbarWidgets = (Get-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced").TaskBarDa
|
|
if($TaskbarWidgets -eq 0) {
|
|
return $false
|
|
}
|
|
else{
|
|
return $true
|
|
}
|
|
}
|
|
}
|