LETS GOOO (#12)

* Add Selected Apps Label, Reshuffel the nesting of the checkbox and the label to be able to reference the name from the actual checkbox

* Add visual selection and allow click on the whole app section

* Fix Theme definition to work with theme change

* Fix Highlight on if label or icon is clicked

* change applications.json to powershell object list and refactor UI Creation logic

* Optimization and Add Collapsable Categories

* Add Button functionality for install, uninstall, info, install selected, uninstall selected, clear and implement search

* Rest application.json to Main

* Reset Compile to main

* Pretty much revamp_apps but without changes to applications.json

* Small fixes
This commit is contained in:
Martin Wiethan
2024-10-13 19:25:02 +02:00
committed by GitHub
parent 5bbc6c6a92
commit 6d88e51462
8 changed files with 632 additions and 120 deletions

View File

@ -20,9 +20,9 @@ function Invoke-WPFGetInstalled {
return
}
$preferChoco = $sync.WPFpreferChocolatey.IsChecked
Invoke-WPFRunspace -ArgumentList $checkbox, $preferChoco -DebugPreference $DebugPreference -ScriptBlock {
param($checkbox, $preferChoco, $DebugPreference)
Invoke-WPFRunspace -ArgumentList $checkbox, $preferChoco -ParameterList @(,("ShowOnlyCheckedApps",${function:Show-OnlyCheckedApps})) -DebugPreference $DebugPreference -ScriptBlock {
param($checkbox, $preferChoco, $ShowOnlyCheckedApps,$DebugPreference)
Write-Host $ShowOnlyCheckedApps.ToString()
$sync.ProcessRunning = $true
$sync.form.Dispatcher.Invoke([action]{ Set-WinUtilTaskbaritem -state "Indeterminate" })
@ -38,13 +38,15 @@ function Invoke-WPFGetInstalled {
else{
$Checkboxes = Invoke-WinUtilCurrentSystem -CheckBox $checkbox
}
$sync.form.Dispatcher.invoke({
foreach($checkbox in $Checkboxes) {
$sync.$checkbox.ischecked = $True
}
}
})
$sync.ItemsControl.Dispatcher.Invoke([action]{
$ShowOnlyCheckedApps.Invoke($sync.SelectedApps, $sync.ItemsControl)
})
Write-Host "Done..."
$sync.ProcessRunning = $false
$sync.form.Dispatcher.Invoke([action] { Set-WinUtilTaskbaritem -state "None" })