From b3e76f5580eb528b3ea69cce48c3cc2bb9f9428a Mon Sep 17 00:00:00 2001 From: rbalsleyMSFT Date: Wed, 25 Dec 2024 00:49:09 -0800 Subject: [PATCH] Broke out the xaml to a separate file. Added drivers tab --- FFUDevelopment/BuildFFUVM_UI.ps1 | 208 +++++++----------------------- FFUDevelopment/BuildFFUVM_UI.xaml | 179 +++++++++++++++++++++++++ 2 files changed, 224 insertions(+), 163 deletions(-) create mode 100644 FFUDevelopment/BuildFFUVM_UI.xaml diff --git a/FFUDevelopment/BuildFFUVM_UI.ps1 b/FFUDevelopment/BuildFFUVM_UI.ps1 index 62fda88..833217f 100644 --- a/FFUDevelopment/BuildFFUVM_UI.ps1 +++ b/FFUDevelopment/BuildFFUVM_UI.ps1 @@ -12,171 +12,16 @@ Add-Type -AssemblyName PresentationCore,PresentationFramework Add-Type -AssemblyName System.Windows.Forms # Added to load Windows Forms for OpenFileDialog # Define the path to the info.png image -$infoImagePath = "$PSScriptRoot\info.png" +$infoImagePath = Join-Path -Path $PSScriptRoot -ChildPath "info.png" -# Replace the XAML string with one that uses ToolTips instead of Popups and adjusts their placement -$xamlString = @" - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +# Load the XAML from the external file +$xamlPath = Join-Path -Path $PSScriptRoot -ChildPath "BuildFFUVM_UI.xaml" +if (-Not (Test-Path $xamlPath)) { + Write-Error "XAML file not found at path: $xamlPath" + exit +} - - - - - - - - - - - - - - - - - - - -