mirror of
https://github.com/ChrisTitusTech/winutil.git
synced 2025-07-03 03:23:31 -05:00
Add minimize and maximize button
Added an minimize and maximize button to the main window
This commit is contained in:
11
functions/public/Invoke-WPFMaximizeButton.ps1
Normal file
11
functions/public/Invoke-WPFMaximizeButton.ps1
Normal file
@ -0,0 +1,11 @@
|
||||
function Invoke-WPFMaximizeButton {
|
||||
<#
|
||||
.SYNOPSIS
|
||||
Alternates between Maximized and Minimized window
|
||||
#>
|
||||
if ($sync["Form"].WindowState -eq [System.Windows.WindowState]::Maximized) {
|
||||
$sync["Form"].WindowState = [System.Windows.WindowState]::Normal
|
||||
} else {
|
||||
$sync["Form"].WindowState = [System.Windows.WindowState]::Maximized
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user