프로젝트

일반

사용자정보

통계
| 브랜치(Branch): | 개정판:

markus / ConvertService / ServiceBase / Markus.Service.StationController / MainWindow.xaml @ e19522be

이력 | 보기 | 이력해설 | 다운로드 (5.24 KB)

1
<Window x:Class="Markus.Service.StationController.MainWindow"
2
        xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
3
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
4
        xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
5
        xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
6
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
7
        xmlns:mvvmToolkit="clr-namespace:Markus.Mvvm.ToolKit;assembly=Markus.Mvvm.ToolKit"
8
        TextElement.Foreground="{DynamicResource MaterialDesignBody}"
9
        mc:Ignorable="d"
10
        xmlns:i="clr-namespace:System.Windows.Interactivity;assembly=System.Windows.Interactivity"
11
        xmlns:vm="clr-namespace:Markus.Service.StationController.ViewModel"
12
        xmlns:localData="clr-namespace:Markus.Service.StationController.Data"
13
        Title="Markus Convert Service" Height="450" Width="800" Foreground="{DynamicResource {x:Static SystemColors.MenuHighlightBrushKey}}">
14
    <i:Interaction.Triggers>
15
        <i:EventTrigger  EventName="Loaded">
16
            <i:InvokeCommandAction Command="{Binding LoadedCommand}"/>
17
        </i:EventTrigger>
18
        <i:EventTrigger  EventName="Closing">
19
            <i:InvokeCommandAction Command="{Binding ClosingCommand}"/>
20
        </i:EventTrigger>
21
    </i:Interaction.Triggers>
22
    <Window.DataContext>
23
        <vm:MainViewModel/>
24
    </Window.DataContext>
25
    <materialDesign:DialogHost x:Name="m_dialogHost" Identifier="dialogHost" DialogTheme="Light">
26
        <materialDesign:DrawerHost IsLeftDrawerOpen="{Binding ElementName=MenuToggleButton, Path=IsChecked}">
27
            <materialDesign:DrawerHost.LeftDrawerContent>
28
                <DockPanel MinWidth="212">
29
                    <ToggleButton Style="{StaticResource MaterialDesignHamburgerToggleButton}" 
30
                                    DockPanel.Dock="Top"
31
                                    HorizontalAlignment="Right" Margin="16"
32
                                    IsChecked="{Binding ElementName=MenuToggleButton, Path=IsChecked, Mode=TwoWay}" />
33
                    <ListBox x:Name="MenuListBox" Margin="0 16 0 16" SelectedIndex="0"                     
34
                             ItemsSource="{Binding NavigationItems}" SelectedItem="{Binding SelectNavigationItem}">
35
                        <i:Interaction.Triggers>
36
                            <i:EventTrigger  EventName="PreviewMouseLeftButtonUp">
37
                                <i:InvokeCommandAction Command="{Binding ListboxItemMouseUpCommand}"/>
38
                            </i:EventTrigger>
39
                        </i:Interaction.Triggers>
40
                        <ListBox.ItemTemplate>
41
                            <DataTemplate DataType="localData:NavigationItem">
42
                                <TextBlock Text="{Binding Name}" Margin="32 0 32 0" />
43
                            </DataTemplate>
44
                        </ListBox.ItemTemplate>
45
                    </ListBox>
46
                </DockPanel>
47
            </materialDesign:DrawerHost.LeftDrawerContent>
48
            <Grid>
49
                <Grid.RowDefinitions>
50
                    <RowDefinition Height="Auto"/>
51
                    <RowDefinition/>
52
                </Grid.RowDefinitions>
53
                    <materialDesign:ColorZone Padding="16" materialDesign:ShadowAssist.ShadowDepth="Depth2"
54
                                            Mode="PrimaryMid">
55
                    <DockPanel>
56
                        <ToggleButton Style="{StaticResource MaterialDesignHamburgerToggleButton}" IsChecked="{Binding IsMenuOpen}"
57
                                        x:Name="MenuToggleButton"/>
58
                        <Grid>
59
                            <Grid.ColumnDefinitions>
60
                                <ColumnDefinition Width="Auto"/>
61
                                <ColumnDefinition/>
62
                            </Grid.ColumnDefinitions>
63
                            <TextBlock  Style="{StaticResource MaterialDesignSubheadingTextBlock}" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="10,0,0,0" >Markus Convert Management</TextBlock>
64
                            <TextBlock Grid.Column="1" VerticalAlignment="Center" HorizontalAlignment="Center"
65
                                        Text="{Binding SelectNavigationItem.Description}"
66
                                       Style="{StaticResource MaterialDesignDisplay1TextBlock}"/>
67
                        </Grid>
68
                    </DockPanel>
69
                </materialDesign:ColorZone>
70
                <Grid Grid.Row="1">
71
                    <Grid.RowDefinitions>
72
                        <RowDefinition Height="Auto" />
73
                        <RowDefinition Height="*" />
74
                    </Grid.RowDefinitions>
75
                    <ScrollViewer Grid.Row="1" 
76
                                  HorizontalScrollBarVisibility="Auto"
77
                                  VerticalScrollBarVisibility="Auto">
78
                        <ContentControl Content="{Binding SelectNavigationItem.Content}"/>
79
                    </ScrollViewer>
80
                    <materialDesign:Snackbar MessageQueue="{materialDesign:MessageQueue}" x:Name="MainSnackbar"
81
                                            Grid.Row="1" />
82
                </Grid>
83
            </Grid>
84
        </materialDesign:DrawerHost>
85
    </materialDesign:DialogHost>
86
</Window>
클립보드 이미지 추가 (최대 크기: 500 MB)