-
Notifications
You must be signed in to change notification settings - Fork 0
/
MainWindow.xaml
208 lines (195 loc) · 9.69 KB
/
MainWindow.xaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
<pu:WindowX x:Class="RFCL.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:RFCL.ViewModel"
mc:Ignorable="d"
xmlns:pu="https://opensource.panuon.com/wpf-ui"
MinHeight="450" MinWidth="800"
Title="RFCL" Height="580" Width="1000"
Foreground="#FFFFFF"
BorderBrush="#2E2E2E"
Background="Transparent"
BorderThickness="1"
WindowStartupLocation="CenterScreen"
pu:WindowXCaption.BorderThickness="0,0,0,1"
pu:WindowXCaption.Buttons="MinimizeClose">
<Grid>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="220" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<Grid>
<StackPanel Grid.Column="0" Margin="10,10,0,10">
<Button Height="40"
Content="主页"
Command="{Binding HomeViewCommandCommand}"
Background="{Binding HomeViewBackground}"
Foreground="#FFFFFF"
pu:IconHelper.FontFamily="{StaticResource SegoeIcons}"
pu:IconHelper.Margin="0,1,10,0"
pu:IconHelper.FontSize="16"
pu:ButtonHelper.Icon=""
pu:ButtonHelper.CornerRadius="5">
<pu:ButtonHelper.HoverBackground>
<SolidColorBrush Color="#3E3E3E" Opacity="0.5" />
</pu:ButtonHelper.HoverBackground>
<pu:ButtonHelper.ClickBackground>
<SolidColorBrush Color="#3A3A3A" Opacity="0.5" />
</pu:ButtonHelper.ClickBackground>
</Button>
<Button Height="40"
Margin="0,5,0,0"
Content="游戏设置"
Command="{Binding GameViewCommandCommand}"
Background="{Binding GameViewBackground}"
Foreground="#FFFFFF"
pu:IconHelper.FontFamily="{StaticResource SegoeIcons}"
pu:IconHelper.Margin="0,1,10,0"
pu:IconHelper.FontSize="16"
pu:ButtonHelper.Icon=""
pu:ButtonHelper.CornerRadius="5">
<pu:ButtonHelper.HoverBackground>
<SolidColorBrush Color="#3E3E3E" Opacity="0.5" />
</pu:ButtonHelper.HoverBackground>
<pu:ButtonHelper.ClickBackground>
<SolidColorBrush Color="#3A3A3A" Opacity="0.5" />
</pu:ButtonHelper.ClickBackground>
</Button>
<Button Height="40"
Margin="0,5,0,0"
Content="版本列表"
Command="{Binding VersionViewCommandCommand}"
Background="{Binding VersionViewBackground}"
Foreground="#FFFFFF"
pu:IconHelper.FontFamily="{StaticResource SegoeIcons}"
pu:IconHelper.Margin="0,0,10,0"
pu:IconHelper.FontSize="16"
pu:ButtonHelper.Icon=""
pu:ButtonHelper.CornerRadius="5">
<pu:ButtonHelper.HoverBackground>
<SolidColorBrush Color="#3E3E3E" Opacity="0.5" />
</pu:ButtonHelper.HoverBackground>
<pu:ButtonHelper.ClickBackground>
<SolidColorBrush Color="#3A3A3A" Opacity="0.5" />
</pu:ButtonHelper.ClickBackground>
</Button>
<Button Height="40"
Margin="0,5,0,0"
Content="下载"
Command="{Binding DownloadViewCommandCommand}"
Background="{Binding DownloadViewBackground}"
Foreground="#FFFFFF"
pu:IconHelper.FontFamily="{StaticResource SegoeIcons}"
pu:IconHelper.Margin="0,0,10,0"
pu:IconHelper.FontSize="16"
pu:ButtonHelper.Icon=""
pu:ButtonHelper.CornerRadius="5">
<pu:ButtonHelper.HoverBackground>
<SolidColorBrush Color="#3E3E3E" Opacity="0.5" />
</pu:ButtonHelper.HoverBackground>
<pu:ButtonHelper.ClickBackground>
<SolidColorBrush Color="#3A3A3A" Opacity="0.5" />
</pu:ButtonHelper.ClickBackground>
</Button>
</StackPanel>
<StackPanel VerticalAlignment="Bottom" Grid.Column="0" Margin="10,10,0,10">
<Button Height="40"
Content="账号"
Command="{Binding AccountViewCommandCommand}"
Background="{Binding AccountViewBackground}"
Foreground="#FFFFFF"
pu:IconHelper.FontFamily="{StaticResource SegoeIcons}"
pu:IconHelper.Margin="0,0,10,0"
pu:IconHelper.FontSize="16"
pu:ButtonHelper.Icon=""
pu:ButtonHelper.CornerRadius="5">
<pu:ButtonHelper.HoverBackground>
<SolidColorBrush Color="#3E3E3E" Opacity="0.5" />
</pu:ButtonHelper.HoverBackground>
<pu:ButtonHelper.ClickBackground>
<SolidColorBrush Color="#3A3A3A" Opacity="0.5" />
</pu:ButtonHelper.ClickBackground>
</Button>
<Button Height="40"
Margin="0,5,0,0"
Content="设置"
Command="{Binding SettingsViewCommandCommand}"
Background="{Binding SettingsViewBackground}"
Foreground="#FFFFFF"
pu:IconHelper.FontFamily="{StaticResource SegoeIcons}"
pu:IconHelper.Margin="0,0,10,0"
pu:IconHelper.FontSize="16"
pu:ButtonHelper.Icon=""
pu:ButtonHelper.CornerRadius="5">
<pu:ButtonHelper.HoverBackground>
<SolidColorBrush Color="#3E3E3E" Opacity="0.5" />
</pu:ButtonHelper.HoverBackground>
<pu:ButtonHelper.ClickBackground>
<SolidColorBrush Color="#3A3A3A" Opacity="0.5" />
</pu:ButtonHelper.ClickBackground>
</Button>
</StackPanel>
</Grid>
<Frame NavigationUIVisibility="Hidden" Grid.Column="2" Margin="10"
Content="{Binding FrameContent, Mode=TwoWay}" />
</Grid>
<Grid x:Name="Shadowing" Visibility="Collapsed" Background="Black" Opacity="0.6" />
<Border HorizontalAlignment="Center" VerticalAlignment="Center" MinHeight="140"
MinWidth="240" Visibility="Collapsed" CornerRadius="5" Background="#2A2A2A"
x:Name="Contentdialog">
<Grid Margin="15" x:Name="ContentdialogContent" />
</Border>
</Grid>
<pu:WindowX.Triggers>
<EventTrigger RoutedEvent="pu:WindowX.Loaded">
<EventTrigger.Actions>
<BeginStoryboard>
<Storyboard>
<DoubleAnimation Duration="0:0:.50" Storyboard.TargetProperty="Opacity"
From="0" To="2" />
</Storyboard>
</BeginStoryboard>
</EventTrigger.Actions>
</EventTrigger>
</pu:WindowX.Triggers>
<pu:WindowX.DataContext>
<local:MainWindowViewModel />
</pu:WindowX.DataContext>
<pu:WindowXCaption.HeaderTemplate>
<DataTemplate>
<TextBlock Text="RFCL"
VerticalAlignment="Center"
HorizontalAlignment="Center"
Margin="80,0,0,0" />
</DataTemplate>
</pu:WindowXCaption.HeaderTemplate>
<pu:WindowXCaption.MinimizeButtonStyle>
<Style TargetType="Button" BasedOn="{StaticResource {x:Static pu:WindowXCaption.MinimizeButtonStyleKey}}">
<Setter Property="FontSize"
Value="14" />
<Setter Property="pu:ButtonHelper.HoverBackground"
Value="{x:Null}" />
<Setter Property="pu:ButtonHelper.HoverForeground"
Value="#AAAAAA" />
</Style>
</pu:WindowXCaption.MinimizeButtonStyle>
<pu:WindowXCaption.CloseButtonStyle>
<Style TargetType="Button" BasedOn="{StaticResource {x:Static pu:WindowXCaption.CloseButtonStyleKey}}">
<Setter Property="FontSize"
Value="14" />
<Setter Property="pu:ButtonHelper.HoverBackground"
Value="{x:Null}" />
<Setter Property="pu:ButtonHelper.HoverForeground"
Value="#FF4C4C" />
</Style>
</pu:WindowXCaption.CloseButtonStyle>
<pu:WindowXCaption.Background>
<SolidColorBrush Color="#2A2A2A" Opacity="0.5" />
</pu:WindowXCaption.Background>
<pu:WindowXCaption.BorderBrush>
<SolidColorBrush Color="#2E2E2E" Opacity="0.5" />
</pu:WindowXCaption.BorderBrush>
</pu:WindowX>