mirror of
https://github.com/ChrisTitusTech/winutil.git
synced 2025-07-01 10:32:35 -05:00
Add Taskbaritem indication
This commit is contained in:
@ -2,6 +2,7 @@ function Invoke-WPFUpdatesScan {
|
||||
|
||||
|
||||
Invoke-WPFRunspace -DebugPreference $DebugPreference -ScriptBlock {
|
||||
$sync.form.Dispatcher.Invoke([action]{ Set-WinUtilTaskbaritem -state "Indeterminate" -value 0.01 -overlay "logo" })
|
||||
# Check if the PSWindowsUpdate module is installed
|
||||
if (-not (Get-Module -ListAvailable -Name PSWindowsUpdate)) {
|
||||
try {
|
||||
@ -51,8 +52,10 @@ function Invoke-WPFUpdatesScan {
|
||||
$sync["WPFUpdatesList"].Columns[0].Visibility = "Collapsed"
|
||||
}
|
||||
})
|
||||
$sync.form.Dispatcher.Invoke([action]{ Set-WinUtilTaskbaritem -state "None" -overlay "checkmark" })
|
||||
} catch {
|
||||
Write-Error "Error scanning for updates: $_"
|
||||
$sync.form.Dispatcher.Invoke([action]{ Set-WinUtilTaskbaritem -state "Error" -overlay "warning" })
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user