|
|
|
@ -2,10 +2,11 @@ |
|
|
|
|
|
|
|
Toolkit for WPF |
|
|
|
|
|
|
|
Copyright (C) 2007-2019 Xceed Software Inc. |
|
|
|
Copyright (C) 2007-2020 Xceed Software Inc. |
|
|
|
|
|
|
|
This program is provided to you under the terms of the Microsoft Public |
|
|
|
License (Ms-PL) as published at https://github.com/xceedsoftware/wpftoolkit/blob/master/license.md |
|
|
|
This program is provided to you under the terms of the XCEED SOFTWARE, INC. |
|
|
|
COMMUNITY LICENSE AGREEMENT (for non-commercial use) as published at |
|
|
|
https://github.com/xceedsoftware/wpftoolkit/blob/master/license.md |
|
|
|
|
|
|
|
For more features, controls, and fast professional support, |
|
|
|
pick up the Plus Edition at https://xceed.com/xceed-toolkit-plus-for-wpf/ |
|
|
|
@ -16,13 +17,11 @@ |
|
|
|
|
|
|
|
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" |
|
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
|
|
|
xmlns:localThemes="clr-namespace:Xceed.Wpf.AvalonDock.Themes" |
|
|
|
xmlns:shell="clr-namespace:Microsoft.Windows.Shell;assembly=Xceed.Wpf.AvalonDock" |
|
|
|
xmlns:avalonDock="clr-namespace:Xceed.Wpf.AvalonDock;assembly=Xceed.Wpf.AvalonDock" |
|
|
|
xmlns:avalonDockLayout="clr-namespace:Xceed.Wpf.AvalonDock.Layout;assembly=Xceed.Wpf.AvalonDock" |
|
|
|
xmlns:avalonDockControls="clr-namespace:Xceed.Wpf.AvalonDock.Controls;assembly=Xceed.Wpf.AvalonDock" |
|
|
|
xmlns:avalonDockConverters="clr-namespace:Xceed.Wpf.AvalonDock.Converters;assembly=Xceed.Wpf.AvalonDock" |
|
|
|
xmlns:avalonDockProperties="clr-namespace:Xceed.Wpf.AvalonDock.Properties;assembly=Xceed.Wpf.AvalonDock"> |
|
|
|
xmlns:shell="http://schemas.xceed.com/wpf/xaml/avalondock" |
|
|
|
xmlns:avalonDock="http://schemas.xceed.com/wpf/xaml/avalondock" |
|
|
|
xmlns:avalonDockControls="http://schemas.xceed.com/wpf/xaml/avalondock" |
|
|
|
xmlns:avalonDockConverters="http://schemas.xceed.com/wpf/xaml/avalondock" |
|
|
|
xmlns:avalonDockProperties="http://schemas.xceed.com/wpf/xaml/avalondock"> |
|
|
|
|
|
|
|
<ResourceDictionary.MergedDictionaries> |
|
|
|
<ResourceDictionary Source="Brushes.xaml" /> |
|
|
|
@ -41,6 +40,10 @@ |
|
|
|
<avalonDockControls:LayoutDocumentControl Model="{Binding}" /> |
|
|
|
</DataTemplate> |
|
|
|
|
|
|
|
<DataTemplate x:Key="AnchorablePaneControlContentTemplate"> |
|
|
|
<avalonDockControls:LayoutAnchorableControl Model="{Binding}" /> |
|
|
|
</DataTemplate> |
|
|
|
|
|
|
|
<Style x:Key="AvalonDock_ThemeMetro_ToolButtonStyle" |
|
|
|
TargetType="ToggleButton"> |
|
|
|
<Setter Property="Background" |
|
|
|
@ -116,7 +119,8 @@ |
|
|
|
IsItemsHost="true" |
|
|
|
Margin="2,0,2,0" |
|
|
|
Grid.Row="0" |
|
|
|
KeyboardNavigation.TabIndex="1" /> |
|
|
|
KeyboardNavigation.TabIndex="1" |
|
|
|
KeyboardNavigation.DirectionalNavigation="Cycle" /> |
|
|
|
<avalonDockControls:DropDownButton x:Name="MenuDropDownButton" |
|
|
|
Style="{StaticResource AvalonDock_ThemeMetro_ToolButtonStyle}" |
|
|
|
Focusable="False" |
|
|
|
@ -159,6 +163,7 @@ |
|
|
|
Padding="0,1,0,2"> |
|
|
|
<ContentPresenter x:Name="PART_SelectedContentHost" |
|
|
|
ContentSource="SelectedContent" |
|
|
|
ContentTemplate="{TemplateBinding ContentTemplate}" |
|
|
|
Margin="0,2,0,2" |
|
|
|
SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" /> |
|
|
|
</Border> |
|
|
|
@ -224,8 +229,7 @@ |
|
|
|
<Border x:Name="Bd" |
|
|
|
BorderBrush="{TemplateBinding BorderBrush}" |
|
|
|
BorderThickness="0,3,0,0" |
|
|
|
Background="{TemplateBinding Background}" |
|
|
|
Padding="{TemplateBinding Padding}"> |
|
|
|
Background="{TemplateBinding Background}"> |
|
|
|
</Border> |
|
|
|
<ContentPresenter x:Name="Content" |
|
|
|
Margin="2" |
|
|
|
@ -330,6 +334,7 @@ |
|
|
|
KeyboardNavigation.TabNavigation="Cycle"> |
|
|
|
<ContentPresenter x:Name="PART_SelectedContentHost" |
|
|
|
ContentSource="SelectedContent" |
|
|
|
ContentTemplate="{TemplateBinding ContentTemplate}" |
|
|
|
Margin="{TemplateBinding Padding}" |
|
|
|
SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" /> |
|
|
|
</Border> |
|
|
|
@ -338,6 +343,7 @@ |
|
|
|
IsItemsHost="true" |
|
|
|
Grid.Row="1" |
|
|
|
KeyboardNavigation.TabIndex="1" |
|
|
|
KeyboardNavigation.DirectionalNavigation="Cycle" |
|
|
|
Panel.ZIndex="1" /> |
|
|
|
</Grid> |
|
|
|
<ControlTemplate.Triggers> |
|
|
|
@ -378,8 +384,7 @@ |
|
|
|
BorderBrush="{TemplateBinding BorderBrush}" |
|
|
|
Margin="4" |
|
|
|
BorderThickness="0,2,0,0" |
|
|
|
Background="{TemplateBinding Background}" |
|
|
|
Padding="{TemplateBinding Padding}"> |
|
|
|
Background="{TemplateBinding Background}"> |
|
|
|
<ContentPresenter x:Name="Content" |
|
|
|
ContentSource="Header" |
|
|
|
HorizontalAlignment="{Binding HorizontalContentAlignment, RelativeSource={RelativeSource AncestorType={x:Type ItemsControl}}}" |
|
|
|
@ -446,13 +451,9 @@ |
|
|
|
</Setter.Value> |
|
|
|
</Setter> |
|
|
|
|
|
|
|
<Setter Property="ContentTemplate"> |
|
|
|
<Setter.Value> |
|
|
|
<DataTemplate> |
|
|
|
<avalonDockControls:LayoutAnchorableControl Model="{Binding}" /> |
|
|
|
</DataTemplate> |
|
|
|
</Setter.Value> |
|
|
|
</Setter> |
|
|
|
<Setter Property="ContentTemplate" |
|
|
|
Value="{StaticResource AnchorablePaneControlContentTemplate}" /> |
|
|
|
|
|
|
|
</Style> |
|
|
|
|
|
|
|
<Style TargetType="avalonDockControls:AnchorablePaneTitle"> |
|
|
|
@ -633,8 +634,8 @@ |
|
|
|
Padding="2"> |
|
|
|
<ContentPresenter TextElement.Foreground="{DynamicResource AvalonDock_ThemeMetro_BaseColor2}" |
|
|
|
Content="{Binding Model, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ContentTemplate="{Binding AnchorableHeaderTemplate, Mode=OneWay, RelativeSource={RelativeSource AncestorType={x:Type avalonDock:DockingManager}, Mode=FindAncestor}}" |
|
|
|
ContentTemplateSelector="{Binding AnchorableHeaderTemplateSelector, Mode=OneWay, RelativeSource={RelativeSource AncestorType={x:Type avalonDock:DockingManager}, Mode=FindAncestor}}" /> |
|
|
|
ContentTemplate="{Binding Model.Root.Manager.AnchorableHeaderTemplate, Mode=OneWay, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ContentTemplateSelector="{Binding Model.Root.Manager.AnchorableHeaderTemplateSelector, Mode=OneWay, RelativeSource={RelativeSource TemplatedParent}}" /> |
|
|
|
</Border> |
|
|
|
<ControlTemplate.Triggers> |
|
|
|
<Trigger Property="Side" |
|
|
|
@ -1180,12 +1181,15 @@ |
|
|
|
<Setter Property="Template"> |
|
|
|
<Setter.Value> |
|
|
|
<ControlTemplate TargetType="{x:Type avalonDockControls:LayoutDocumentTabItem}"> |
|
|
|
<!--Use a transparent background to hit for contextMenu popup--> |
|
|
|
<avalonDockControls:DropDownControlArea DropDownContextMenu="{Binding Root.Manager.DocumentContextMenu}" |
|
|
|
DropDownContextMenuDataContext="{Binding LayoutItem, RelativeSource={RelativeSource TemplatedParent}}"> |
|
|
|
DropDownContextMenuDataContext="{Binding LayoutItem, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
Background="Transparent"> |
|
|
|
<Border Background="{TemplateBinding Background}" |
|
|
|
BorderBrush="{TemplateBinding BorderBrush}" |
|
|
|
BorderThickness="{TemplateBinding BorderThickness}" |
|
|
|
Padding="0,2,0,1"> |
|
|
|
Padding="0,2,0,1" |
|
|
|
Margin="{Binding Padding, RelativeSource={RelativeSource AncestorType={x:Type TabItem}}}"> |
|
|
|
<Grid> |
|
|
|
<Grid.ColumnDefinitions> |
|
|
|
<ColumnDefinition Width="*" /> |
|
|
|
@ -1195,8 +1199,8 @@ |
|
|
|
<Border Grid.ColumnSpan="3" |
|
|
|
Background="Transparent" /> |
|
|
|
<ContentPresenter Content="{Binding Model, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ContentTemplate="{Binding DocumentHeaderTemplate, Mode=OneWay, RelativeSource={RelativeSource AncestorType={x:Type avalonDock:DockingManager}, Mode=FindAncestor}}" |
|
|
|
ContentTemplateSelector="{Binding DocumentHeaderTemplateSelector, Mode=OneWay, RelativeSource={RelativeSource AncestorType={x:Type avalonDock:DockingManager}, Mode=FindAncestor}}" /> |
|
|
|
ContentTemplate="{Binding Root.Manager.DocumentHeaderTemplate, Mode=OneWay}" |
|
|
|
ContentTemplateSelector="{Binding Root.Manager.DocumentHeaderTemplateSelector, Mode=OneWay}" /> |
|
|
|
<!-- Close button should be moved out to the container style --> |
|
|
|
<Button x:Name="DocumentCloseButton" |
|
|
|
Style="{StaticResource AvalonDock_ThemeMetro_ButtonStyle}" |
|
|
|
@ -1277,19 +1281,18 @@ |
|
|
|
<Setter Property="Template"> |
|
|
|
<Setter.Value> |
|
|
|
<ControlTemplate TargetType="{x:Type avalonDockControls:LayoutAnchorableTabItem}"> |
|
|
|
<!--Use a transparent background to hit for contextMenu popup--> |
|
|
|
<avalonDockControls:DropDownControlArea DropDownContextMenu="{Binding Root.Manager.AnchorableContextMenu}" |
|
|
|
DropDownContextMenuDataContext="{Binding LayoutItem, RelativeSource={RelativeSource TemplatedParent}}"> |
|
|
|
DropDownContextMenuDataContext="{Binding LayoutItem, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
Background="Transparent"> |
|
|
|
<Border Background="{TemplateBinding Background}" |
|
|
|
BorderBrush="{TemplateBinding BorderBrush}" |
|
|
|
BorderThickness="{TemplateBinding BorderThickness}"> |
|
|
|
BorderThickness="{TemplateBinding BorderThickness}" |
|
|
|
Margin="{Binding Padding, RelativeSource={RelativeSource AncestorType={x:Type TabItem}}}"> |
|
|
|
<Grid> |
|
|
|
<ContentPresenter Content="{Binding Model, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ContentTemplate="{Binding AnchorableHeaderTemplate, Mode=OneWay, RelativeSource={RelativeSource AncestorType={x:Type avalonDock:DockingManager}, Mode=FindAncestor}}" |
|
|
|
ContentTemplateSelector="{Binding AnchorableHeaderTemplateSelector, Mode=OneWay, RelativeSource={RelativeSource AncestorType={x:Type avalonDock:DockingManager}, Mode=FindAncestor}}" /> |
|
|
|
<avalonDockControls:DropDownControlArea Grid.Column="0" |
|
|
|
DropDownContextMenu="{Binding Model.Root.Manager.AnchorableContextMenu, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
DropDownContextMenuDataContext="{Binding Path=Model, RelativeSource={RelativeSource TemplatedParent}}" > |
|
|
|
</avalonDockControls:DropDownControlArea> |
|
|
|
ContentTemplate="{Binding Root.Manager.AnchorableHeaderTemplate, Mode=OneWay}" |
|
|
|
ContentTemplateSelector="{Binding Root.Manager.AnchorableHeaderTemplateSelector, Mode=OneWay}" /> |
|
|
|
</Grid> |
|
|
|
</Border> |
|
|
|
</avalonDockControls:DropDownControlArea> |
|
|
|
@ -1365,112 +1368,114 @@ |
|
|
|
<Setter Property="Template"> |
|
|
|
<Setter.Value> |
|
|
|
<ControlTemplate TargetType="{x:Type avalonDockControls:LayoutDocumentFloatingWindowControl}"> |
|
|
|
<Grid> |
|
|
|
<Border x:Name="WindowBorder" |
|
|
|
Background="{TemplateBinding Background}" |
|
|
|
BorderBrush="{TemplateBinding BorderBrush}" |
|
|
|
BorderThickness="{TemplateBinding BorderThickness}"> |
|
|
|
<Grid> |
|
|
|
<Grid.RowDefinitions> |
|
|
|
<RowDefinition MinHeight="24" |
|
|
|
Height="Auto"/> |
|
|
|
<RowDefinition Height="*" /> |
|
|
|
</Grid.RowDefinitions> |
|
|
|
<Grid.ColumnDefinitions> |
|
|
|
<ColumnDefinition Width="Auto" /> |
|
|
|
<ColumnDefinition /> |
|
|
|
</Grid.ColumnDefinitions> |
|
|
|
|
|
|
|
<Border x:Name="bd" |
|
|
|
Width="5" |
|
|
|
VerticalAlignment="Stretch" |
|
|
|
Background="{DynamicResource AvalonDock_ThemeMetro_BaseColor5}" /> |
|
|
|
|
|
|
|
<Border x:Name="Header" |
|
|
|
Padding="2,0,2,0" |
|
|
|
Grid.Column="1"> |
|
|
|
<Grid UseLayoutRounding="True"> |
|
|
|
<Grid.ColumnDefinitions> |
|
|
|
<ColumnDefinition Width="*" /> |
|
|
|
<ColumnDefinition Width="Auto" /> |
|
|
|
<ColumnDefinition Width="Auto" /> |
|
|
|
<ColumnDefinition Width="Auto" /> |
|
|
|
</Grid.ColumnDefinitions> |
|
|
|
<ContentPresenter Content="{Binding Model.RootDocument, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ContentTemplate="{Binding Model.Root.Manager.DocumentTitleTemplate, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ContentTemplateSelector="{Binding Model.Root.Manager.DocumentTitleTemplateSelector, RelativeSource={RelativeSource TemplatedParent}}" /> |
|
|
|
|
|
|
|
|
|
|
|
<avalonDockControls:DropDownButton x:Name="ContextMenuDropdownButton" |
|
|
|
shell:WindowChrome.IsHitTestVisibleInChrome="True" |
|
|
|
Style="{StaticResource AvalonDock_ThemeMetro_ToolButtonStyle}" |
|
|
|
Focusable="False" |
|
|
|
Grid.Column="1" |
|
|
|
VerticalAlignment="Center" |
|
|
|
HorizontalAlignment="Center" |
|
|
|
VerticalContentAlignment="Center" |
|
|
|
HorizontalContentAlignment="Center" |
|
|
|
DropDownContextMenu="{Binding Model.Root.Manager.DocumentContextMenu, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
DropDownContextMenuDataContext="{Binding Path=RootDocumentLayoutItem, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ToolTip="{x:Static avalonDockProperties:Resources.Document_CxMenu_Hint}"> |
|
|
|
<Image x:Name="PART_ImgPinMenu" |
|
|
|
Stretch="None" |
|
|
|
Source="Images/PinMenu.png" |
|
|
|
Width="13"> |
|
|
|
</Image> |
|
|
|
</avalonDockControls:DropDownButton> |
|
|
|
|
|
|
|
<Button x:Name="PART_PinMaximize" |
|
|
|
shell:WindowChrome.IsHitTestVisibleInChrome="True" |
|
|
|
Focusable="False" |
|
|
|
Visibility="{Binding IsMaximized, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource InverseBoolToVisibilityConverter}}" |
|
|
|
Style="{StaticResource AvalonDock_ThemeMetro_ButtonStyle}" |
|
|
|
Command="{x:Static shell:SystemCommands.MaximizeWindowCommand}" |
|
|
|
CommandParameter="{Binding RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ToolTip="{x:Static avalonDockProperties:Resources.Window_Maximize}" |
|
|
|
Grid.Column="2"> |
|
|
|
<Image x:Name="PART_ImgPinMaximize" |
|
|
|
Source="Images/PinMaximize.png" |
|
|
|
Width="13" > |
|
|
|
</Image> |
|
|
|
</Button> |
|
|
|
|
|
|
|
<Button x:Name="PART_PinRestore" |
|
|
|
shell:WindowChrome.IsHitTestVisibleInChrome="True" |
|
|
|
Focusable="False" |
|
|
|
Visibility="{Binding IsMaximized, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource BoolToVisibilityConverter}}" |
|
|
|
Style="{StaticResource AvalonDock_ThemeMetro_ButtonStyle}" |
|
|
|
Command="{x:Static shell:SystemCommands.RestoreWindowCommand}" |
|
|
|
CommandParameter="{Binding RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ToolTip="{x:Static avalonDockProperties:Resources.Window_Restore}" |
|
|
|
Grid.Column="2"> |
|
|
|
<Image x:Name="PART_ImgPinRestore" |
|
|
|
Source="Images/PinRestore.png" |
|
|
|
Width="13" > |
|
|
|
</Image> |
|
|
|
</Button> |
|
|
|
|
|
|
|
<Button x:Name="PART_PinClose" |
|
|
|
shell:WindowChrome.IsHitTestVisibleInChrome="True" |
|
|
|
Focusable="False" |
|
|
|
Style="{StaticResource AvalonDock_ThemeMetro_ButtonStyle}" |
|
|
|
Visibility="{Binding Path=IsEnabled, RelativeSource={RelativeSource Self}, Mode=OneWay, Converter={StaticResource BoolToVisibilityConverter}}" |
|
|
|
Command="{Binding Path=RootDocumentLayoutItem.CloseCommand, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ToolTip="{x:Static avalonDockProperties:Resources.Document_Close}" |
|
|
|
Grid.Column="3"> |
|
|
|
<Image x:Name="PART_ImgPinClose" |
|
|
|
Source="Images/PinClose.png" |
|
|
|
Width="13" > |
|
|
|
</Image> |
|
|
|
</Button> |
|
|
|
</Grid> |
|
|
|
</Border> |
|
|
|
<ContentPresenter Content="{TemplateBinding Content}" |
|
|
|
Grid.Row="1" |
|
|
|
Grid.ColumnSpan="2" /> |
|
|
|
</Grid> |
|
|
|
</Border> |
|
|
|
</Grid> |
|
|
|
<AdornerDecorator> |
|
|
|
<Grid> |
|
|
|
<Border x:Name="WindowBorder" |
|
|
|
Background="{TemplateBinding Background}" |
|
|
|
BorderBrush="{TemplateBinding BorderBrush}" |
|
|
|
BorderThickness="{TemplateBinding BorderThickness}"> |
|
|
|
<Grid> |
|
|
|
<Grid.RowDefinitions> |
|
|
|
<RowDefinition MinHeight="24" |
|
|
|
Height="Auto" /> |
|
|
|
<RowDefinition Height="*" /> |
|
|
|
</Grid.RowDefinitions> |
|
|
|
<Grid.ColumnDefinitions> |
|
|
|
<ColumnDefinition Width="Auto" /> |
|
|
|
<ColumnDefinition /> |
|
|
|
</Grid.ColumnDefinitions> |
|
|
|
|
|
|
|
<Border x:Name="bd" |
|
|
|
Width="5" |
|
|
|
VerticalAlignment="Stretch" |
|
|
|
Background="{DynamicResource AvalonDock_ThemeMetro_BaseColor5}" /> |
|
|
|
|
|
|
|
<Border x:Name="Header" |
|
|
|
Padding="2,0,2,0" |
|
|
|
Grid.Column="1"> |
|
|
|
<Grid UseLayoutRounding="True"> |
|
|
|
<Grid.ColumnDefinitions> |
|
|
|
<ColumnDefinition Width="*" /> |
|
|
|
<ColumnDefinition Width="Auto" /> |
|
|
|
<ColumnDefinition Width="Auto" /> |
|
|
|
<ColumnDefinition Width="Auto" /> |
|
|
|
</Grid.ColumnDefinitions> |
|
|
|
<ContentPresenter Content="{Binding Model.RootDocument, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ContentTemplate="{Binding Model.Root.Manager.DocumentTitleTemplate, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ContentTemplateSelector="{Binding Model.Root.Manager.DocumentTitleTemplateSelector, RelativeSource={RelativeSource TemplatedParent}}" /> |
|
|
|
|
|
|
|
|
|
|
|
<avalonDockControls:DropDownButton x:Name="ContextMenuDropdownButton" |
|
|
|
shell:WindowChrome.IsHitTestVisibleInChrome="True" |
|
|
|
Style="{StaticResource AvalonDock_ThemeMetro_ToolButtonStyle}" |
|
|
|
Focusable="False" |
|
|
|
Grid.Column="1" |
|
|
|
VerticalAlignment="Center" |
|
|
|
HorizontalAlignment="Center" |
|
|
|
VerticalContentAlignment="Center" |
|
|
|
HorizontalContentAlignment="Center" |
|
|
|
DropDownContextMenu="{Binding Model.Root.Manager.DocumentContextMenu, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
DropDownContextMenuDataContext="{Binding Path=RootDocumentLayoutItem, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ToolTip="{x:Static avalonDockProperties:Resources.Document_CxMenu_Hint}"> |
|
|
|
<Image x:Name="PART_ImgPinMenu" |
|
|
|
Stretch="None" |
|
|
|
Source="Images/PinMenu.png" |
|
|
|
Width="13"> |
|
|
|
</Image> |
|
|
|
</avalonDockControls:DropDownButton> |
|
|
|
|
|
|
|
<Button x:Name="PART_PinMaximize" |
|
|
|
shell:WindowChrome.IsHitTestVisibleInChrome="True" |
|
|
|
Focusable="False" |
|
|
|
Visibility="{Binding IsMaximized, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource InverseBoolToVisibilityConverter}}" |
|
|
|
Style="{StaticResource AvalonDock_ThemeMetro_ButtonStyle}" |
|
|
|
Command="{x:Static shell:SystemCommands.MaximizeWindowCommand}" |
|
|
|
CommandParameter="{Binding RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ToolTip="{x:Static avalonDockProperties:Resources.Window_Maximize}" |
|
|
|
Grid.Column="2"> |
|
|
|
<Image x:Name="PART_ImgPinMaximize" |
|
|
|
Source="Images/PinMaximize.png" |
|
|
|
Width="13"> |
|
|
|
</Image> |
|
|
|
</Button> |
|
|
|
|
|
|
|
<Button x:Name="PART_PinRestore" |
|
|
|
shell:WindowChrome.IsHitTestVisibleInChrome="True" |
|
|
|
Focusable="False" |
|
|
|
Visibility="{Binding IsMaximized, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource BoolToVisibilityConverter}}" |
|
|
|
Style="{StaticResource AvalonDock_ThemeMetro_ButtonStyle}" |
|
|
|
Command="{x:Static shell:SystemCommands.RestoreWindowCommand}" |
|
|
|
CommandParameter="{Binding RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ToolTip="{x:Static avalonDockProperties:Resources.Window_Restore}" |
|
|
|
Grid.Column="2"> |
|
|
|
<Image x:Name="PART_ImgPinRestore" |
|
|
|
Source="Images/PinRestore.png" |
|
|
|
Width="13"> |
|
|
|
</Image> |
|
|
|
</Button> |
|
|
|
|
|
|
|
<Button x:Name="PART_PinClose" |
|
|
|
shell:WindowChrome.IsHitTestVisibleInChrome="True" |
|
|
|
Focusable="False" |
|
|
|
Style="{StaticResource AvalonDock_ThemeMetro_ButtonStyle}" |
|
|
|
Visibility="{Binding Path=IsEnabled, RelativeSource={RelativeSource Self}, Mode=OneWay, Converter={StaticResource BoolToVisibilityConverter}}" |
|
|
|
Command="{Binding Path=RootDocumentLayoutItem.CloseCommand, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ToolTip="{x:Static avalonDockProperties:Resources.Document_Close}" |
|
|
|
Grid.Column="3"> |
|
|
|
<Image x:Name="PART_ImgPinClose" |
|
|
|
Source="Images/PinClose.png" |
|
|
|
Width="13"> |
|
|
|
</Image> |
|
|
|
</Button> |
|
|
|
</Grid> |
|
|
|
</Border> |
|
|
|
<ContentPresenter Content="{TemplateBinding Content}" |
|
|
|
Grid.Row="1" |
|
|
|
Grid.ColumnSpan="2" /> |
|
|
|
</Grid> |
|
|
|
</Border> |
|
|
|
</Grid> |
|
|
|
</AdornerDecorator> |
|
|
|
<ControlTemplate.Triggers> |
|
|
|
<Trigger Property="WindowState" |
|
|
|
Value="Maximized"> |
|
|
|
@ -1553,116 +1558,118 @@ |
|
|
|
<Setter Property="Template"> |
|
|
|
<Setter.Value> |
|
|
|
<ControlTemplate TargetType="{x:Type avalonDockControls:LayoutAnchorableFloatingWindowControl}"> |
|
|
|
<Grid> |
|
|
|
<Border x:Name="WindowBorder" |
|
|
|
BorderThickness="{TemplateBinding BorderThickness}" |
|
|
|
Background="{TemplateBinding Background}" |
|
|
|
BorderBrush="{TemplateBinding BorderBrush}"> |
|
|
|
<Grid> |
|
|
|
<Grid.RowDefinitions> |
|
|
|
<RowDefinition MinHeight="24" |
|
|
|
Height="Auto"/> |
|
|
|
<RowDefinition Height="*" /> |
|
|
|
</Grid.RowDefinitions> |
|
|
|
<Border x:Name="Header" |
|
|
|
Padding="2,0,2,0" |
|
|
|
TextElement.Foreground="{DynamicResource AvalonDock_ThemeMetro_BaseColor2}" |
|
|
|
Background="{TemplateBinding Background}"> |
|
|
|
<Grid UseLayoutRounding="True"> |
|
|
|
<Grid.ColumnDefinitions> |
|
|
|
<ColumnDefinition Width="*" /> |
|
|
|
<ColumnDefinition Width="Auto" /> |
|
|
|
<ColumnDefinition Width="Auto" /> |
|
|
|
<ColumnDefinition Width="Auto" /> |
|
|
|
</Grid.ColumnDefinitions> |
|
|
|
|
|
|
|
<Border Visibility="{Binding Path=Model.IsSinglePane, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource BoolToVisibilityConverter}}"> |
|
|
|
<avalonDockControls:DropDownControlArea DropDownContextMenu="{Binding Model.Root.Manager.AnchorableContextMenu, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
DropDownContextMenuDataContext="{Binding Path=SingleContentLayoutItem, RelativeSource={RelativeSource TemplatedParent}}"> |
|
|
|
<ContentPresenter Content="{Binding Model.SinglePane.SelectedContent, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ContentTemplate="{Binding Model.Root.Manager.AnchorableTitleTemplate, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ContentTemplateSelector="{Binding Model.Root.Manager.AnchorableTitleTemplateSelector, RelativeSource={RelativeSource TemplatedParent}}" /> |
|
|
|
</avalonDockControls:DropDownControlArea> |
|
|
|
</Border> |
|
|
|
|
|
|
|
<avalonDockControls:DropDownButton x:Name="SinglePaneContextMenu" |
|
|
|
shell:WindowChrome.IsHitTestVisibleInChrome="True" |
|
|
|
Visibility="{Binding Path=Model.IsSinglePane, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource BoolToVisibilityConverter}}" |
|
|
|
Style="{StaticResource AvalonDock_ThemeMetro_ToolButtonStyle}" |
|
|
|
Focusable="False" |
|
|
|
Grid.Column="1" |
|
|
|
VerticalAlignment="Center" |
|
|
|
HorizontalAlignment="Center" |
|
|
|
VerticalContentAlignment="Center" |
|
|
|
HorizontalContentAlignment="Center" |
|
|
|
DropDownContextMenu="{Binding Model.Root.Manager.AnchorableContextMenu, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
DropDownContextMenuDataContext="{Binding Path=SingleContentLayoutItem, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ToolTip="{x:Static avalonDockProperties:Resources.Anchorable_CxMenu_Hint}"> |
|
|
|
<Image x:Name="PART_ImgPinMenu" |
|
|
|
Stretch="None" |
|
|
|
Source="Images/PinMenu.png" |
|
|
|
Width="13" > |
|
|
|
</Image> |
|
|
|
</avalonDockControls:DropDownButton> |
|
|
|
|
|
|
|
<Button x:Name="PART_PinMaximize" |
|
|
|
shell:WindowChrome.IsHitTestVisibleInChrome="True" |
|
|
|
Focusable="False" |
|
|
|
Visibility="{Binding IsMaximized, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource InverseBoolToVisibilityConverter}}" |
|
|
|
Style="{StaticResource AvalonDock_ThemeMetro_ButtonStyle}" |
|
|
|
VerticalAlignment="Center" |
|
|
|
HorizontalAlignment="Center" |
|
|
|
VerticalContentAlignment="Center" |
|
|
|
HorizontalContentAlignment="Center" |
|
|
|
Command="{x:Static shell:SystemCommands.MaximizeWindowCommand}" |
|
|
|
CommandParameter="{Binding RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ToolTip="{x:Static avalonDockProperties:Resources.Window_Maximize}" |
|
|
|
Grid.Column="2"> |
|
|
|
<Image x:Name="PART_ImgPinMaximize" |
|
|
|
Source="Images/PinMaximize.png" |
|
|
|
Width="13" > |
|
|
|
</Image> |
|
|
|
</Button> |
|
|
|
|
|
|
|
<Button x:Name="PART_PinRestore" |
|
|
|
shell:WindowChrome.IsHitTestVisibleInChrome="True" |
|
|
|
Focusable="False" |
|
|
|
Visibility="{Binding IsMaximized, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource BoolToVisibilityConverter}}" |
|
|
|
Style="{StaticResource AvalonDock_ThemeMetro_ButtonStyle}" |
|
|
|
VerticalAlignment="Center" |
|
|
|
HorizontalAlignment="Center" |
|
|
|
Command="{x:Static shell:SystemCommands.RestoreWindowCommand}" |
|
|
|
CommandParameter="{Binding RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ToolTip="{x:Static avalonDockProperties:Resources.Window_Restore}" |
|
|
|
Grid.Column="2"> |
|
|
|
<Image x:Name="PART_ImgPinRestore" |
|
|
|
Source="Images/PinRestore.png" |
|
|
|
Width="13" > |
|
|
|
</Image> |
|
|
|
</Button> |
|
|
|
|
|
|
|
<Button x:Name="PART_PinClose" |
|
|
|
shell:WindowChrome.IsHitTestVisibleInChrome="True" |
|
|
|
Focusable="False" |
|
|
|
Style="{StaticResource AvalonDock_ThemeMetro_ButtonStyle}" |
|
|
|
VerticalAlignment="Center" |
|
|
|
HorizontalAlignment="Center" |
|
|
|
Visibility="{Binding Path=IsEnabled, RelativeSource={RelativeSource Self}, Mode=OneWay, Converter={StaticResource BoolToVisibilityConverter}}" |
|
|
|
Command="{Binding HideWindowCommand, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ToolTip="{x:Static avalonDockProperties:Resources.Anchorable_BtnClose_Hint}" |
|
|
|
Grid.Column="3"> |
|
|
|
<Image x:Name="PART_ImgPinClose" |
|
|
|
Source="Images/PinClose.png" |
|
|
|
Width="13" > |
|
|
|
</Image> |
|
|
|
</Button> |
|
|
|
</Grid> |
|
|
|
</Border> |
|
|
|
<ContentPresenter Content="{TemplateBinding Content}" |
|
|
|
Grid.Row="1" /> |
|
|
|
</Grid> |
|
|
|
</Border> |
|
|
|
</Grid> |
|
|
|
<AdornerDecorator> |
|
|
|
<Grid> |
|
|
|
<Border x:Name="WindowBorder" |
|
|
|
BorderThickness="{TemplateBinding BorderThickness}" |
|
|
|
Background="{TemplateBinding Background}" |
|
|
|
BorderBrush="{TemplateBinding BorderBrush}"> |
|
|
|
<Grid> |
|
|
|
<Grid.RowDefinitions> |
|
|
|
<RowDefinition MinHeight="24" |
|
|
|
Height="Auto" /> |
|
|
|
<RowDefinition Height="*" /> |
|
|
|
</Grid.RowDefinitions> |
|
|
|
<Border x:Name="Header" |
|
|
|
Padding="2,0,2,0" |
|
|
|
TextElement.Foreground="{DynamicResource AvalonDock_ThemeMetro_BaseColor2}" |
|
|
|
Background="{TemplateBinding Background}"> |
|
|
|
<Grid UseLayoutRounding="True"> |
|
|
|
<Grid.ColumnDefinitions> |
|
|
|
<ColumnDefinition Width="*" /> |
|
|
|
<ColumnDefinition Width="Auto" /> |
|
|
|
<ColumnDefinition Width="Auto" /> |
|
|
|
<ColumnDefinition Width="Auto" /> |
|
|
|
</Grid.ColumnDefinitions> |
|
|
|
|
|
|
|
<Border Visibility="{Binding Path=Model.IsSinglePane, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource BoolToVisibilityConverter}}"> |
|
|
|
<avalonDockControls:DropDownControlArea DropDownContextMenu="{Binding Model.Root.Manager.AnchorableContextMenu, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
DropDownContextMenuDataContext="{Binding Path=SingleContentLayoutItem, RelativeSource={RelativeSource TemplatedParent}}"> |
|
|
|
<ContentPresenter Content="{Binding Model.SinglePane.SelectedContent, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ContentTemplate="{Binding Model.Root.Manager.AnchorableTitleTemplate, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ContentTemplateSelector="{Binding Model.Root.Manager.AnchorableTitleTemplateSelector, RelativeSource={RelativeSource TemplatedParent}}" /> |
|
|
|
</avalonDockControls:DropDownControlArea> |
|
|
|
</Border> |
|
|
|
|
|
|
|
<avalonDockControls:DropDownButton x:Name="SinglePaneContextMenu" |
|
|
|
shell:WindowChrome.IsHitTestVisibleInChrome="True" |
|
|
|
Visibility="{Binding Path=Model.IsSinglePane, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource BoolToVisibilityConverter}}" |
|
|
|
Style="{StaticResource AvalonDock_ThemeMetro_ToolButtonStyle}" |
|
|
|
Focusable="False" |
|
|
|
Grid.Column="1" |
|
|
|
VerticalAlignment="Center" |
|
|
|
HorizontalAlignment="Center" |
|
|
|
VerticalContentAlignment="Center" |
|
|
|
HorizontalContentAlignment="Center" |
|
|
|
DropDownContextMenu="{Binding Model.Root.Manager.AnchorableContextMenu, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
DropDownContextMenuDataContext="{Binding Path=SingleContentLayoutItem, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ToolTip="{x:Static avalonDockProperties:Resources.Anchorable_CxMenu_Hint}"> |
|
|
|
<Image x:Name="PART_ImgPinMenu" |
|
|
|
Stretch="None" |
|
|
|
Source="Images/PinMenu.png" |
|
|
|
Width="13"> |
|
|
|
</Image> |
|
|
|
</avalonDockControls:DropDownButton> |
|
|
|
|
|
|
|
<Button x:Name="PART_PinMaximize" |
|
|
|
shell:WindowChrome.IsHitTestVisibleInChrome="True" |
|
|
|
Focusable="False" |
|
|
|
Visibility="{Binding IsMaximized, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource InverseBoolToVisibilityConverter}}" |
|
|
|
Style="{StaticResource AvalonDock_ThemeMetro_ButtonStyle}" |
|
|
|
VerticalAlignment="Center" |
|
|
|
HorizontalAlignment="Center" |
|
|
|
VerticalContentAlignment="Center" |
|
|
|
HorizontalContentAlignment="Center" |
|
|
|
Command="{x:Static shell:SystemCommands.MaximizeWindowCommand}" |
|
|
|
CommandParameter="{Binding RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ToolTip="{x:Static avalonDockProperties:Resources.Window_Maximize}" |
|
|
|
Grid.Column="2"> |
|
|
|
<Image x:Name="PART_ImgPinMaximize" |
|
|
|
Source="Images/PinMaximize.png" |
|
|
|
Width="13"> |
|
|
|
</Image> |
|
|
|
</Button> |
|
|
|
|
|
|
|
<Button x:Name="PART_PinRestore" |
|
|
|
shell:WindowChrome.IsHitTestVisibleInChrome="True" |
|
|
|
Focusable="False" |
|
|
|
Visibility="{Binding IsMaximized, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource BoolToVisibilityConverter}}" |
|
|
|
Style="{StaticResource AvalonDock_ThemeMetro_ButtonStyle}" |
|
|
|
VerticalAlignment="Center" |
|
|
|
HorizontalAlignment="Center" |
|
|
|
Command="{x:Static shell:SystemCommands.RestoreWindowCommand}" |
|
|
|
CommandParameter="{Binding RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ToolTip="{x:Static avalonDockProperties:Resources.Window_Restore}" |
|
|
|
Grid.Column="2"> |
|
|
|
<Image x:Name="PART_ImgPinRestore" |
|
|
|
Source="Images/PinRestore.png" |
|
|
|
Width="13"> |
|
|
|
</Image> |
|
|
|
</Button> |
|
|
|
|
|
|
|
<Button x:Name="PART_PinClose" |
|
|
|
shell:WindowChrome.IsHitTestVisibleInChrome="True" |
|
|
|
Focusable="False" |
|
|
|
Style="{StaticResource AvalonDock_ThemeMetro_ButtonStyle}" |
|
|
|
VerticalAlignment="Center" |
|
|
|
HorizontalAlignment="Center" |
|
|
|
Visibility="{Binding Path=IsEnabled, RelativeSource={RelativeSource Self}, Mode=OneWay, Converter={StaticResource BoolToVisibilityConverter}}" |
|
|
|
Command="{Binding HideWindowCommand, RelativeSource={RelativeSource TemplatedParent}}" |
|
|
|
ToolTip="{x:Static avalonDockProperties:Resources.Anchorable_BtnClose_Hint}" |
|
|
|
Grid.Column="3"> |
|
|
|
<Image x:Name="PART_ImgPinClose" |
|
|
|
Source="Images/PinClose.png" |
|
|
|
Width="13"> |
|
|
|
</Image> |
|
|
|
</Button> |
|
|
|
</Grid> |
|
|
|
</Border> |
|
|
|
<ContentPresenter Content="{TemplateBinding Content}" |
|
|
|
Grid.Row="1" /> |
|
|
|
</Grid> |
|
|
|
</Border> |
|
|
|
</Grid> |
|
|
|
</AdornerDecorator> |
|
|
|
<ControlTemplate.Triggers> |
|
|
|
<Trigger Property="WindowState" |
|
|
|
Value="Maximized"> |
|
|
|
|