Skip to content

Commit e482d0b

Browse files
authored
Added MD3 version of MaterialDesignSwitchToggleButton (#2748)
1 parent fd662c2 commit e482d0b

File tree

3 files changed

+1048
-3
lines changed

3 files changed

+1048
-3
lines changed

MaterialDesign3.Demo.Wpf/App.xaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
<ResourceDictionary
4545
Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.Button.xaml" />
4646
<ResourceDictionary
47-
Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.ToggleButton.xaml" />
47+
Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesign3.ToggleButton.xaml" />
4848
</ResourceDictionary.MergedDictionaries>
4949

5050
<smtxAe:TextDocumentValueConverter

MaterialDesignThemes.Wpf/Themes/MaterialDesign3.Defaults.xaml

+4-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
22
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
33

4-
<!-- use this resource dictionary to set up the most common themese for standard controls -->
4+
<!-- use this resource dictionary to set up the most common themes for standard controls -->
55

66
<ResourceDictionary.MergedDictionaries>
77
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesign3.Font.xaml" />
@@ -41,13 +41,15 @@
4141
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.TabControl.xaml" />
4242
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.TextBox.xaml" />
4343
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.TimePicker.xaml" />
44-
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.ToggleButton.xaml" />
4544
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.ToolBar.xaml" />
4645
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.ToolBarTray.xaml" />
4746
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.ToolTip.xaml" />
4847
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.TreeView.xaml" />
4948
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.Thumb.xaml" />
5049
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.ValidationErrorTemplate.xaml" />
50+
51+
<!-- add MD3 toggle button last because CheckBox and ToolBar resource dictionaries import the MD2 version -->
52+
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesign3.ToggleButton.xaml" />
5153
</ResourceDictionary.MergedDictionaries>
5254

5355
<SolidColorBrush x:Key="MaterialDesignLightBackground" Color="#FFFAFAFA"/>

0 commit comments

Comments
 (0)