Skip to content

Commit c32daf1

Browse files
committed
Show DDS icon where it needs to be shown
1 parent d7d2dd4 commit c32daf1

File tree

1 file changed

+21
-11
lines changed

1 file changed

+21
-11
lines changed

ModManager/Views/Components/ModTweaker.xaml

+21-11
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,9 @@
1717
TrueValue="Visible"
1818
FalseValue="Hidden" />
1919
<Converters:NegateBoolConverter x:Key="NegateBool" />
20-
<Converters:IsEmptyToVisibility x:Key="CollapsedOnEmpty" OnEmpty="Collapsed" OnElse="Visible" />
20+
<Converters:IsEmptyToVisibility x:Key="CollapsedOnEmpty"
21+
OnEmpty="Collapsed"
22+
OnElse="Visible" />
2123
</Grid.Resources>
2224
<Grid.RowDefinitions>
2325
<RowDefinition Height="40" />
@@ -72,16 +74,24 @@
7274
<DataTemplate>
7375
<Expander IsExpanded="True">
7476
<Expander.Header>
75-
<StackPanel Margin="5">
76-
<TextBlock Style="{StaticResource IMYA_TEXT}"
77-
Text="{Binding Title}"
78-
FontWeight="Bold"
79-
Margin="2"/>
80-
<TextBlock Style="{StaticResource IMYA_TEXT}"
81-
Text="{Binding Description}"
82-
FontWeight="Light"
83-
Margin="2" />
84-
77+
<StackPanel Orientation="Horizontal">
78+
<Image Source="{Binding Path=IconFilename, Converter = {StaticResource FilepathToImageConverter}, UpdateSourceTrigger=Explicit, ConverterParameter=46x46}"
79+
MaxWidth="46"
80+
MaxHeight="46"
81+
HorizontalAlignment="Center"
82+
VerticalAlignment="Center"
83+
Visibility="{Binding HasIcon, Converter={StaticResource VisibleOnTrue}}"/>
84+
<StackPanel VerticalAlignment="Center"
85+
Margin="5">
86+
<TextBlock Style="{StaticResource IMYA_TEXT}"
87+
Text="{Binding Title}"
88+
FontWeight="Bold"
89+
Margin="2"/>
90+
<TextBlock Style="{StaticResource IMYA_TEXT}"
91+
Text="{Binding Description}"
92+
FontWeight="Light"
93+
Margin="2" />
94+
</StackPanel>
8595
</StackPanel>
8696
</Expander.Header>
8797

0 commit comments

Comments
 (0)