mirror of
https://github.com/ChrisTitusTech/winutil.git
synced 2025-06-28 09:04:47 -05:00

* Implement app installation progress overlay and refactor progress bar handling * Add overlay background color settings and ensure minimum progress bar value * Add busy overlay functionality and progress bar updates for installation process * Refactor busy overlay implementation to dynamically adjust size based on app area dimensions
22 lines
967 B
PowerShell
22 lines
967 B
PowerShell
function Show-WPFInstallAppBusy {
|
|
<#
|
|
.SYNOPSIS
|
|
Displays a busy overlay in the install app area of the WPF form.
|
|
This is used to indicate that an install or uninstall is in progress.
|
|
Dynamically updates the size of the overlay based on the app area on each invocation.
|
|
.PARAMETER text
|
|
The text to display in the busy overlay. Defaults to "Installing apps...".
|
|
#>
|
|
param (
|
|
$text = "Installing apps..."
|
|
)
|
|
$sync.form.Dispatcher.Invoke([action]{
|
|
$sync.InstallAppAreaOverlay.Visibility = [Windows.Visibility]::Visible
|
|
$sync.InstallAppAreaOverlay.Width = $($sync.InstallAppAreaScrollViewer.ActualWidth * 0.4)
|
|
$sync.InstallAppAreaOverlay.Height = $($sync.InstallAppAreaScrollViewer.ActualWidth * 0.4)
|
|
$sync.InstallAppAreaOverlayText.Text = $text
|
|
$sync.InstallAppAreaBorder.IsEnabled = $false
|
|
$sync.InstallAppAreaScrollViewer.Effect.Radius = 5
|
|
})
|
|
}
|