comparison Chronosv2/source/Themes/Metro/WindowStyles.xaml @ 10:443821e55f06

Initial cleaned up add from Codeplex files
author stevenh7776 stevenhollidge@hotmail.com
date Tue, 21 Feb 2012 17:25:44 +0700
parents
children
comparison
equal deleted inserted replaced
9:904a9faadf8b 10:443821e55f06
1 <ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
2 xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
3 xmlns:chronos="http://chronos/schemas/2010/xaml">
4
5 <!-- Global Settings-->
6 <ResourceDictionary.MergedDictionaries>
7 <ResourceDictionary Source="Colors.xaml"/>
8 <ResourceDictionary Source="Brushes.xaml"/>
9 <ResourceDictionary Source="Fonts.xaml"/>
10 <ResourceDictionary Source="CoreStyles.xaml"/>
11 </ResourceDictionary.MergedDictionaries>
12
13 <!-- Converters -->
14 <chronos:ZoomTransformConverter x:Key="ZoomTransformConverter" />
15
16 <!-- Default Workspace Window Style -->
17 <Style x:Key="DefaultWorkspaceWindowStyle" TargetType="{x:Type chronos:WindowElement}">
18 <Setter Property="Id" Value="{Binding Id}" />
19 <Setter Property="FontSize" Value="{StaticResource ContentFontSize}"/>
20 <Setter Property="FocusVisualStyle" Value="{x:Null}" />
21 <Setter Property="MinWidth" Value="720" />
22 <Setter Property="MinHeight" Value="110" />
23 <Setter Property="Background" Value="{StaticResource WindowBackgroundBrush}" />
24 <Setter Property="BorderBrush" Value="{StaticResource WindowBorderBrush}" />
25 <Setter Property="BorderThickness" Value="1" />
26 <Setter Property="WindowState" Value="Normal" />
27 <Setter Property="Visibility" Value="Visible" />
28 <Setter Property="HorizontalContentAlignment" Value="Left" />
29 <Setter Property="VerticalContentAlignment" Value="Stretch" />
30 <Setter Property="AllowDrop" Value="False" />
31 <Setter Property="CanResize" Value="False" />
32 <Setter Property="ViewMode" Value="{Binding ViewMode}" />
33 <Setter Property="Title" Value="Sample Window" />
34 <Setter Property="Template">
35 <Setter.Value>
36 <ControlTemplate TargetType="{x:Type chronos:WindowElement}">
37 <Grid x:Name="Root">
38 <VisualStateManager.VisualStateGroups>
39 <VisualStateGroup x:Name="WindowState">
40 <VisualState x:Name="Normal">
41 <Storyboard>
42 <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Visibility">
43 <DiscreteObjectKeyFrame KeyTime="0">
44 <DiscreteObjectKeyFrame.Value>
45 <Visibility>Visible</Visibility>
46 </DiscreteObjectKeyFrame.Value>
47 </DiscreteObjectKeyFrame>
48 </ObjectAnimationUsingKeyFrames>
49 <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity">
50 <SplineDoubleKeyFrame KeyTime="0" Value="1"/>
51 </DoubleAnimationUsingKeyFrames>
52 </Storyboard>
53 </VisualState>
54 <VisualState x:Name="Minimized">
55 <Storyboard>
56 <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity">
57 <SplineDoubleKeyFrame KeyTime="0" Value="0"/>
58 </DoubleAnimationUsingKeyFrames>
59 <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Visibility">
60 <DiscreteObjectKeyFrame KeyTime="0">
61 <DiscreteObjectKeyFrame.Value>
62 <Visibility>Collapsed</Visibility>
63 </DiscreteObjectKeyFrame.Value>
64 </DiscreteObjectKeyFrame>
65 </ObjectAnimationUsingKeyFrames>
66 </Storyboard>
67 </VisualState>
68 <VisualState x:Name="Maximized">
69 <Storyboard>
70 <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Visibility">
71 <DiscreteObjectKeyFrame KeyTime="0">
72 <DiscreteObjectKeyFrame.Value>
73 <Visibility>Visible</Visibility>
74 </DiscreteObjectKeyFrame.Value>
75 </DiscreteObjectKeyFrame>
76 </ObjectAnimationUsingKeyFrames>
77 <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity">
78 <SplineDoubleKeyFrame KeyTime="0" Value="1"/>
79 </DoubleAnimationUsingKeyFrames>
80 <StringAnimationUsingKeyFrames Storyboard.TargetProperty="(TextBlock.Text)" Storyboard.TargetName="MaximizeButtonLabel">
81 <DiscreteStringKeyFrame KeyTime="0:0:0.0" Value="2"/>
82 </StringAnimationUsingKeyFrames>
83 <StringAnimationUsingKeyFrames Storyboard.TargetProperty="ToolTip" Storyboard.TargetName="PART_MaximizeButton">
84 <DiscreteStringKeyFrame KeyTime="0:0:0.0" Value="Restore"/>
85 </StringAnimationUsingKeyFrames>
86 </Storyboard>
87 </VisualState>
88 </VisualStateGroup>
89 </VisualStateManager.VisualStateGroups>
90
91 <Border BorderBrush="{TemplateBinding BorderBrush}"
92 BorderThickness="{TemplateBinding BorderThickness}"
93 Background="{TemplateBinding Background}" />
94
95 <Grid Margin="15,10,15,0">
96 <Grid.RowDefinitions>
97 <RowDefinition x:Name="RowHeader" Height="50" />
98 <RowDefinition x:Name="RowToolbar" Height="Auto" />
99 <RowDefinition />
100 <RowDefinition x:Name="RowBody" Height="*" />
101 <RowDefinition x:Name="RowFooter" Height="Auto" />
102 </Grid.RowDefinitions>
103
104 <Grid Grid.Row="0">
105 <Grid.ColumnDefinitions>
106 <ColumnDefinition Width="*" />
107 <ColumnDefinition Width="Auto" />
108 </Grid.ColumnDefinitions>
109
110 <Rectangle x:Name="PART_Dragger"
111 Grid.Column="0" Grid.ColumnSpan="2"
112 Margin="3.5"
113 Fill="Transparent" />
114
115 <Grid Grid.Column="0"
116 IsHitTestVisible="False"
117 HorizontalAlignment="Left" VerticalAlignment="Center" Margin="3.5">
118
119 <Grid.RowDefinitions>
120 <RowDefinition Height="15" />
121 <RowDefinition Height="Auto" />
122 </Grid.RowDefinitions>
123
124 <ProgressBar x:Name="BrandBar" Grid.Row="0"
125 Minimum="0" Maximum="100"
126 Foreground="{StaticResource AccentColorBlueBrush}"
127 HorizontalAlignment="Left" VerticalAlignment="Bottom"
128 Width="250" Height="6" IsHitTestVisible="False"
129 Value="100" />
130
131 <TextBlock Grid.Row="1"
132 FontFamily="{StaticResource HeaderFontFamily}" FontSize="{StaticResource HeaderFontSize}" FontWeight="SemiBold"
133 Text="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Title}"
134 HorizontalAlignment="Left" VerticalAlignment="Center"
135 IsHitTestVisible="False" />
136 </Grid>
137
138 <Grid Grid.Column="1"
139 VerticalAlignment="Center">
140
141 <Grid.ColumnDefinitions>
142 <ColumnDefinition Width="Auto" />
143 <ColumnDefinition Width="Auto" />
144 <ColumnDefinition Width="Auto" />
145 </Grid.ColumnDefinitions>
146
147 <Button x:Name="PART_MinimizeButton" Grid.Column="0"
148 Style="{StaticResource MetroButtonStyle}"
149 Command="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=MinimizeCommand}"
150 VerticalAlignment="Center" Margin="1.5"
151 ToolTip="Minimize">
152 <TextBlock x:Name="MinimizeButtonLabel" TextWrapping="Wrap" Text="0" FontFamily="Webdings" FontSize="13.333" Foreground="{StaticResource TextBrush}" FontWeight="Normal" />
153 </Button>
154
155 <Button x:Name="PART_MaximizeButton" Grid.Column="1"
156 Style="{StaticResource MetroButtonStyle}"
157 FontFamily="Webdings" Foreground="#FF919191" FontSize="13.333" FontWeight="Normal"
158 Command="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=MaximizeCommand}"
159 VerticalAlignment="Center" Margin="1.5"
160 ToolTip="Maximize">
161 <TextBlock x:Name="MaximizeButtonLabel" TextWrapping="Wrap" Text="1" FontFamily="Webdings" FontSize="13.333" Foreground="{StaticResource TextBrush}" FontWeight="Normal" />
162 </Button>
163
164 <Button x:Name="PART_CloseButton" Grid.Column="2"
165 Style="{StaticResource MetroButtonStyle}"
166 FontFamily="Webdings" Foreground="#FF919191" FontSize="13.333" FontWeight="Normal"
167 Command="{Binding CloseCommand}"
168 VerticalAlignment="Center" Margin="1.5"
169 ToolTip="Close">
170 <TextBlock x:Name="CloseButtonLabel" TextWrapping="Wrap" Text="r" FontFamily="Webdings" FontSize="13.333" Foreground="{StaticResource TextBrush}" FontWeight="Normal" />
171 </Button>
172 </Grid>
173 </Grid>
174
175 <Grid Grid.Row="1">
176 <Grid.ColumnDefinitions>
177 <ColumnDefinition Width="*" />
178 <ColumnDefinition Width="Auto" />
179 </Grid.ColumnDefinitions>
180
181 <Grid Grid.Column="0">
182 <Grid.ColumnDefinitions>
183 <ColumnDefinition Width="Auto" />
184 <ColumnDefinition Width="Auto" />
185 <ColumnDefinition Width="Auto" />
186 <ColumnDefinition Width="Auto" />
187 <ColumnDefinition Width="20" />
188 <ColumnDefinition Width="Auto" />
189 <ColumnDefinition Width="Auto" />
190 <ColumnDefinition Width="Auto" />
191 <ColumnDefinition Width="Auto" />
192 <ColumnDefinition Width="Auto" />
193 <ColumnDefinition Width="Auto" />
194 </Grid.ColumnDefinitions>
195
196 <chronos:SplitButton x:Name="ActionsSplitButton"
197 Grid.Column="0"
198 Content="_actions"
199 FontSize="18" FontWeight="Light"
200 Placement="Bottom" VerticalAlignment="Center"
201 Width="Auto" Height="32" Margin="3.5">
202
203 <MenuItem Header="Inquiry"
204 Command="{Binding InquiryCommand}" />
205
206 <MenuItem Header="Edit"
207 Command="{Binding EditCommand}" />
208
209 <MenuItem Header="Remove"
210 Command="{Binding DeleteCommand}" />
211
212 <MenuItem Header="Save changes"
213 Command="{Binding SaveCommand}" />
214
215 <MenuItem Header="Discard changes"
216 Command="{Binding DiscardCommand}" />
217
218 <Separator Style="{StaticResource DefaultSeparatorStyle}" />
219
220 <MenuItem Header="Print preview ..."
221 Command="{Binding PrintPreviewCommand}" />
222
223 <MenuItem Header="Print ..."
224 Command="{Binding PrintCommand}" />
225
226 <Separator Style="{StaticResource DefaultSeparatorStyle}" />
227
228 <MenuItem Header="Close"
229 Command="{Binding CloseCommand}" />
230
231 </chronos:SplitButton>
232
233 <chronos:SplitButton x:Name="RelationsSplitButton"
234 Grid.Column="1"
235 FontSize="18" FontWeight="Light"
236 Content="_relations"
237 Placement="Bottom" VerticalAlignment="Center"
238 IsEnabled="{Binding HasRelations}"
239 Width="Auto" Height="Auto" Margin="3.5">
240
241 </chronos:SplitButton>
242
243 <chronos:SplitButton x:Name="ToolsSplitButton"
244 Grid.Column="2"
245 FontSize="18" FontWeight="Light"
246 Content="_tools"
247 Placement="Bottom" VerticalAlignment="Center"
248 Width="Auto" Height="32" Margin="3.5">
249
250 <MenuItem Header="New Window"
251 Command="{Binding NewWindowCommand}" />
252
253 <Separator Style="{StaticResource DefaultSeparatorStyle}" />
254
255 <MenuItem Header="Bookmarks">
256
257 <MenuItem Header="Organize bookmarks"
258 Command="{Binding OrganizeBookmarksCommand}"/>
259
260 <MenuItem Header="Bookmark current"
261 Command="{Binding BookmarkCurrentCommand}" />
262
263 <MenuItem Header="Clear bookmarks"
264 Command="{Binding ClearBookmarksCommand}" />
265
266 <MenuItem Header="Create shortcut"
267 Command="{Binding CreateShortcutCommand}">
268 </MenuItem>
269
270 </MenuItem>
271 </chronos:SplitButton>
272
273 <chronos:SplitButton x:Name="HelpSplitButton"
274 Grid.Column="3"
275 FontSize="18" FontWeight="Light"
276 Content="_help"
277 Placement="Bottom" VerticalAlignment="Center"
278 Width="Auto" Height="32"
279 Margin="3.5">
280
281 <MenuItem Header="Show zoom window"
282 IsChecked="{Binding ShowZoomWindow}"
283 Command="{Binding ShowZoomWindowCommand}"/>
284
285 <MenuItem Header="Show form help"
286 Command="{Binding ShowFormHelpCommand}" />
287
288 </chronos:SplitButton>
289
290 <Button Grid.Column="5"
291 Style="{StaticResource MetroButtonStyle}"
292 FontSize="16" FontWeight="SemiBold"
293 VerticalAlignment="Center" Margin="3.5"
294 Command="{Binding InquiryCommand}"
295 Content="inquiry"
296 ToolTip="Inquiry">
297 </Button>
298
299 <Button Grid.Column="6"
300 Style="{StaticResource MetroButtonStyle}"
301 FontSize="16" FontWeight="SemiBold"
302 VerticalAlignment="Center" Margin="3.5"
303 Command="{Binding EditCommand}"
304 Content="edit"
305 ToolTip="Edit">
306 </Button>
307
308 <Button Grid.Column="7"
309 Style="{StaticResource MetroButtonStyle}"
310 FontSize="16" FontWeight="SemiBold"
311 VerticalAlignment="Center" Margin="3.5"
312 Command="{Binding DeleteCommand}"
313 Content="remove"
314 ToolTip="Remove">
315 </Button>
316
317 <Button Grid.Column="8"
318 Style="{StaticResource MetroButtonStyle}"
319 FontSize="16" FontWeight="SemiBold"
320 VerticalAlignment="Center" Margin="3.5"
321 Command="{Binding SaveCommand}"
322 Content="save"
323 ToolTip="Save changes">
324 </Button>
325
326 <Button Grid.Column="9"
327 Style="{StaticResource MetroButtonStyle}"
328 FontSize="16" FontWeight="SemiBold"
329 VerticalAlignment="Center" Margin="3.5"
330 Command="{Binding DiscardCommand}"
331 IsCancel="True"
332 Content="discard"
333 ToolTip="Discard changes">
334 </Button>
335
336 <Button Grid.Column="10"
337 Style="{StaticResource MetroButtonStyle}"
338 FontSize="16" FontWeight="SemiBold"
339 VerticalAlignment="Center" Margin="3.5"
340 Command="{Binding PrintCommand}"
341 Content="print"
342 ToolTip="Print">
343 </Button>
344 </Grid>
345
346 <Grid Grid.Column="1">
347 <Button Style="{StaticResource HyperlinkButtonStyle}"
348 FontSize="16" FontWeight="SemiBold"
349 HorizontalAlignment="Right" VerticalAlignment="Center" Margin="3.5"
350 Command="{Binding ShowZoomWindowCommand}"
351 Content="zoom"
352 ToolTip="Show zoom window">
353 </Button>
354 </Grid>
355 </Grid>
356
357 <chronos:HeaderNotification Grid.Row="2" Panel.ZIndex="99"
358 MessageText="{Binding NotificationMessage}"
359 VerticalAlignment="Top" />
360
361 <Grid Grid.Row="3">
362 <ContentPresenter x:Name="PART_ContentPresenter"
363 RenderTransformOrigin="0.5,0.5"
364 Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}"
365 HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}">
366
367 <ContentPresenter.LayoutTransform>
368 <ScaleTransform ScaleX="{Binding Value, Mode=TwoWay, Converter={StaticResource ZoomTransformConverter}, ElementName=ZoomSlider}"
369 ScaleY="{Binding Value, Mode=TwoWay, Converter={StaticResource ZoomTransformConverter}, ElementName=ZoomSlider}" />
370 </ContentPresenter.LayoutTransform>
371
372 </ContentPresenter>
373 </Grid>
374
375 <Grid Grid.Row="4">
376 <TextBlock x:Name="StatusMessage"
377 Margin="3.5"
378 VerticalAlignment="Center" HorizontalAlignment="Stretch"
379 FontSize="{StaticResource ControlContentFontSize}"
380 Text="{Binding StatusMessage}" ToolTip="{Binding StatusMessage}" />
381 </Grid>
382
383 <Popup x:Name="ZoomView"
384 AllowsTransparency="True"
385 Width="300" Height="120"
386 Focusable="True" StaysOpen="False" IsOpen="{Binding ShowZoomWindow}"
387 Placement="Center" PlacementTarget="{Binding ElementName=Root}" PopupAnimation="Slide">
388
389 <Border Margin="5,5,5,5" CornerRadius="3,3,3,3" Effect="{StaticResource DropShadowBrush}" Background="{StaticResource WindowBackgroundBrush}">
390 <Grid Margin="5">
391 <Grid.RowDefinitions>
392 <RowDefinition Height="Auto" />
393 <RowDefinition Height="*" />
394 <RowDefinition Height="Auto" />
395 </Grid.RowDefinitions>
396
397 <StackPanel Grid.Row="0"
398 Orientation="Horizontal" HorizontalAlignment="Right" VerticalAlignment="Center">
399
400 <Button x:Name="ZoomViewCloseButton"
401 Command="{Binding ShowZoomWindowCommand}"
402 VerticalAlignment="Center"
403 Margin="3.5"
404 Style="{StaticResource MetroButtonStyle}"
405 ToolTip="Close">
406 <TextBlock TextWrapping="Wrap" Text="r" FontFamily="Webdings" Foreground="#FF919191" FontSize="13.333" />
407 </Button>
408
409 </StackPanel>
410
411 <Slider x:Name="ZoomSlider"
412 Grid.Row="1"
413 Minimum="50" Maximum="250"
414 SmallChange="10" LargeChange="10"
415 IsMoveToPointEnabled="True" IsSnapToTickEnabled="True"
416 Interval="10" TickFrequency="10" TickPlacement="Both"
417 Value="{Binding ZoomLevel, Mode=TwoWay, FallbackValue=100}"
418 HorizontalAlignment="Stretch" VerticalAlignment="Center" />
419
420 <TextBlock Grid.Row="2"
421 Text="{Binding Value, ElementName=ZoomSlider, StringFormat=\{0\}%}"
422 HorizontalAlignment="Center"
423 VerticalAlignment="Center" />
424
425 </Grid>
426 </Border>
427 </Popup>
428 </Grid>
429 </Grid>
430
431 <ControlTemplate.Triggers>
432 <Trigger Property="IsActive" Value="False">
433 <Setter TargetName="BrandBar" Property="Foreground" Value="{StaticResource AccentColorRedBrush}" />
434 <Setter TargetName="ActionsSplitButton" Property="IsEnabled" Value="False" />
435 <Setter TargetName="RelationsSplitButton" Property="IsEnabled" Value="False" />
436 <Setter TargetName="ToolsSplitButton" Property="IsEnabled" Value="False" />
437 <Setter TargetName="HelpSplitButton" Property="IsEnabled" Value="False" />
438 </Trigger>
439
440 <Trigger Property="ViewMode" Value="Busy">
441 <Setter TargetName="BrandBar" Property="IsIndeterminate" Value="True" />
442 </Trigger>
443
444 <Trigger Property="ShowCloseButton" Value="False">
445 <Setter TargetName="PART_CloseButton" Property="Visibility" Value="Collapsed" />
446 </Trigger>
447
448 <Trigger Property="ShowMinimizeButton" Value="False">
449 <Setter TargetName="PART_MinimizeButton" Property="Visibility" Value="Collapsed" />
450 </Trigger>
451
452 <Trigger Property="ShowMaximizeButton" Value="False">
453 <Setter TargetName="PART_MaximizeButton" Property="Visibility" Value="Collapsed" />
454 </Trigger>
455 </ControlTemplate.Triggers>
456 </ControlTemplate>
457 </Setter.Value>
458 </Setter>
459 </Style>
460
461 <!-- Default Window Style -->
462 <Style x:Key="DefaultWindowStyle" TargetType="{x:Type chronos:WindowElement}">
463 <Setter Property="Id" Value="{Binding Id}" />
464 <Setter Property="FontSize" Value="{StaticResource ContentFontSize}"/>
465 <Setter Property="FocusVisualStyle" Value="{x:Null}" />
466 <Setter Property="Background" Value="{StaticResource WindowBackgroundBrush}" />
467 <Setter Property="BorderBrush" Value="{StaticResource ControlBorderBrush}" />
468 <Setter Property="BorderThickness" Value="1" />
469 <Setter Property="WindowState" Value="Normal" />
470 <Setter Property="Visibility" Value="Visible" />
471 <Setter Property="HorizontalContentAlignment" Value="Stretch" />
472 <Setter Property="VerticalContentAlignment" Value="Stretch" />
473 <Setter Property="AllowDrop" Value="False" />
474 <Setter Property="CanDrag" Value="True" />
475 <Setter Property="CanResize" Value="False" />
476 <Setter Property="ShowMinimizeButton" Value="True" />
477 <Setter Property="ShowMaximizeButton" Value="True" />
478 <Setter Property="ShowCloseButton" Value="True" />
479 <Setter Property="ViewMode" Value="{Binding ViewMode}" />
480 <Setter Property="Title" Value="Sample Window" />
481 <Setter Property="Template">
482 <Setter.Value>
483 <ControlTemplate TargetType="{x:Type chronos:WindowElement}">
484 <Grid x:Name="Root">
485 <VisualStateManager.VisualStateGroups>
486 <VisualStateGroup x:Name="WindowState">
487 <VisualState x:Name="Normal">
488 <Storyboard>
489 <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Visibility">
490 <DiscreteObjectKeyFrame KeyTime="0">
491 <DiscreteObjectKeyFrame.Value>
492 <Visibility>Visible</Visibility>
493 </DiscreteObjectKeyFrame.Value>
494 </DiscreteObjectKeyFrame>
495 </ObjectAnimationUsingKeyFrames>
496 <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity">
497 <SplineDoubleKeyFrame KeyTime="0" Value="1"/>
498 </DoubleAnimationUsingKeyFrames>
499 </Storyboard>
500 </VisualState>
501 <VisualState x:Name="Minimized">
502 <Storyboard>
503 <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity">
504 <SplineDoubleKeyFrame KeyTime="0" Value="0"/>
505 </DoubleAnimationUsingKeyFrames>
506 <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Visibility">
507 <DiscreteObjectKeyFrame KeyTime="0">
508 <DiscreteObjectKeyFrame.Value>
509 <Visibility>Collapsed</Visibility>
510 </DiscreteObjectKeyFrame.Value>
511 </DiscreteObjectKeyFrame>
512 </ObjectAnimationUsingKeyFrames>
513 </Storyboard>
514 </VisualState>
515 <VisualState x:Name="Maximized">
516 <Storyboard>
517 <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Visibility">
518 <DiscreteObjectKeyFrame KeyTime="0">
519 <DiscreteObjectKeyFrame.Value>
520 <Visibility>Visible</Visibility>
521 </DiscreteObjectKeyFrame.Value>
522 </DiscreteObjectKeyFrame>
523 </ObjectAnimationUsingKeyFrames>
524 <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity">
525 <SplineDoubleKeyFrame KeyTime="0" Value="1"/>
526 </DoubleAnimationUsingKeyFrames>
527 <StringAnimationUsingKeyFrames Storyboard.TargetProperty="(TextBlock.Text)" Storyboard.TargetName="MaximizeButtonLabel">
528 <DiscreteStringKeyFrame KeyTime="0:0:0.0" Value="2"/>
529 </StringAnimationUsingKeyFrames>
530 <StringAnimationUsingKeyFrames Storyboard.TargetProperty="ToolTip" Storyboard.TargetName="PART_MaximizeButton">
531 <DiscreteStringKeyFrame KeyTime="0:0:0.0" Value="Restore"/>
532 </StringAnimationUsingKeyFrames>
533 </Storyboard>
534 </VisualState>
535 </VisualStateGroup>
536 </VisualStateManager.VisualStateGroups>
537
538 <Border BorderBrush="{TemplateBinding BorderBrush}"
539 BorderThickness="{TemplateBinding BorderThickness}"
540 Background="{TemplateBinding Background}"
541 Effect="{StaticResource DropShadowBrush}"/>
542
543 <Grid Margin="20,16,20,5">
544 <Grid.RowDefinitions>
545 <RowDefinition x:Name="RowHeader" Height="Auto" />
546 <RowDefinition />
547 <RowDefinition x:Name="RowBody" Height="*" />
548 <RowDefinition x:Name="RowFooter" Height="Auto" />
549 </Grid.RowDefinitions>
550
551 <Grid Grid.Row="0">
552 <Grid.ColumnDefinitions>
553 <ColumnDefinition Width="*" />
554 <ColumnDefinition Width="Auto" />
555 </Grid.ColumnDefinitions>
556
557 <Rectangle x:Name="PART_Dragger"
558 Grid.Column="0" Grid.ColumnSpan="2"
559 Margin="3.5"
560 Fill="Transparent" />
561
562 <Grid Grid.Column="0"
563 IsHitTestVisible="False"
564 HorizontalAlignment="Left" VerticalAlignment="Center" Margin="3.5">
565
566 <Grid.RowDefinitions>
567 <RowDefinition Height="15" />
568 <RowDefinition Height="Auto" />
569 </Grid.RowDefinitions>
570
571 <ProgressBar x:Name="BrandBar" Grid.Row="0"
572 Minimum="0" Maximum="100"
573 Foreground="{StaticResource AccentColorBlueBrush}"
574 HorizontalAlignment="Left" VerticalAlignment="Bottom"
575 Width="250" Height="6" IsHitTestVisible="False"
576 Value="100" />
577
578 <TextBlock Grid.Row="1"
579 FontFamily="{StaticResource HeaderFontFamily}" FontSize="{StaticResource HeaderFontSize}" FontWeight="SemiBold"
580 Text="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Title}"
581 HorizontalAlignment="Left" VerticalAlignment="Center"
582 IsHitTestVisible="False" />
583 </Grid>
584
585 <Grid Grid.Column="1"
586 HorizontalAlignment="Right" VerticalAlignment="Center" Margin="3.5">
587
588 <Grid.ColumnDefinitions>
589 <ColumnDefinition Width="Auto" />
590 <ColumnDefinition Width="Auto" />
591 <ColumnDefinition Width="Auto" />
592 </Grid.ColumnDefinitions>
593
594 <Button x:Name="PART_MinimizeButton" Grid.Column="0"
595 Style="{StaticResource MetroButtonStyle}"
596 Command="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=MinimizeCommand}"
597 VerticalAlignment="Center" Margin="1.5"
598 ToolTip="Minimize">
599 <TextBlock x:Name="MinimizeButtonLabel" TextWrapping="Wrap" Text="0" FontFamily="Webdings" FontSize="13.333" Foreground="{StaticResource TextBrush}" FontWeight="Normal" />
600 </Button>
601
602 <Button x:Name="PART_MaximizeButton" Grid.Column="1"
603 Style="{StaticResource MetroButtonStyle}"
604 FontFamily="Webdings" Foreground="#FF919191" FontSize="13.333" FontWeight="Normal"
605 Command="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=MaximizeCommand}"
606 VerticalAlignment="Center" Margin="1.5"
607 ToolTip="Maximize">
608 <TextBlock x:Name="MaximizeButtonLabel" TextWrapping="Wrap" Text="1" FontFamily="Webdings" FontSize="13.333" Foreground="{StaticResource TextBrush}" FontWeight="Normal" />
609 </Button>
610
611 <Button x:Name="PART_CloseButton" Grid.Column="2"
612 Style="{StaticResource MetroButtonStyle}"
613 FontFamily="Webdings" Foreground="#FF919191" FontSize="13.333" FontWeight="Normal"
614 Command="{Binding CloseCommand}"
615 VerticalAlignment="Center" Margin="1.5"
616 ToolTip="Close">
617 <TextBlock x:Name="CloseButtonLabel" TextWrapping="Wrap" Text="r" FontFamily="Webdings" FontSize="13.333" Foreground="{StaticResource TextBrush}" FontWeight="Normal" />
618 </Button>
619 </Grid>
620 </Grid>
621
622 <chronos:HeaderNotification Grid.Row="1" Panel.ZIndex="99"
623 MessageText="{Binding NotificationMessage}"
624 VerticalAlignment="Top" />
625
626 <Grid Grid.Row="2">
627 <ContentPresenter x:Name="PART_ContentPresenter"
628 Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}"
629 HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}">
630 </ContentPresenter>
631 </Grid>
632
633 <Grid Grid.Row="3">
634 <TextBlock x:Name="StatusMessage"
635 Margin="3.5"
636 VerticalAlignment="Center" HorizontalAlignment="Stretch"
637 FontSize="{StaticResource ControlContentFontSize}"
638 Text="{Binding StatusMessage}" ToolTip="{Binding StatusMessage}" />
639 </Grid>
640 </Grid>
641 </Grid>
642
643 <ControlTemplate.Triggers>
644 <Trigger Property="IsActive" Value="False">
645 <Setter TargetName="BrandBar" Property="Foreground" Value="{StaticResource AccentColorRedBrush}" />
646 </Trigger>
647
648 <Trigger Property="ViewMode" Value="Busy">
649 <Setter TargetName="BrandBar" Property="IsIndeterminate" Value="True" />
650 </Trigger>
651
652 <Trigger Property="ShowMinimizeButton" Value="False">
653 <Setter TargetName="PART_MinimizeButton" Property="Visibility" Value="Collapsed" />
654 </Trigger>
655
656 <Trigger Property="ShowMaximizeButton" Value="False">
657 <Setter TargetName="PART_MaximizeButton" Property="Visibility" Value="Collapsed" />
658 </Trigger>
659
660 <Trigger Property="ShowCloseButton" Value="False">
661 <Setter TargetName="PART_CloseButton" Property="Visibility" Value="Collapsed" />
662 </Trigger>
663 </ControlTemplate.Triggers>
664 </ControlTemplate>
665 </Setter.Value>
666 </Setter>
667 </Style>
668
669 <!-- Default Dialog Window Style -->
670 <Style x:Key="DefaultDialogWindowStyle" TargetType="{x:Type chronos:WindowElement}" BasedOn="{StaticResource DefaultWindowStyle}">
671 <Setter Property="CanDrag" Value="False" />
672 <Setter Property="ShowMinimizeButton" Value="False" />
673 <Setter Property="ShowMaximizeButton" Value="False" />
674 <Setter Property="ShowCloseButton" Value="False" />
675 <Setter Property="Background" Value="{StaticResource GradientBackgroundBrush}" />
676 </Style>
677
678 <!-- Basic Window Style -->
679 <Style x:Key="BasicWindowStyle" TargetType="{x:Type chronos:WindowElement}">
680 <Setter Property="Id" Value="{Binding Id}" />
681 <Setter Property="FontSize" Value="{StaticResource ContentFontSize}"/>
682 <Setter Property="FocusVisualStyle" Value="{x:Null}" />
683 <Setter Property="Background" Value="{StaticResource WindowBackgroundBrush}" />
684 <Setter Property="BorderBrush" Value="{StaticResource ControlBorderBrush}" />
685 <Setter Property="BorderThickness" Value="1" />
686 <Setter Property="WindowState" Value="Normal" />
687 <Setter Property="Visibility" Value="Visible" />
688 <Setter Property="HorizontalContentAlignment" Value="Stretch" />
689 <Setter Property="VerticalContentAlignment" Value="Stretch" />
690 <Setter Property="AllowDrop" Value="False" />
691 <Setter Property="CanDrag" Value="True" />
692 <Setter Property="CanResize" Value="False" />
693 <Setter Property="ShowMinimizeButton" Value="True" />
694 <Setter Property="ShowMaximizeButton" Value="True" />
695 <Setter Property="ShowCloseButton" Value="True" />
696 <Setter Property="Title" Value="Sample Window" />
697 <Setter Property="Template">
698 <Setter.Value>
699 <ControlTemplate TargetType="{x:Type chronos:WindowElement}">
700 <Grid x:Name="Root">
701 <VisualStateManager.VisualStateGroups>
702 <VisualStateGroup x:Name="WindowState">
703 <VisualState x:Name="Normal">
704 <Storyboard>
705 <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Visibility">
706 <DiscreteObjectKeyFrame KeyTime="0">
707 <DiscreteObjectKeyFrame.Value>
708 <Visibility>Visible</Visibility>
709 </DiscreteObjectKeyFrame.Value>
710 </DiscreteObjectKeyFrame>
711 </ObjectAnimationUsingKeyFrames>
712 <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity">
713 <SplineDoubleKeyFrame KeyTime="0" Value="1"/>
714 </DoubleAnimationUsingKeyFrames>
715 </Storyboard>
716 </VisualState>
717 <VisualState x:Name="Minimized">
718 <Storyboard>
719 <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity">
720 <SplineDoubleKeyFrame KeyTime="0" Value="0"/>
721 </DoubleAnimationUsingKeyFrames>
722 <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Visibility">
723 <DiscreteObjectKeyFrame KeyTime="0">
724 <DiscreteObjectKeyFrame.Value>
725 <Visibility>Collapsed</Visibility>
726 </DiscreteObjectKeyFrame.Value>
727 </DiscreteObjectKeyFrame>
728 </ObjectAnimationUsingKeyFrames>
729 </Storyboard>
730 </VisualState>
731 <VisualState x:Name="Maximized">
732 <Storyboard>
733 <ObjectAnimationUsingKeyFrames Duration="0" Storyboard.TargetProperty="Visibility">
734 <DiscreteObjectKeyFrame KeyTime="0">
735 <DiscreteObjectKeyFrame.Value>
736 <Visibility>Visible</Visibility>
737 </DiscreteObjectKeyFrame.Value>
738 </DiscreteObjectKeyFrame>
739 </ObjectAnimationUsingKeyFrames>
740 <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity">
741 <SplineDoubleKeyFrame KeyTime="0" Value="1"/>
742 </DoubleAnimationUsingKeyFrames>
743 <StringAnimationUsingKeyFrames Storyboard.TargetProperty="(TextBlock.Text)" Storyboard.TargetName="MaximizeButtonLabel">
744 <DiscreteStringKeyFrame KeyTime="0:0:0.0" Value="2"/>
745 </StringAnimationUsingKeyFrames>
746 <StringAnimationUsingKeyFrames Storyboard.TargetProperty="ToolTip" Storyboard.TargetName="PART_MaximizeButton">
747 <DiscreteStringKeyFrame KeyTime="0:0:0.0" Value="Restore"/>
748 </StringAnimationUsingKeyFrames>
749 </Storyboard>
750 </VisualState>
751 </VisualStateGroup>
752 </VisualStateManager.VisualStateGroups>
753
754 <Border BorderBrush="{TemplateBinding BorderBrush}"
755 BorderThickness="{TemplateBinding BorderThickness}"
756 Background="{TemplateBinding Background}"
757 Effect="{StaticResource DropShadowBrush}"/>
758
759 <Grid Margin="20,16,20,5">
760 <Grid.RowDefinitions>
761 <RowDefinition x:Name="RowHeader" Height="Auto" />
762 <RowDefinition Height="20" />
763 <RowDefinition x:Name="RowBody" Height="*" />
764 <RowDefinition Height="20" />
765 </Grid.RowDefinitions>
766
767 <Grid Grid.Row="0">
768 <Grid.ColumnDefinitions>
769 <ColumnDefinition Width="*" />
770 <ColumnDefinition Width="Auto" />
771 </Grid.ColumnDefinitions>
772
773 <Rectangle x:Name="PART_Dragger"
774 Grid.Column="0" Grid.ColumnSpan="2"
775 Margin="3.5"
776 Fill="Transparent" />
777
778 <Grid Grid.Column="0"
779 IsHitTestVisible="False"
780 HorizontalAlignment="Left" VerticalAlignment="Center" Margin="3.5">
781
782 <Grid.RowDefinitions>
783 <RowDefinition Height="15" />
784 <RowDefinition Height="Auto" />
785 </Grid.RowDefinitions>
786
787 <ProgressBar x:Name="BrandBar" Grid.Row="0"
788 Minimum="0" Maximum="100"
789 Foreground="{StaticResource AccentColorBlueBrush}"
790 HorizontalAlignment="Left" VerticalAlignment="Bottom"
791 Width="250" Height="6" IsHitTestVisible="False"
792 Value="100" />
793
794 <TextBlock Grid.Row="1"
795 FontFamily="{StaticResource HeaderFontFamily}" FontSize="{StaticResource HeaderFontSize}" FontWeight="SemiBold"
796 Text="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Title}"
797 HorizontalAlignment="Left" VerticalAlignment="Center"
798 IsHitTestVisible="False" />
799 </Grid>
800
801 <Grid Grid.Column="1"
802 HorizontalAlignment="Right" VerticalAlignment="Center" Margin="3.5">
803
804 <Grid.ColumnDefinitions>
805 <ColumnDefinition Width="Auto" />
806 <ColumnDefinition Width="Auto" />
807 <ColumnDefinition Width="Auto" />
808 </Grid.ColumnDefinitions>
809
810 <Button x:Name="PART_MinimizeButton" Grid.Column="0"
811 Style="{StaticResource MetroButtonStyle}"
812 Command="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=MinimizeCommand}"
813 VerticalAlignment="Center" Margin="1.5"
814 ToolTip="Minimize">
815 <TextBlock x:Name="MinimizeButtonLabel" TextWrapping="Wrap" Text="0" FontFamily="Webdings" FontSize="13.333" Foreground="{StaticResource TextBrush}" FontWeight="Normal" />
816 </Button>
817
818 <Button x:Name="PART_MaximizeButton" Grid.Column="1"
819 Style="{StaticResource MetroButtonStyle}"
820 FontFamily="Webdings" Foreground="#FF919191" FontSize="13.333" FontWeight="Normal"
821 Command="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=MaximizeCommand}"
822 VerticalAlignment="Center" Margin="1.5"
823 ToolTip="Maximize">
824 <TextBlock x:Name="MaximizeButtonLabel" TextWrapping="Wrap" Text="1" FontFamily="Webdings" FontSize="13.333" Foreground="{StaticResource TextBrush}" FontWeight="Normal" />
825 </Button>
826
827 <Button x:Name="PART_CloseButton" Grid.Column="2"
828 Style="{StaticResource MetroButtonStyle}"
829 FontFamily="Webdings" Foreground="#FF919191" FontSize="13.333" FontWeight="Normal"
830 Command="{Binding CloseCommand}"
831 VerticalAlignment="Center" Margin="1.5"
832 ToolTip="Close">
833 <TextBlock x:Name="CloseButtonLabel" TextWrapping="Wrap" Text="r" FontFamily="Webdings" FontSize="13.333" Foreground="{StaticResource TextBrush}" FontWeight="Normal" />
834 </Button>
835 </Grid>
836 </Grid>
837
838 <Grid Grid.Row="2">
839 <ContentPresenter x:Name="PART_ContentPresenter"
840 Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}"
841 HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}">
842 </ContentPresenter>
843 </Grid>
844 </Grid>
845 </Grid>
846
847 <ControlTemplate.Triggers>
848 <Trigger Property="IsActive" Value="False">
849 <Setter TargetName="BrandBar" Property="Foreground" Value="{StaticResource AccentColorRedBrush}" />
850 </Trigger>
851
852 <Trigger Property="ViewMode" Value="Busy">
853 <Setter TargetName="BrandBar" Property="IsIndeterminate" Value="True" />
854 </Trigger>
855
856 <Trigger Property="ShowMinimizeButton" Value="False">
857 <Setter TargetName="PART_MinimizeButton" Property="Visibility" Value="Collapsed" />
858 </Trigger>
859
860 <Trigger Property="ShowMaximizeButton" Value="False">
861 <Setter TargetName="PART_MaximizeButton" Property="Visibility" Value="Collapsed" />
862 </Trigger>
863
864 <Trigger Property="ShowCloseButton" Value="False">
865 <Setter TargetName="PART_CloseButton" Property="Visibility" Value="Collapsed" />
866 </Trigger>
867 </ControlTemplate.Triggers>
868 </ControlTemplate>
869 </Setter.Value>
870 </Setter>
871 </Style>
872
873 <!-- Basic Dialog Window Style -->
874 <Style x:Key="BasicDialogWindowStyle" TargetType="{x:Type chronos:WindowElement}" BasedOn="{StaticResource BasicWindowStyle}">
875 <Setter Property="CanDrag" Value="False" />
876 <Setter Property="ShowMinimizeButton" Value="False" />
877 <Setter Property="ShowMaximizeButton" Value="False" />
878 <Setter Property="ShowCloseButton" Value="False" />
879 <Setter Property="Background" Value="{StaticResource GradientBackgroundBrush}" />
880 </Style>
881
882 <!-- Message Window Style -->
883 <Style TargetType="{x:Type chronos:MessageWindowElement}">
884 <Setter Property="FocusVisualStyle" Value="{x:Null}" />
885 <Setter Property="Background" Value="{StaticResource GradientBackgroundBrush}" />
886 <Setter Property="BorderBrush" Value="{StaticResource ControlBorderBrush}" />
887 <Setter Property="BorderThickness" Value="1" />
888 <Setter Property="WindowState" Value="Normal" />
889 <Setter Property="Visibility" Value="Visible" />
890 <Setter Property="HorizontalContentAlignment" Value="Center" />
891 <Setter Property="VerticalContentAlignment" Value="Center" />
892 <Setter Property="AllowDrop" Value="False" />
893 <Setter Property="CanDrag" Value="False" />
894 <Setter Property="CanResize" Value="False" />
895 <Setter Property="ShowMinimizeButton" Value="False" />
896 <Setter Property="ShowMaximizeButton" Value="False" />
897 <Setter Property="ShowCloseButton" Value="False" />
898 <Setter Property="Title" Value="Sample Window" />
899 <Setter Property="Template">
900 <Setter.Value>
901 <ControlTemplate TargetType="{x:Type chronos:MessageWindowElement}">
902 <Grid x:Name="Root">
903
904 <Border BorderBrush="{TemplateBinding BorderBrush}"
905 BorderThickness="{TemplateBinding BorderThickness}"
906 Background="{TemplateBinding Background}"
907 Effect="{StaticResource DropShadowBrush}"/>
908
909 <Grid Margin="30,16,30,30">
910 <Grid.RowDefinitions>
911 <RowDefinition x:Name="RowHeader" Height="Auto" />
912 <RowDefinition Height="15" />
913 <RowDefinition x:Name="RowBody" Height="*" />
914 <RowDefinition x:Name="RowFooter" Height="Auto" />
915 </Grid.RowDefinitions>
916
917 <Grid Grid.Row="0">
918 <Grid.ColumnDefinitions>
919 <ColumnDefinition Width="*" />
920 <ColumnDefinition Width="Auto" />
921 </Grid.ColumnDefinitions>
922
923 <Rectangle x:Name="PART_Dragger"
924 Grid.Column="0" Grid.ColumnSpan="2"
925 Margin="3.5"
926 Fill="Transparent" />
927
928 <Grid Grid.Column="0"
929 IsHitTestVisible="False"
930 HorizontalAlignment="Left" VerticalAlignment="Center" Margin="3.5">
931
932 <Grid.RowDefinitions>
933 <RowDefinition Height="15" />
934 <RowDefinition Height="Auto" />
935 </Grid.RowDefinitions>
936
937 <Rectangle Grid.Row="0"
938 VerticalAlignment="Bottom" HorizontalAlignment="Left"
939 Fill="{StaticResource AccentColorBlueBrush}"
940 Width="109" Height="6"
941 IsHitTestVisible="False" />
942
943 <TextBlock Grid.Row="1"
944 FontFamily="{StaticResource HeaderFontFamily}" FontSize="{StaticResource HeaderFontSize}" FontWeight="SemiBold"
945 Text="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Title}"
946 HorizontalAlignment="Left" VerticalAlignment="Center"
947 IsHitTestVisible="False" />
948 </Grid>
949
950 <Grid Grid.Column="1"
951 HorizontalAlignment="Right" VerticalAlignment="Center" Margin="3.5"
952 Visibility="Collapsed">
953
954 <Grid.ColumnDefinitions>
955 <ColumnDefinition Width="Auto" />
956 <ColumnDefinition Width="Auto" />
957 <ColumnDefinition Width="Auto" />
958 </Grid.ColumnDefinitions>
959
960 <Button x:Name="PART_MinimizeButton" Grid.Column="0"
961 Style="{StaticResource MetroButtonStyle}"
962 Command="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=MinimizeCommand}"
963 VerticalAlignment="Center" Margin="1.5"
964 ToolTip="Minimize">
965 <TextBlock x:Name="MinimizeButtonLabel" TextWrapping="Wrap" Text="0" FontFamily="Webdings" FontSize="13.333" Foreground="{StaticResource TextBrush}" FontWeight="Normal" />
966 </Button>
967
968 <Button x:Name="PART_MaximizeButton" Grid.Column="1"
969 Style="{StaticResource MetroButtonStyle}"
970 FontFamily="Webdings" Foreground="#FF919191" FontSize="13.333" FontWeight="Normal"
971 Command="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=MaximizeCommand}"
972 VerticalAlignment="Center" Margin="1.5"
973 ToolTip="Maximize">
974 <TextBlock x:Name="MaximizeButtonLabel" TextWrapping="Wrap" Text="1" FontFamily="Webdings" FontSize="13.333" Foreground="{StaticResource TextBrush}" FontWeight="Normal" />
975 </Button>
976
977 <Button x:Name="PART_CloseButton" Grid.Column="2"
978 Style="{StaticResource MetroButtonStyle}"
979 FontFamily="Webdings" Foreground="#FF919191" FontSize="13.333" FontWeight="Normal"
980 Command="{Binding CloseCommand}"
981 VerticalAlignment="Center" Margin="1.5"
982 ToolTip="Close">
983 <TextBlock x:Name="CloseButtonLabel" TextWrapping="Wrap" Text="r" FontFamily="Webdings" FontSize="13.333" Foreground="{StaticResource TextBrush}" FontWeight="Normal" />
984 </Button>
985 </Grid>
986 </Grid>
987
988 <Grid Grid.Row="2">
989 <ContentControl FontSize="{StaticResource ContentFontSize}" FontWeight="SemiBold">
990 <ContentPresenter x:Name="PART_ContentPresenter"
991 Content="{TemplateBinding Content}"
992 ContentTemplate="{TemplateBinding ContentTemplate}"
993 HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}">
994 </ContentPresenter>
995 </ContentControl>
996 </Grid>
997
998 <Grid Grid.Row="3">
999 <StackPanel x:Name="ButtonsPanel"
1000 Orientation="Horizontal" VerticalAlignment="Center" HorizontalAlignment="Right">
1001
1002 <Button x:Name="AcceptButton"
1003 Style="{StaticResource HyperlinkButtonStyle}"
1004 Margin="3.5" Padding="2"
1005 Command="chronos:MessageWindowElement.AcceptCommand" IsDefault="True" />
1006
1007 <Button x:Name="CancelButton"
1008 Margin="3.5" Padding="2"
1009 Style="{StaticResource HyperlinkButtonStyle}"
1010 Command="chronos:MessageWindowElement.CancelCommand" IsCancel="True" />
1011
1012 </StackPanel>
1013 </Grid>
1014 </Grid>
1015 </Grid>
1016
1017 <ControlTemplate.Triggers>
1018 <Trigger Property="Buttons" Value="OKCancel">
1019 <Setter TargetName="AcceptButton" Property="Content" Value="Aceptar" />
1020 <Setter TargetName="CancelButton" Property="Content" Value="Cancelar" />
1021 </Trigger>
1022 <Trigger Property="Buttons" Value="YesNo">
1023 <Setter TargetName="AcceptButton" Property="Content" Value="Sí" />
1024 <Setter TargetName="CancelButton" Property="Content" Value="No" />
1025 </Trigger>
1026 <Trigger Property="Buttons" Value="Ok">
1027 <Setter TargetName="ButtonsPanel" Property="HorizontalAlignment" Value="Center" />
1028 <Setter TargetName="AcceptButton" Property="Content" Value="Aceptar" />
1029 <Setter TargetName="CancelButton" Property="Visibility" Value="Collapsed" />
1030 </Trigger>
1031
1032 <Trigger Property="ShowMinimizeButton" Value="False">
1033 <Setter TargetName="PART_MinimizeButton" Property="Visibility" Value="Collapsed" />
1034 </Trigger>
1035
1036 <Trigger Property="ShowMaximizeButton" Value="False">
1037 <Setter TargetName="PART_MaximizeButton" Property="Visibility" Value="Collapsed" />
1038 </Trigger>
1039
1040 <Trigger Property="ShowCloseButton" Value="False">
1041 <Setter TargetName="PART_CloseButton" Property="Visibility" Value="Collapsed" />
1042 </Trigger>
1043 </ControlTemplate.Triggers>
1044 </ControlTemplate>
1045 </Setter.Value>
1046 </Setter>
1047 </Style>
1048
1049 </ResourceDictionary>