[Microwin] Fix & Cleanup UI (#3426)

* hide MicrowinISOPanel on proceeding steps

* fix textbox styling + remove Password text

* MicroWinPanelToggling
This commit is contained in:
MyDrift
2025-06-26 19:21:49 +02:00
committed by GitHub
parent 28958938fc
commit e74258acf4
5 changed files with 74 additions and 4 deletions

View File

@ -801,6 +801,7 @@
<Setter Property="HorizontalAlignment" Value="Stretch"/>
<Setter Property="VerticalAlignment" Value="Center"/>
<Setter Property="HorizontalContentAlignment" Value="Stretch"/>
<Setter Property="CaretBrush" Value="{DynamicResource MainForegroundColor}"/>
<Setter Property="ContextMenu">
<Setter.Value>
<ContextMenu>
@ -855,6 +856,7 @@
<Setter Property="HorizontalAlignment" Value="Stretch"/>
<Setter Property="VerticalAlignment" Value="Center"/>
<Setter Property="HorizontalContentAlignment" Value="Stretch"/>
<Setter Property="CaretBrush" Value="{DynamicResource MainForegroundColor}"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="PasswordBox">
@ -1259,7 +1261,7 @@
VerticalAlignment="Stretch"
HorizontalAlignment="Stretch">
<StackPanel Name="MicrowinMain" Background="{DynamicResource MainBackgroundColor}" SnapsToDevicePixels="True" Grid.Column="0" Grid.Row="0">
<StackPanel Background="Transparent" SnapsToDevicePixels="True" Margin="1">
<StackPanel Name="MicrowinISOPanel" Background="Transparent" SnapsToDevicePixels="True" Margin="1">
<CheckBox x:Name="WPFMicrowinDownloadFromGitHub" Content="Download oscdimg.exe from CTT Github repo" IsChecked="True" Margin="{DynamicResource MicrowinCheckBoxMargin}" />
<TextBlock Margin="5" Padding="1" TextWrapping="Wrap" Foreground="{DynamicResource ComboBoxForegroundColor}">
Choose a Windows ISO file that you've downloaded <LineBreak/>
@ -1314,8 +1316,46 @@
</Button.Content>
</Button>
</StackPanel>
<!-- Visibility="Hidden" -->
<StackPanel Name="MicrowinOptionsPanel" HorizontalAlignment="Left" SnapsToDevicePixels="True" Margin="1" Visibility="Hidden">
<Grid Margin="0,0,0,10">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Button Name="WPFMicrowinPanelBack"
Grid.Column="0"
Width="30" Height="30"
HorizontalAlignment="Left"
FontFamily="Segoe MDL2 Assets"
FontSize="12"
Content="&#xE76B;"
ToolTip="Back to main view"
Background="{DynamicResource ButtonBackgroundColor}"
Foreground="{DynamicResource ButtonForegroundColor}"
BorderBrush="{DynamicResource ButtonBackgroundColor}"
BorderThickness="1"
Padding="0">
<Button.ContentTemplate>
<DataTemplate>
<TextBlock Text="{Binding}"
HorizontalAlignment="Center"
VerticalAlignment="Center"/>
</DataTemplate>
</Button.ContentTemplate>
</Button>
<TextBlock Name="MicrowinPanel2Title"
Grid.Column="1"
Text="Configure Windows ISO"
Margin="10,0,0,0"
Foreground="{DynamicResource MainForegroundColor}"
FontSize="16"
VerticalAlignment="Center"/>
</Grid>
<TextBlock Margin="6" Padding="1" TextWrapping="Wrap">Choose Windows SKU</TextBlock>
<ComboBox x:Name = "MicrowinWindowsFlavors" Margin="1" />
<Rectangle Fill="{DynamicResource MainForegroundColor}" Height="2" HorizontalAlignment="Stretch" Margin="0,10,0,10"/>
@ -1343,7 +1383,7 @@
Foreground="{DynamicResource LabelboxForegroundColor}"
MaxLength="20"
/>
<TextBlock Margin="6" Padding="1" TextWrapping="Wrap">Password (characters will not be shown for your security):</TextBlock>
<TextBlock Margin="6" Padding="1" TextWrapping="Wrap">Password:</TextBlock>
<PasswordBox Name="MicrowinUserPassword" Background="Transparent" BorderThickness="1" BorderBrush="{DynamicResource MainForegroundColor}"
Margin="6"
PasswordChar="*"