Remove debug logging statements from UI initialization for cleaner code

This commit is contained in:
rbalsleyMSFT
2025-06-09 20:32:54 -07:00
parent c5730230f6
commit 9d7d0a0ec9
-5
View File
@@ -1768,11 +1768,6 @@ $window.Add_Loaded({
$window.FindName('txtProcessors').Text = $script:uiState.Defaults.generalDefaults.Processors $window.FindName('txtProcessors').Text = $script:uiState.Defaults.generalDefaults.Processors
$window.FindName('txtVMLocation').Text = $script:uiState.Defaults.generalDefaults.VMLocation $window.FindName('txtVMLocation').Text = $script:uiState.Defaults.generalDefaults.VMLocation
$window.FindName('txtVMNamePrefix').Text = $script:uiState.Defaults.generalDefaults.VMNamePrefix $window.FindName('txtVMNamePrefix').Text = $script:uiState.Defaults.generalDefaults.VMNamePrefix
WriteLog "DEBUG: Before cmbLogicalSectorSize assignment."
WriteLog "DEBUG: \$script:uiState.Defaults.generalDefaults is $($script:uiState.Defaults.generalDefaults -ne $null)."
if ($script:uiState.Defaults.generalDefaults -ne $null) {
WriteLog "DEBUG: \$script:uiState.Defaults.generalDefaults.LogicalSectorSize is $($script:uiState.Defaults.generalDefaults.LogicalSectorSize)."
}
$window.FindName('cmbLogicalSectorSize').SelectedItem = ($window.FindName('cmbLogicalSectorSize').Items | Where-Object { $_.Content -eq $script:uiState.Defaults.generalDefaults.LogicalSectorSize.ToString() }) $window.FindName('cmbLogicalSectorSize').SelectedItem = ($window.FindName('cmbLogicalSectorSize').Items | Where-Object { $_.Content -eq $script:uiState.Defaults.generalDefaults.LogicalSectorSize.ToString() })
# Hyper-V Settings: Populate VM Switch ComboBox (Keep existing logic) # Hyper-V Settings: Populate VM Switch ComboBox (Keep existing logic)