Skip to content

Commit 2f78e1a

Browse files
Evangelinkpunker76
authored andcommitted
Fix some mui style keys
1 parent 9410222 commit 2f78e1a

10 files changed

+18
-15
lines changed

src/MahApps.Metro/Styles/Controls.ComboBox.xaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -987,7 +987,7 @@
987987
</Style.Triggers>
988988
</Style>
989989

990-
<Style x:Key="MahApps.Styles.ComboBox.DataGridEditing" TargetType="ComboBox" BasedOn="{StaticResource MahApps.Styles.ComboBox.Mui}">
990+
<Style x:Key="MahApps.Styles.ComboBox.DataGridEditing.Mui" TargetType="ComboBox" BasedOn="{StaticResource MahApps.Styles.ComboBox.Mui}">
991991
<Setter Property="IsSynchronizedWithCurrentItem" Value="False" />
992992
<Setter Property="BorderThickness" Value="0" />
993993
<Setter Property="Padding" Value="1,1" />

src/MahApps.Metro/Styles/Controls.DataGrid.xaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -627,7 +627,7 @@
627627

628628
<!-- MUI -->
629629

630-
<Style x:Key="{ComponentResourceKey TypeInTargetAssembly={x:Type DataGrid}, ResourceId=DataGridSelectAllButtonStyle}" TargetType="{x:Type Button}"
630+
<Style x:Key="MahApps.Styles.Button.DataGridSelectAll.Mui" TargetType="{x:Type Button}"
631631
BasedOn="{StaticResource MahApps.Styles.Button.Base.Mui}">
632632
<Setter Property="Background" Value="Transparent" />
633633
<Setter Property="BorderThickness" Value="0" />

src/MahApps.Metro/Styles/Controls.GridSpliter.xaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
22
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
33

4+
<!-- MUI -->
5+
46
<Style x:Key="MahApps.Styles.GridSplitter.Mui" TargetType="GridSplitter">
57
<Setter Property="Background" Value="{DynamicResource MahApps.Brushes.SeparatorBackground.Mui}" />
68
<Setter Property="VerticalAlignment" Value="Stretch" />

src/MahApps.Metro/Styles/Controls.Hyperlink.xaml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
2-
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
3-
xmlns:local="clr-namespace:MahApps.Metro.Styles">
2+
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
43

5-
<Style x:Key="MahApps.Styles.Hyperlink.Mui" TargetType="{x:Type Hyperlink}">
4+
<!-- MUI -->
5+
6+
<Style x:Key="MahApps.Styles.Hyperlink.Mui" TargetType="{x:Type Hyperlink}">
67
<Setter Property="Foreground" Value="{DynamicResource MahApps.Brushes.Hyperlink.Mui}"/>
78
<Setter Property="TextDecorations" Value="Underline"/>
89
<Style.Triggers>

src/MahApps.Metro/Styles/Controls.Label.xaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@
55
<Setter Property="Foreground" Value="{DynamicResource MahApps.Brushes.Label.Text}" />
66
</Style>
77

8+
<!-- MUI -->
9+
810
<Style x:Key="MahApps.Styles.Label.Mui" TargetType="{x:Type Label}">
911
<Setter Property="Foreground" Value="{DynamicResource MahApps.Brushes.WindowText.Mui}"/>
1012
<Setter Property="Background" Value="Transparent"/>

src/MahApps.Metro/Styles/Controls.ListView.xaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -449,7 +449,7 @@
449449
</Setter>
450450
</Style>
451451

452-
<Style x:Key="{x:Static GridView.GridViewStyleKey}" TargetType="{x:Type ListView}">
452+
<Style x:Key="MahApps.Styles.ListView.GridView.Mui" TargetType="{x:Type ListView}">
453453
<Setter Property="FocusVisualStyle" Value="{x:Null}" />
454454
<Setter Property="Background" Value="Transparent"/>
455455
<Setter Property="BorderThickness" Value="0"/>

src/MahApps.Metro/Styles/Controls.MenuItem.xaml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
<Geometry x:Key="RightArrow">M 0,0 L 4,3.5 L 0,7 Z</Geometry>
77
<Geometry x:Key="Checkmark">M 15,21L 22,28L 32.9999,14.0001L 35.9999,17.0001L 22,34L 12.0001,24L 15,21 Z</Geometry>
88

