mirror of
https://github.com/ChrisTitusTech/winutil.git
synced 2024-11-14 22:55:52 -06:00
Merge branch 'ChrisTitusTech:main' into main
This commit is contained in:
commit
0b196a849e
4
.github/release-drafter.yml
vendored
4
.github/release-drafter.yml
vendored
@ -19,10 +19,6 @@ template: |
|
|||||||
|
|
||||||
$CHANGES
|
$CHANGES
|
||||||
|
|
||||||
## Contributors
|
|
||||||
|
|
||||||
$CONTRIBUTORS
|
|
||||||
|
|
||||||
change-title-escapes: '\<*_&"'''
|
change-title-escapes: '\<*_&"'''
|
||||||
autolabeler:
|
autolabeler:
|
||||||
- label: 'documentation'
|
- label: 'documentation'
|
||||||
|
@ -1,169 +1,169 @@
|
|||||||
{
|
{
|
||||||
"_default": {
|
"_default": {
|
||||||
"CustomDialogFontSize": "12",
|
"CustomDialogFontSize": "12",
|
||||||
"CustomDialogFontSizeHeader": "14",
|
"CustomDialogFontSizeHeader": "14",
|
||||||
"CustomDialogIconSize": "25",
|
"CustomDialogIconSize": "25",
|
||||||
"CustomDialogWidth": "400",
|
"CustomDialogWidth": "400",
|
||||||
"CustomDialogHeight": "200",
|
"CustomDialogHeight": "200",
|
||||||
|
|
||||||
"FontSize": "12",
|
"FontSize": "12",
|
||||||
"FontFamily": "Arial",
|
"FontFamily": "Arial",
|
||||||
"FontSizeHeading": "16",
|
"FontSizeHeading": "16",
|
||||||
"HeaderFontFamily": "Consolas, Monaco",
|
"HeaderFontFamily": "Consolas, Monaco",
|
||||||
|
|
||||||
"CheckBoxBulletDecoratorSize": "14",
|
"CheckBoxBulletDecoratorSize": "14",
|
||||||
"CheckBoxMargin": "15,0,0,2",
|
"CheckBoxMargin": "15,0,0,2",
|
||||||
|
|
||||||
"TabContentMargin": "5",
|
"TabContentMargin": "5",
|
||||||
"TabButtonFontSize": "14",
|
"TabButtonFontSize": "14",
|
||||||
"TabButtonWidth": "100",
|
"TabButtonWidth": "100",
|
||||||
"TabButtonHeight": "25",
|
"TabButtonHeight": "25",
|
||||||
"TabRowHeightInPixels": "50",
|
"TabRowHeightInPixels": "50",
|
||||||
"IconFontSize": "14",
|
"IconFontSize": "14",
|
||||||
"IconButtonSize": "35",
|
"IconButtonSize": "35",
|
||||||
"SettingsIconFontSize": "18",
|
"SettingsIconFontSize": "18",
|
||||||
"CloseIconFontSize": "18",
|
"CloseIconFontSize": "18",
|
||||||
|
|
||||||
"MicroWinLogoSize": "10",
|
"MicroWinLogoSize": "10",
|
||||||
"MicrowinCheckBoxMargin": "-10,5,0,0",
|
"MicrowinCheckBoxMargin": "-10,5,0,0",
|
||||||
|
|
||||||
"ProgressBarForegroundColor": "#2e77ff",
|
"ProgressBarForegroundColor": "#2e77ff",
|
||||||
"ProgressBarBackgroundColor": "Transparent",
|
"ProgressBarBackgroundColor": "Transparent",
|
||||||
"ProgressBarTextColor": "#232629",
|
"ProgressBarTextColor": "#232629",
|
||||||
|
|
||||||
"ComboBoxBackgroundColor": "#F7F7F7",
|
"ComboBoxBackgroundColor": "#F7F7F7",
|
||||||
"LabelboxForegroundColor": "#232629",
|
"LabelboxForegroundColor": "#232629",
|
||||||
"MainForegroundColor": "#232629",
|
"MainForegroundColor": "#232629",
|
||||||
"MainBackgroundColor": "#F7F7F7",
|
"MainBackgroundColor": "#F7F7F7",
|
||||||
"LabelBackgroundColor": "#F7F7F7",
|
"LabelBackgroundColor": "#F7F7F7",
|
||||||
"LinkForegroundColor": "#232629",
|
"LinkForegroundColor": "#232629",
|
||||||
"LinkHoverForegroundColor": "#232629",
|
"LinkHoverForegroundColor": "#232629",
|
||||||
"GroupBorderBackgroundColor": "#232629",
|
"GroupBorderBackgroundColor": "#232629",
|
||||||
"ComboBoxForegroundColor": "#232629",
|
"ComboBoxForegroundColor": "#232629",
|
||||||
|
|
||||||
"ButtonFontSize": "12",
|
"ButtonFontSize": "12",
|
||||||
"ButtonFontFamily": "Arial",
|
"ButtonFontFamily": "Arial",
|
||||||
"ButtonWidth": "200",
|
"ButtonWidth": "200",
|
||||||
"ButtonHeight": "25",
|
"ButtonHeight": "25",
|
||||||
"ConfigTabButtonFontSize": "16",
|
"ConfigTabButtonFontSize": "16",
|
||||||
|
|
||||||
"SearchBarWidth": "200",
|
"SearchBarWidth": "200",
|
||||||
"SearchBarHeight": "25",
|
"SearchBarHeight": "25",
|
||||||
"SearchBarTextBoxFontSize": "12",
|
"SearchBarTextBoxFontSize": "12",
|
||||||
"SearchBarClearButtonFontSize": "14",
|
"SearchBarClearButtonFontSize": "14",
|
||||||
|
|
||||||
"ButtonInstallBackgroundColor": "#F7F7F7",
|
"ButtonInstallBackgroundColor": "#F7F7F7",
|
||||||
"ButtonTweaksBackgroundColor": "#F7F7F7",
|
"ButtonTweaksBackgroundColor": "#F7F7F7",
|
||||||
"ButtonConfigBackgroundColor": "#F7F7F7",
|
"ButtonConfigBackgroundColor": "#F7F7F7",
|
||||||
"ButtonUpdatesBackgroundColor": "#F7F7F7",
|
"ButtonUpdatesBackgroundColor": "#F7F7F7",
|
||||||
"ButtonInstallForegroundColor": "#232629",
|
"ButtonInstallForegroundColor": "#232629",
|
||||||
"ButtonTweaksForegroundColor": "#232629",
|
"ButtonTweaksForegroundColor": "#232629",
|
||||||
"ButtonConfigForegroundColor": "#232629",
|
"ButtonConfigForegroundColor": "#232629",
|
||||||
"ButtonUpdatesForegroundColor": "#232629",
|
"ButtonUpdatesForegroundColor": "#232629",
|
||||||
"ButtonBackgroundColor": "#F5F5F5",
|
"ButtonBackgroundColor": "#F5F5F5",
|
||||||
"ButtonBackgroundPressedColor": "#1A1A1A",
|
"ButtonBackgroundPressedColor": "#1A1A1A",
|
||||||
"CheckboxMouseOverColor": "#999999",
|
"CheckboxMouseOverColor": "#999999",
|
||||||
"ButtonBackgroundMouseoverColor": "#C2C2C2",
|
"ButtonBackgroundMouseoverColor": "#C2C2C2",
|
||||||
"ButtonBackgroundSelectedColor": "#F0F0F0",
|
"ButtonBackgroundSelectedColor": "#F0F0F0",
|
||||||
"ButtonForegroundColor": "#232629",
|
"ButtonForegroundColor": "#232629",
|
||||||
"ToggleButtonOnColor": "#2e77ff",
|
"ToggleButtonOnColor": "#2e77ff",
|
||||||
|
|
||||||
"ButtonBorderThickness": "1",
|
"ButtonBorderThickness": "1",
|
||||||
"ButtonMargin": "1",
|
"ButtonMargin": "1",
|
||||||
"ButtonCornerRadius": "2",
|
"ButtonCornerRadius": "2",
|
||||||
"BorderColor": "#232629",
|
"BorderColor": "#232629",
|
||||||
"BorderOpacity": "0.2",
|
"BorderOpacity": "0.2",
|
||||||
"ShadowPulse": "Forever"
|
"ShadowPulse": "Forever"
|
||||||
},
|
},
|
||||||
"Classic": {
|
"Classic": {
|
||||||
"ComboBoxBackgroundColor": "#F7F7F7",
|
"ComboBoxBackgroundColor": "#F7F7F7",
|
||||||
"LabelboxForegroundColor": "#232629",
|
"LabelboxForegroundColor": "#232629",
|
||||||
"MainForegroundColor": "#232629",
|
"MainForegroundColor": "#232629",
|
||||||
"MainBackgroundColor": "#F7F7F7",
|
"MainBackgroundColor": "#F7F7F7",
|
||||||
"LabelBackgroundColor": "#F7F7F7",
|
"LabelBackgroundColor": "#F7F7F7",
|
||||||
"LinkForegroundColor": "#232629",
|
"LinkForegroundColor": "#232629",
|
||||||
"LinkHoverForegroundColor": "#232629",
|
"LinkHoverForegroundColor": "#232629",
|
||||||
"GroupBorderBackgroundColor": "#232629",
|
"GroupBorderBackgroundColor": "#232629",
|
||||||
"ComboBoxForegroundColor": "#232629",
|
"ComboBoxForegroundColor": "#232629",
|
||||||
|
|
||||||
"ButtonInstallBackgroundColor": "#F7F7F7",
|
"ButtonInstallBackgroundColor": "#F7F7F7",
|
||||||
"ButtonTweaksBackgroundColor": "#F7F7F7",
|
"ButtonTweaksBackgroundColor": "#F7F7F7",
|
||||||
"ButtonConfigBackgroundColor": "#F7F7F7",
|
"ButtonConfigBackgroundColor": "#F7F7F7",
|
||||||
"ButtonUpdatesBackgroundColor": "#F7F7F7",
|
"ButtonUpdatesBackgroundColor": "#F7F7F7",
|
||||||
"ButtonInstallForegroundColor": "#232629",
|
"ButtonInstallForegroundColor": "#232629",
|
||||||
"ButtonTweaksForegroundColor": "#232629",
|
"ButtonTweaksForegroundColor": "#232629",
|
||||||
"ButtonConfigForegroundColor": "#232629",
|
"ButtonConfigForegroundColor": "#232629",
|
||||||
"ButtonUpdatesForegroundColor": "#232629",
|
"ButtonUpdatesForegroundColor": "#232629",
|
||||||
"ButtonBackgroundColor": "#F5F5F5",
|
"ButtonBackgroundColor": "#F5F5F5",
|
||||||
"ButtonBackgroundPressedColor": "#1A1A1A",
|
"ButtonBackgroundPressedColor": "#1A1A1A",
|
||||||
"CheckboxMouseOverColor": "#999999",
|
"CheckboxMouseOverColor": "#999999",
|
||||||
"ButtonBackgroundMouseoverColor": "#C2C2C2",
|
"ButtonBackgroundMouseoverColor": "#C2C2C2",
|
||||||
"ButtonBackgroundSelectedColor": "#F0F0F0",
|
"ButtonBackgroundSelectedColor": "#F0F0F0",
|
||||||
"ButtonForegroundColor": "#232629",
|
"ButtonForegroundColor": "#232629",
|
||||||
"ToggleButtonOnColor": "#2e77ff"
|
"ToggleButtonOnColor": "#2e77ff"
|
||||||
},
|
},
|
||||||
"Matrix": {
|
"Matrix": {
|
||||||
"ComboBoxBackgroundColor": "#232629",
|
"ComboBoxBackgroundColor": "#232629",
|
||||||
"LabelboxForegroundColor": "#81a1c1",
|
"LabelboxForegroundColor": "#f7f7f7",
|
||||||
"MainForegroundColor": "#F7F7F7",
|
"MainForegroundColor": "#F7F7F7",
|
||||||
"MainBackgroundColor": "#232629",
|
"MainBackgroundColor": "#232629",
|
||||||
"LabelBackgroundColor": "#232629",
|
"LabelBackgroundColor": "#232629",
|
||||||
"LinkForegroundColor": "#add8e6",
|
"LinkForegroundColor": "#add8e6",
|
||||||
"LinkHoverForegroundColor": "#F7F7F7",
|
"LinkHoverForegroundColor": "#F7F7F7",
|
||||||
"ComboBoxForegroundColor": "#81a1c1",
|
"ComboBoxForegroundColor": "#81a1c1",
|
||||||
|
|
||||||
"ProgressBarForegroundColor": "#222222",
|
"ProgressBarForegroundColor": "#222222",
|
||||||
"ProgressBarBackgroundColor": "Transparent",
|
"ProgressBarBackgroundColor": "Transparent",
|
||||||
"ProgressBarTextColor": "#cccccc",
|
"ProgressBarTextColor": "#cccccc",
|
||||||
|
|
||||||
"ButtonInstallBackgroundColor": "#222222",
|
"ButtonInstallBackgroundColor": "#222222",
|
||||||
"ButtonTweaksBackgroundColor": "#333333",
|
"ButtonTweaksBackgroundColor": "#333333",
|
||||||
"ButtonConfigBackgroundColor": "#444444",
|
"ButtonConfigBackgroundColor": "#444444",
|
||||||
"ButtonUpdatesBackgroundColor": "#555555",
|
"ButtonUpdatesBackgroundColor": "#555555",
|
||||||
"ButtonInstallForegroundColor": "#F7F7F7",
|
"ButtonInstallForegroundColor": "#F7F7F7",
|
||||||
"ButtonTweaksForegroundColor": "#F7F7F7",
|
"ButtonTweaksForegroundColor": "#F7F7F7",
|
||||||
"ButtonConfigForegroundColor": "#F7F7F7",
|
"ButtonConfigForegroundColor": "#F7F7F7",
|
||||||
"ButtonUpdatesForegroundColor": "#F7F7F7",
|
"ButtonUpdatesForegroundColor": "#F7F7F7",
|
||||||
"ButtonBackgroundColor": "#1E3747",
|
"ButtonBackgroundColor": "#1E3747",
|
||||||
"ButtonBackgroundPressedColor": "#F7F7F7",
|
"ButtonBackgroundPressedColor": "#F7F7F7",
|
||||||
"ButtonBackgroundMouseoverColor": "#3B4252",
|
"ButtonBackgroundMouseoverColor": "#3B4252",
|
||||||
"ButtonBackgroundSelectedColor": "#5E81AC",
|
"ButtonBackgroundSelectedColor": "#5E81AC",
|
||||||
"ButtonForegroundColor": "#F7F7F7",
|
"ButtonForegroundColor": "#F7F7F7",
|
||||||
"ToggleButtonOnColor": "#2e77ff",
|
"ToggleButtonOnColor": "#2e77ff",
|
||||||
|
|
||||||
"BorderColor": "#0060CC",
|
"BorderColor": "#0060CC",
|
||||||
"BorderOpacity": "0.2",
|
"BorderOpacity": "0.2",
|
||||||
"ShadowPulse": "0:0:3"
|
"ShadowPulse": "0:0:3"
|
||||||
},
|
},
|
||||||
"Dark": {
|
"Dark": {
|
||||||
"ComboBoxBackgroundColor": "#232629",
|
"ComboBoxBackgroundColor": "#1e3747",
|
||||||
"LabelboxForegroundColor": "#81a1c1",
|
"LabelboxForegroundColor": "#0567ff",
|
||||||
"MainForegroundColor": "#F7F7F7",
|
"MainForegroundColor": "#F7F7F7",
|
||||||
"MainBackgroundColor": "#232629",
|
"MainBackgroundColor": "#121212",
|
||||||
"LabelBackgroundColor": "#232629",
|
"LabelBackgroundColor": "#121212",
|
||||||
"LinkForegroundColor": "#add8e6",
|
"LinkForegroundColor": "#add8e6",
|
||||||
"LinkHoverForegroundColor": "#F7F7F7",
|
"LinkHoverForegroundColor": "#F7F7F7",
|
||||||
"ComboBoxForegroundColor": "#81a1c1",
|
"ComboBoxForegroundColor": "#f7f7f7",
|
||||||
|
|
||||||
"ProgressBarForegroundColor": "#222222",
|
"ProgressBarForegroundColor": "#222222",
|
||||||
"ProgressBarBackgroundColor": "Transparent",
|
"ProgressBarBackgroundColor": "Transparent",
|
||||||
"ProgressBarTextColor": "#cccccc",
|
"ProgressBarTextColor": "#cccccc",
|
||||||
|
|
||||||
"ButtonInstallBackgroundColor": "#222222",
|
"ButtonInstallBackgroundColor": "#222222",
|
||||||
"ButtonTweaksBackgroundColor": "#333333",
|
"ButtonTweaksBackgroundColor": "#333333",
|
||||||
"ButtonConfigBackgroundColor": "#444444",
|
"ButtonConfigBackgroundColor": "#444444",
|
||||||
"ButtonUpdatesBackgroundColor": "#555555",
|
"ButtonUpdatesBackgroundColor": "#555555",
|
||||||
"ButtonInstallForegroundColor": "#F7F7F7",
|
"ButtonInstallForegroundColor": "#F7F7F7",
|
||||||
"ButtonTweaksForegroundColor": "#F7F7F7",
|
"ButtonTweaksForegroundColor": "#F7F7F7",
|
||||||
"ButtonConfigForegroundColor": "#F7F7F7",
|
"ButtonConfigForegroundColor": "#F7F7F7",
|
||||||
"ButtonUpdatesForegroundColor": "#F7F7F7",
|
"ButtonUpdatesForegroundColor": "#F7F7F7",
|
||||||
"ButtonBackgroundColor": "#1E3747",
|
"ButtonBackgroundColor": "#1E3747",
|
||||||
"ButtonBackgroundPressedColor": "#00CFFF",
|
"ButtonBackgroundPressedColor": "#00CFFF",
|
||||||
"ButtonBackgroundMouseoverColor": "#5E81AC",
|
"ButtonBackgroundMouseoverColor": "#5E81AC",
|
||||||
"ButtonBackgroundSelectedColor": "#5E81AC",
|
"ButtonBackgroundSelectedColor": "#5E81AC",
|
||||||
"ButtonForegroundColor": "#F7F7F7",
|
"ButtonForegroundColor": "#F7F7F7",
|
||||||
"ToggleButtonOnColor": "#2e77ff",
|
"ToggleButtonOnColor": "#2e77ff",
|
||||||
|
|
||||||
"BorderColor": "#0b1215"
|
"BorderColor": "#2F373D"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -13,10 +13,11 @@ function Install-WinUtilChoco {
|
|||||||
if((Test-WinUtilPackageManager -choco) -eq "installed") {
|
if((Test-WinUtilPackageManager -choco) -eq "installed") {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
# Install logic taken from https://chocolatey.org/install#individual
|
||||||
Write-Host "Seems Chocolatey is not installed, installing now."
|
Write-Host "Seems Chocolatey is not installed, installing now."
|
||||||
Start-Process -FilePath "powershell" -ArgumentList "Set-ExecutionPolicy Bypass -Scope Process -Force; Invoke-Expression ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1')) -ErrorAction Stop" -Wait -NoNewWindow
|
Set-ExecutionPolicy Bypass -Scope Process -Force;
|
||||||
Start-Process -FilePath "powershell" -ArgumentList "choco feature enable -n allowGlobalConfirmation" -Wait -NoNewWindow
|
[System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072;
|
||||||
|
Invoke-Expression ((New-Object System.Net.WebClient).DownloadString('https://community.chocolatey.org/install.ps1'))
|
||||||
|
|
||||||
} catch {
|
} catch {
|
||||||
Write-Host "===========================================" -Foregroundcolor Red
|
Write-Host "===========================================" -Foregroundcolor Red
|
||||||
|
@ -20,7 +20,7 @@ function Invoke-WPFInstall {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
$ChocoPreference = $($sync.WPFpreferChocolatey.IsChecked)
|
$ChocoPreference = $($sync.WPFpreferChocolatey.IsChecked)
|
||||||
Invoke-WPFRunspace -ArgumentList $PackagesToInstall,$ChocoPreference -DebugPreference $DebugPreference -ScriptBlock {
|
$installHandle = Invoke-WPFRunspace -ParameterList @(("PackagesToInstall", $PackagesToInstall),("ChocoPreference", $ChocoPreference)) -DebugPreference $DebugPreference -ScriptBlock {
|
||||||
param($PackagesToInstall, $ChocoPreference, $DebugPreference)
|
param($PackagesToInstall, $ChocoPreference, $DebugPreference)
|
||||||
if ($PackagesToInstall.count -eq 1) {
|
if ($PackagesToInstall.count -eq 1) {
|
||||||
$sync.form.Dispatcher.Invoke([action]{ Set-WinUtilTaskbaritem -state "Indeterminate" -value 0.01 -overlay "logo" })
|
$sync.form.Dispatcher.Invoke([action]{ Set-WinUtilTaskbaritem -state "Indeterminate" -value 0.01 -overlay "logo" })
|
||||||
|
@ -11,17 +11,23 @@ function Invoke-WPFRunspace {
|
|||||||
.PARAMETER ArgumentList
|
.PARAMETER ArgumentList
|
||||||
A list of arguments to pass to the runspace
|
A list of arguments to pass to the runspace
|
||||||
|
|
||||||
|
.PARAMETER ParameterList
|
||||||
|
A list of named parameters that should be provided.
|
||||||
.EXAMPLE
|
.EXAMPLE
|
||||||
Invoke-WPFRunspace `
|
Invoke-WPFRunspace `
|
||||||
-ScriptBlock $sync.ScriptsInstallPrograms `
|
-ScriptBlock $sync.ScriptsInstallPrograms `
|
||||||
-ArgumentList "Installadvancedip,Installbitwarden" `
|
-ArgumentList "Installadvancedip,Installbitwarden" `
|
||||||
|
|
||||||
|
Invoke-WPFRunspace`
|
||||||
|
-ScriptBlock $sync.ScriptsInstallPrograms `
|
||||||
|
-ParameterList @(("PackagesToInstall", @("Installadvancedip,Installbitwarden")),("ChocoPreference", $true))
|
||||||
#>
|
#>
|
||||||
|
|
||||||
[CmdletBinding()]
|
[CmdletBinding()]
|
||||||
Param (
|
Param (
|
||||||
$ScriptBlock,
|
$ScriptBlock,
|
||||||
$ArgumentList,
|
$ArgumentList,
|
||||||
|
$ParameterList,
|
||||||
$DebugPreference
|
$DebugPreference
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -30,8 +36,10 @@ function Invoke-WPFRunspace {
|
|||||||
|
|
||||||
# Add Scriptblock and Arguments to runspace
|
# Add Scriptblock and Arguments to runspace
|
||||||
$script:powershell.AddScript($ScriptBlock)
|
$script:powershell.AddScript($ScriptBlock)
|
||||||
foreach ($Argument in $ArgumentList) {
|
$script:powershell.AddArgument($ArgumentList)
|
||||||
$script:powershell.AddArgument($Argument)
|
|
||||||
|
foreach ($parameter in $ParameterList) {
|
||||||
|
$script:powershell.AddParameter($parameter[0], $parameter[1])
|
||||||
}
|
}
|
||||||
$script:powershell.AddArgument($DebugPreference) # Pass DebugPreference to the script block
|
$script:powershell.AddArgument($DebugPreference) # Pass DebugPreference to the script block
|
||||||
$script:powershell.RunspacePool = $sync.runspace
|
$script:powershell.RunspacePool = $sync.runspace
|
||||||
@ -47,4 +55,6 @@ function Invoke-WPFRunspace {
|
|||||||
$sync.runspace.Close()
|
$sync.runspace.Close()
|
||||||
[System.GC]::Collect()
|
[System.GC]::Collect()
|
||||||
}
|
}
|
||||||
|
# Return the handle
|
||||||
|
return $handle
|
||||||
}
|
}
|
||||||
|
@ -30,7 +30,7 @@ function Invoke-WPFUnInstall {
|
|||||||
if($confirm -eq "No") {return}
|
if($confirm -eq "No") {return}
|
||||||
$ChocoPreference = $($sync.WPFpreferChocolatey.IsChecked)
|
$ChocoPreference = $($sync.WPFpreferChocolatey.IsChecked)
|
||||||
|
|
||||||
Invoke-WPFRunspace -ArgumentList $PackagesToInstall, $ChocoPreference -DebugPreference $DebugPreference -ScriptBlock {
|
Invoke-WPFRunspace -ArgumentList @(("PackagesToInstall", $PackagesToInstall),("ChocoPreference", $ChocoPreference)) -DebugPreference $DebugPreference -ScriptBlock {
|
||||||
param($PackagesToInstall, $ChocoPreference, $DebugPreference)
|
param($PackagesToInstall, $ChocoPreference, $DebugPreference)
|
||||||
if ($PackagesToInstall.count -eq 1) {
|
if ($PackagesToInstall.count -eq 1) {
|
||||||
$sync.form.Dispatcher.Invoke([action]{ Set-WinUtilTaskbaritem -state "Indeterminate" -value 0.01 -overlay "logo" })
|
$sync.form.Dispatcher.Invoke([action]{ Set-WinUtilTaskbaritem -state "Indeterminate" -value 0.01 -overlay "logo" })
|
||||||
|
@ -24,8 +24,12 @@ function Invoke-WPFtweaksbutton {
|
|||||||
|
|
||||||
Write-Debug "Number of tweaks to process: $($Tweaks.Count)"
|
Write-Debug "Number of tweaks to process: $($Tweaks.Count)"
|
||||||
|
|
||||||
Invoke-WPFRunspace -ArgumentList $Tweaks -DebugPreference $DebugPreference -ScriptBlock {
|
# The leading "," in the ParameterList is nessecary because we only provide one argument and powershell cannot be convinced that we want a nested loop with only one argument otherwise
|
||||||
param($Tweaks, $DebugPreference)
|
$tweaksHandle = Invoke-WPFRunspace -ParameterList @(,("tweaks",$tweaks)) -DebugPreference $DebugPreference -ScriptBlock {
|
||||||
|
param(
|
||||||
|
$tweaks,
|
||||||
|
$DebugPreference
|
||||||
|
)
|
||||||
Write-Debug "Inside Number of tweaks to process: $($Tweaks.Count)"
|
Write-Debug "Inside Number of tweaks to process: $($Tweaks.Count)"
|
||||||
|
|
||||||
$sync.ProcessRunning = $true
|
$sync.ProcessRunning = $true
|
||||||
@ -38,8 +42,9 @@ function Invoke-WPFtweaksbutton {
|
|||||||
# Execute other selected tweaks
|
# Execute other selected tweaks
|
||||||
|
|
||||||
for ($i = 0; $i -lt $Tweaks.Count; $i++) {
|
for ($i = 0; $i -lt $Tweaks.Count; $i++) {
|
||||||
Set-WinUtilProgressBar -Label "Applying $($tweaks[$i])" -Percent ($i / $Tweaks.Count * 100)
|
Set-WinUtilProgressBar -Label "Applying $($tweaks[$i])" -Percent ($i / $tweaks.Count * 100)
|
||||||
Invoke-WinUtilTweaks $tweaks[$i]$sync.form.Dispatcher.Invoke([action]{ Set-WinUtilTaskbaritem -value ($i/$Tweaks.Count) })
|
Invoke-WinUtilTweaks $tweaks[$i]
|
||||||
|
$sync.form.Dispatcher.Invoke([action]{ Set-WinUtilTaskbaritem -value ($i/$Tweaks.Count) })
|
||||||
}
|
}
|
||||||
Set-WinUtilProgressBar -Label "Tweaks finished" -Percent 100
|
Set-WinUtilProgressBar -Label "Tweaks finished" -Percent 100
|
||||||
$sync.ProcessRunning = $false
|
$sync.ProcessRunning = $false
|
||||||
|
@ -911,19 +911,19 @@
|
|||||||
<Border Grid.Row="0" Grid.Column="0" Style="{StaticResource BorderStyle}">
|
<Border Grid.Row="0" Grid.Column="0" Style="{StaticResource BorderStyle}">
|
||||||
<StackPanel Background="{MainBackgroundColor}" SnapsToDevicePixels="True">
|
<StackPanel Background="{MainBackgroundColor}" SnapsToDevicePixels="True">
|
||||||
<Button Name="WPFUpdatesdefault" FontSize="{ConfigTabButtonFontSize}" Height="Auto" Width="Auto" Content="Default (Out of Box) Settings" Margin="20,4,20,10" Padding="10"/>
|
<Button Name="WPFUpdatesdefault" FontSize="{ConfigTabButtonFontSize}" Height="Auto" Width="Auto" Content="Default (Out of Box) Settings" Margin="20,4,20,10" Padding="10"/>
|
||||||
<TextBlock Margin="20,0,20,0" Padding="10" TextWrapping="WrapWithOverflow" MaxWidth="300">This is the default settings that come with Windows. <LineBreak/><LineBreak/> No modifications are made and will remove any custom windows update settings.<LineBreak/><LineBreak/>Note: If you still encounter update errors, reset all updates in the config tab. That will restore ALL Microsoft Update Services from their servers and reinstall them to default settings.</TextBlock>
|
<TextBlock Foreground="{ComboBoxForegroundColor}" Margin="20,0,20,0" Padding="10" TextWrapping="WrapWithOverflow" MaxWidth="300">This is the default settings that come with Windows. <LineBreak/><LineBreak/> No modifications are made and will remove any custom windows update settings.<LineBreak/><LineBreak/>Note: If you still encounter update errors, reset all updates in the config tab. That will restore ALL Microsoft Update Services from their servers and reinstall them to default settings.</TextBlock>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</Border>
|
</Border>
|
||||||
<Border Grid.Row="0" Grid.Column="1" Style="{StaticResource BorderStyle}">
|
<Border Grid.Row="0" Grid.Column="1" Style="{StaticResource BorderStyle}">
|
||||||
<StackPanel Background="{MainBackgroundColor}" SnapsToDevicePixels="True">
|
<StackPanel Background="{MainBackgroundColor}" SnapsToDevicePixels="True">
|
||||||
<Button Name="WPFUpdatessecurity" FontSize="{ConfigTabButtonFontSize}" Height="Auto" Width="Auto" Content="Security (Recommended) Settings" Margin="20,4,20,10" Padding="10"/>
|
<Button Name="WPFUpdatessecurity" FontSize="{ConfigTabButtonFontSize}" Height="Auto" Width="Auto" Content="Security (Recommended) Settings" Margin="20,4,20,10" Padding="10"/>
|
||||||
<TextBlock Margin="20,0,20,0" Padding="10" TextWrapping="WrapWithOverflow" MaxWidth="300">This is my recommended setting I use on all computers.<LineBreak/><LineBreak/> It will delay feature updates by 2 years and will install security updates 4 days after release.<LineBreak/><LineBreak/>Feature Updates: Adds features and often bugs to systems when they are released. You want to delay these as long as possible.<LineBreak/><LineBreak/>Security Updates: Typically these are pressing security flaws that need to be patched quickly. You only want to delay these a couple of days just to see if they are safe and don't break other systems. You don't want to go without these for ANY extended periods of time.</TextBlock>
|
<TextBlock Foreground="{ComboBoxForegroundColor}" Margin="20,0,20,0" Padding="10" TextWrapping="WrapWithOverflow" MaxWidth="300">This is my recommended setting I use on all computers.<LineBreak/><LineBreak/> It will delay feature updates by 2 years and will install security updates 4 days after release.<LineBreak/><LineBreak/>Feature Updates: Adds features and often bugs to systems when they are released. You want to delay these as long as possible.<LineBreak/><LineBreak/>Security Updates: Typically these are pressing security flaws that need to be patched quickly. You only want to delay these a couple of days just to see if they are safe and don't break other systems. You don't want to go without these for ANY extended periods of time.</TextBlock>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</Border>
|
</Border>
|
||||||
<Border Grid.Row="0" Grid.Column="2" Style="{StaticResource BorderStyle}">
|
<Border Grid.Row="0" Grid.Column="2" Style="{StaticResource BorderStyle}">
|
||||||
<StackPanel Background="{MainBackgroundColor}" SnapsToDevicePixels="True">
|
<StackPanel Background="{MainBackgroundColor}" SnapsToDevicePixels="True">
|
||||||
<Button Name="WPFUpdatesdisable" FontSize="{ConfigTabButtonFontSize}" Height="Auto" Width="Auto" Content="Disable ALL Updates (NOT RECOMMENDED!)" Margin="20,4,20,10" Padding="10,10,10,10"/>
|
<Button Name="WPFUpdatesdisable" FontSize="{ConfigTabButtonFontSize}" Height="Auto" Width="Auto" Content="Disable ALL Updates (NOT RECOMMENDED!)" Margin="20,4,20,10" Padding="10,10,10,10"/>
|
||||||
<TextBlock Margin="20,0,20,0" Padding="10" TextWrapping="WrapWithOverflow" MaxWidth="300">This completely disables ALL Windows Updates and is NOT RECOMMENDED.<LineBreak/><LineBreak/> However, it can be suitable if you use your system for a select purpose and do not actively browse the internet. <LineBreak/><LineBreak/>Note: Your system will be easier to hack and infect without security updates.</TextBlock>
|
<TextBlock Foreground="{ComboBoxForegroundColor}" Margin="20,0,20,0" Padding="10" TextWrapping="WrapWithOverflow" MaxWidth="300">This completely disables ALL Windows Updates and is NOT RECOMMENDED.<LineBreak/><LineBreak/> However, it can be suitable if you use your system for a select purpose and do not actively browse the internet. <LineBreak/><LineBreak/>Note: Your system will be easier to hack and infect without security updates.</TextBlock>
|
||||||
<TextBlock Text=" " Margin="20,0,20,0" Padding="10" TextWrapping="WrapWithOverflow" MaxWidth="300"/>
|
<TextBlock Text=" " Margin="20,0,20,0" Padding="10" TextWrapping="WrapWithOverflow" MaxWidth="300"/>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</Border>
|
</Border>
|
||||||
|
Loading…
Reference in New Issue
Block a user