|
1 | 1 | <Application xmlns="https://github.com/avaloniaui" |
2 | 2 | xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
3 | 3 | xmlns:local="clr-namespace:FinderOuter" |
| 4 | + xmlns:vm="clr-namespace:FinderOuter.ViewModels" |
| 5 | + xmlns:views="clr-namespace:FinderOuter.Views" |
4 | 6 | x:Class="FinderOuter.App" |
5 | 7 | RequestedThemeVariant="Default"> |
6 | | - <Application.DataTemplates> |
7 | | - <local:ViewLocator/> |
8 | | - </Application.DataTemplates> |
9 | 8 |
|
10 | 9 | <Application.Styles> |
11 | 10 | <SimpleTheme/> |
12 | 11 | </Application.Styles> |
13 | 12 |
|
| 13 | + <Application.DataTemplates> |
| 14 | + <DataTemplate DataType="{x:Type vm:AboutViewModel}"> |
| 15 | + <views:AboutView/> |
| 16 | + </DataTemplate> |
| 17 | + <DataTemplate DataType="{x:Type vm:MessageBoxViewModel}"> |
| 18 | + <views:MessageBoxView/> |
| 19 | + </DataTemplate> |
| 20 | + <DataTemplate DataType="{x:Type vm:KnowledgeBaseViewModel}"> |
| 21 | + <views:KnowledgeBaseView/> |
| 22 | + </DataTemplate> |
| 23 | + </Application.DataTemplates> |
| 24 | + |
14 | 25 | <Application.Styles> |
15 | 26 | <Style Selector="Button"> |
16 | 27 | <Setter Property="CornerRadius" Value="5"/> |
17 | 28 | </Style> |
18 | 29 |
|
19 | 30 | <!--Use Classes="Help" in any Button to change it into a round help button with "?" in it--> |
20 | 31 | <Style Selector="Button.Help"> |
21 | | - <Setter Property="Command" Value="{Binding OpenKBCommand}"/> |
| 32 | + <Setter Property="Command" Value="{Binding OpenKBCommand}" x:DataType="vm:ViewModelBase"/> |
22 | 33 | <Setter Property="CommandParameter" Value="Bitcoin"/> |
23 | 34 | <Setter Property="CornerRadius" Value="20"/> |
24 | 35 | <Setter Property="Margin" Value="6,6,5,5"/> |
|
0 commit comments