9-
<Style x:Key="{x:Static MenuItem.SeparatorStyleKey}" TargetType="{x:Type Separator}">
9+
<Style x:Key="MahApps.Styles.Separator.MenuItem.Mui" TargetType="{x:Type Separator}">
1010
<Setter Property="Template">
1111
<Setter.Value>
1212
<ControlTemplate TargetType="{x:Type Separator}">
@@ -20,8 +20,7 @@
2020
</Setter>
2121
</Style>
2222

23-
<ControlTemplate x:Key="{ComponentResourceKey TypeInTargetAssembly={x:Type MenuItem}, ResourceId=SubmenuItemTemplateKey}"
24-
TargetType="{x:Type MenuItem}">
23+
<ControlTemplate x:Key="MahApps.Templates.MenuItem.SubMenuItem.Mui" TargetType="{x:Type MenuItem}">
2524
<Grid SnapsToDevicePixels="true">
2625
<Rectangle Name="Bg" Fill="{TemplateBinding MenuItem.Background}"/>
2726
<Grid>
@@ -80,8 +79,8 @@
8079
</Trigger>
8180
</ControlTemplate.Triggers>
8281
</ControlTemplate>
83-
<ControlTemplate x:Key="{ComponentResourceKey TypeInTargetAssembly={x:Type MenuItem}, ResourceId=SubmenuHeaderTemplateKey}"
84-
TargetType="{x:Type MenuItem}">
82+
83+
<ControlTemplate x:Key="MahApps.Templates.MenuItem.SubMenuHeader.Mui" TargetType="{x:Type MenuItem}">
8584
<Grid SnapsToDevicePixels="true">
8685
<Rectangle Name="Bg" Fill="{TemplateBinding MenuItem.Background}"/>
8786
<Grid>
@@ -181,6 +180,7 @@
181180
</Trigger>
182181
</ControlTemplate.Triggers>
183182
</ControlTemplate>
183+
184184
<Style x:Key="MahApps.Styles.MenuItem.Mui" TargetType="{x:Type MenuItem}">
185185
<Setter Property="HorizontalContentAlignment"
186186
Value="{Binding Path=HorizontalContentAlignment,RelativeSource={RelativeSource AncestorType={x:Type ItemsControl}}}"/>

src/MahApps.Metro/Styles/Controls.Scrollbars.xaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -521,7 +521,7 @@
521521
</Setter>
522522
</Style>
523523

524-
<Style x:Key="{x:Static GridView.GridViewScrollViewerStyleKey}" TargetType="{x:Type ScrollViewer}">
524+
<Style x:Key="MahApps.Styles.ScrollViewer.GridView.Mui" TargetType="{x:Type ScrollViewer}">
525525
<Setter Property="Focusable" Value="false"/>
526526
<Setter Property="FocusVisualStyle" Value="{x:Null}" />
527527
<Setter Property="Template">

src/MahApps.Metro/Styles/Controls.TextBlock.xaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@
7070
<Setter Property="TextOptions.TextFormattingMode" Value="Display" />
7171
</Style>
7272

73-
<Style x:Key="MahApps.Styles.TextBlock.DataGrid" TargetType="TextBlock" >
73+
<Style x:Key="MahApps.Styles.TextBlock.DataGrid.Mui" TargetType="TextBlock" >
7474
<Setter Property="Margin" Value="2,0" />
7575
</Style>
7676

src/MahApps.Metro/Styles/Controls.TextBox.xaml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1086,8 +1086,6 @@
10861086

10871087
<Style x:Key="MahApps.Styles.RichTextBox.Mui" BasedOn="{StaticResource MahApps.Styles.TextBoxBase.Mui}" TargetType="{x:Type RichTextBox}" />
10881088

1089-
<!-- text-in-datagrid styles-->
1090-
10911089
<Style x:Key="MahApps.Styles.TextBox.DataGridEditing.Mui" TargetType="TextBox" BasedOn="{StaticResource MahApps.Styles.TextBox.Mui}">
10921090
<Setter Property="BorderThickness" Value="0" />
10931091
<Setter Property="Padding" Value="0" />

0 commit comments

Comments
 (0)