mirror of
https://github.com/ChrisTitusTech/winutil.git
synced 2025-01-16 09:50:36 -06:00
Compare commits
5 Commits
faae0e69cb
...
cd35c74896
Author | SHA1 | Date | |
---|---|---|---|
|
cd35c74896 | ||
|
0ff05828e1 | ||
|
05e2946363 | ||
|
1185d05bf1 | ||
|
a1e4d203ce |
@ -10,9 +10,7 @@ function Invoke-WinUtilFeatureInstall {
|
|||||||
$CheckBox
|
$CheckBox
|
||||||
)
|
)
|
||||||
|
|
||||||
# $sync.form.Dispatcher.Invoke([action]{ Set-WinUtilTaskbaritem -state "Normal" -value 1/$using:CheckBox.Count })
|
$x = 0
|
||||||
|
|
||||||
x = 0
|
|
||||||
|
|
||||||
$CheckBox | ForEach-Object {
|
$CheckBox | ForEach-Object {
|
||||||
if($sync.configs.feature.$psitem.feature){
|
if($sync.configs.feature.$psitem.feature){
|
||||||
|
@ -1,11 +1,13 @@
|
|||||||
|
function Set-WinUtilTaskbaritem {
|
||||||
<#
|
<#
|
||||||
|
|
||||||
.SYNOPSIS
|
.SYNOPSIS
|
||||||
Modifies the Taskbaritem of the WPF Form
|
Modifies the Taskbaritem of the WPF Form
|
||||||
|
|
||||||
.PARAMETER state & value
|
.PARAMETER state
|
||||||
Value can be between 0 and 1, 0 being no progress done yet and 1 being fully completed
|
|
||||||
State can be 'None' > No progress, 'Indeterminate' > Without value, 'Normal' > when using value, 'Error' > Red (when using value), 'Paused' > Yellow (when using value)
|
State can be 'None' > No progress, 'Indeterminate' > Without value, 'Normal' > when using value, 'Error' > Red (when using value), 'Paused' > Yellow (when using value)
|
||||||
|
.PARAMETER value
|
||||||
|
Value can be between 0 and 1, 0 being no progress done yet and 1 being fully completed
|
||||||
|
|
||||||
.PARAMETER overlay
|
.PARAMETER overlay
|
||||||
Overlay icon to display on the taskbar item
|
Overlay icon to display on the taskbar item
|
||||||
@ -18,9 +20,6 @@
|
|||||||
Set-WinUtilTaskbaritem -overlay "C:\path\to\icon.png"
|
Set-WinUtilTaskbaritem -overlay "C:\path\to\icon.png"
|
||||||
|
|
||||||
#>
|
#>
|
||||||
|
|
||||||
|
|
||||||
function Set-WinUtilTaskbaritem {
|
|
||||||
param (
|
param (
|
||||||
[double]$value,
|
[double]$value,
|
||||||
$state,
|
$state,
|
||||||
|
@ -161,7 +161,8 @@ $logoPath = "$env:TEMP\cttlogo.png"
|
|||||||
Invoke-WebRequest -Uri $logoUrl -OutFile $logoPath
|
Invoke-WebRequest -Uri $logoUrl -OutFile $logoPath
|
||||||
|
|
||||||
# download the check
|
# download the check
|
||||||
$CheckUrl = "https://raw.githubusercontent.com/ChrisTitusTech/winutil/main/docs/assets/Check.png"
|
$CheckUrl = "https://raw.githubusercontent.com/ChrisTitusTech/winutil/main/docs/assets/check.png"
|
||||||
|
|
||||||
# Download the image
|
# Download the image
|
||||||
$CheckPath = "$env:TEMP\cttcheck.png"
|
$CheckPath = "$env:TEMP\cttcheck.png"
|
||||||
Invoke-WebRequest -Uri $CheckUrl -OutFile $CheckPath
|
Invoke-WebRequest -Uri $CheckUrl -OutFile $CheckPath
|
||||||
@ -446,7 +447,7 @@ $sync["SearchBar"].Add_TextChanged({
|
|||||||
})
|
})
|
||||||
|
|
||||||
$sync["Form"].Add_Activated({
|
$sync["Form"].Add_Activated({
|
||||||
Set-WinUtilTaskbaritem -overlay $logoPath
|
Set-WinUtilTaskbaritem -overlay $logoPath -state "None"
|
||||||
})
|
})
|
||||||
|
|
||||||
# Define event handler for button click
|
# Define event handler for button click
|
||||||
|
Loading…
Reference in New Issue
Block a user