init
This commit is contained in:
@@ -0,0 +1,332 @@
|
||||
<base:BaseView x:Class="DTS.Viewer.ViewerMainView"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:prism="http://prismlibrary.com/"
|
||||
xmlns:i="http://schemas.microsoft.com/xaml/behaviors"
|
||||
xmlns:classes="clr-namespace:DTS.Common.Classes;assembly=DTS.Common"
|
||||
xmlns:converters="clr-namespace:DTS.Common.Converters;assembly=DTS.Common"
|
||||
xmlns:dialogs="clr-namespace:DTS.Common.Dialogs;assembly=DTS.Common"
|
||||
xmlns:base="clr-namespace:DTS.Common.Base;assembly=DTS.Common"
|
||||
xmlns:dock="http://schemas.xceed.com/wpf/xaml/avalondock"
|
||||
xmlns:toolkit="http://schemas.xceed.com/wpf/xaml/toolkit" xmlns:interactivity="clr-namespace:DTS.Common.Interactivity;assembly=DTS.Common"
|
||||
VerticalAlignment="Stretch" HorizontalAlignment="Stretch" >
|
||||
|
||||
<base:BaseView.Resources>
|
||||
<converters:BooleanToVisibilityConverter x:Key="BooleanToVisibilityConverter" />
|
||||
<converters:WidthConverter x:Key="WidthConverter" />
|
||||
</base:BaseView.Resources>
|
||||
|
||||
<i:Interaction.Triggers>
|
||||
<interactivity:InteractionRequestTrigger SourceObject="{Binding NotificationRequest, Mode=OneWay}">
|
||||
<dialogs:PopupWindowAction IsModal="True" StartupPosition="CenterScreen"/>
|
||||
</interactivity:InteractionRequestTrigger>
|
||||
</i:Interaction.Triggers>
|
||||
|
||||
<toolkit:BusyIndicator IsBusy="{Binding IsBusy, UpdateSourceTrigger=PropertyChanged}" BusyContent="{Binding IsBusyMessage}" Visibility="Visible" >
|
||||
<DockPanel x:Name="MainShell" FlowDirection="LeftToRight" LastChildFill="True" SnapsToDevicePixels="True" WindowChrome.ResizeGripDirection="TopLeft" >
|
||||
<dock:DockingManager Name="DockManager" BorderBrush="Black" BorderThickness="1" AllowMixedOrientation="True" Style="{DynamicResource {x:Type dock:DockingManager}}"
|
||||
ShowSystemMenu="False" UseLayoutRounding="False" IsManipulationEnabled="True"
|
||||
VerticalContentAlignment="Stretch" HorizontalContentAlignment="Stretch" >
|
||||
<dock:DockingManager.Resources>
|
||||
<Style TargetType="{x:Type dock:LayoutDocumentTabItem}">
|
||||
<Setter Property="Width" Value="100" />
|
||||
</Style>
|
||||
</dock:DockingManager.Resources>
|
||||
<dock:DockingManager.Theme>
|
||||
<dock:AeroTheme/>
|
||||
</dock:DockingManager.Theme>
|
||||
|
||||
<dock:DockingManager.AnchorablePaneControlStyle>
|
||||
<Style TargetType="{x:Type dock:LayoutAnchorablePaneControl}" >
|
||||
<Setter Property="OverridesDefaultStyle" Value="True"/>
|
||||
<Setter Property="TabStripPlacement" Value="Top"/>
|
||||
<Setter Property="Padding" Value="0"/>
|
||||
<Setter Property="BorderThickness" Value="0"/>
|
||||
<Setter Property="Foreground" Value="{Binding Model.Root.Manager.Foreground, RelativeSource={RelativeSource Self}}"/>
|
||||
<Setter Property="Background" Value="{Binding Model.Root.Manager.Background, RelativeSource={RelativeSource Self}}"/>
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="{x:Type dock:LayoutAnchorablePaneControl}">
|
||||
<Grid x:Name="grid" ClipToBounds="true" SnapsToDevicePixels="true" KeyboardNavigation.TabNavigation="Local">
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto"/>
|
||||
<RowDefinition Height="*"/>
|
||||
</Grid.RowDefinitions>
|
||||
<Border Background="Transparent" Grid.RowSpan="2"/>
|
||||
<Border Grid.Row="0" x:Name="ContentPanel" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" KeyboardNavigation.DirectionalNavigation="Contained" KeyboardNavigation.TabIndex="2" KeyboardNavigation.TabNavigation="Cycle"/>
|
||||
<dock:AnchorablePaneTabPanel Grid.Row="0" x:Name="HeaderPanel" Margin="0,0,2,2" IsItemsHost="true" KeyboardNavigation.TabIndex="1" Panel.ZIndex="1"/>
|
||||
<Grid Grid.Row="1">
|
||||
<ContentPresenter x:Name="PART_SelectedContentHost" ContentSource="SelectedContent" Margin="{TemplateBinding Padding}" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>
|
||||
</Grid>
|
||||
</Grid>
|
||||
<ControlTemplate.Triggers>
|
||||
<Trigger Property="IsEnabled" Value="false">
|
||||
<Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.GrayTextBrushKey}}"/>
|
||||
</Trigger>
|
||||
<DataTrigger Binding="{Binding Items.Count, RelativeSource={RelativeSource Self}}" Value="1">
|
||||
<Setter Property="Margin" Value="0" TargetName="HeaderPanel"/>
|
||||
</DataTrigger>
|
||||
</ControlTemplate.Triggers>
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
<Setter Property="ItemContainerStyle">
|
||||
<Setter.Value>
|
||||
<Style TargetType="{x:Type TabItem}" >
|
||||
<Setter Property="Background" Value="{DynamicResource {ComponentResourceKey ResourceId=BaseColor4, TypeInTargetAssembly={x:Type dock:AeroColors}}}"/>
|
||||
<Setter Property="BorderBrush" Value="{DynamicResource {ComponentResourceKey ResourceId=BaseColor5, TypeInTargetAssembly={x:Type dock:AeroColors}}}"/>
|
||||
<Setter Property="Foreground" Value="{DynamicResource {ComponentResourceKey ResourceId=BaseColor12, TypeInTargetAssembly={x:Type dock:AeroColors}}}"/>
|
||||
<Setter Property="IsSelected" Value="{Binding IsSelected, Mode=TwoWay}"/>
|
||||
<Setter Property="ToolTip" Value="{Binding ToolTip}"/>
|
||||
<Setter Property="Margin" Value="0,0,0,0"/>
|
||||
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="{x:Type TabItem}">
|
||||
<Grid SnapsToDevicePixels="True">
|
||||
<Border x:Name="Bd" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="1,1,1,0" Background="{TemplateBinding Background}" Padding="{TemplateBinding Padding}">
|
||||
<ContentPresenter x:Name="Content" ContentTemplate="{TemplateBinding HeaderTemplate}" Content="{TemplateBinding Header}"
|
||||
ContentStringFormat="{TemplateBinding HeaderStringFormat}"
|
||||
ContentSource="Header" HorizontalAlignment="{Binding HorizontalContentAlignment, RelativeSource={RelativeSource FindAncestor, AncestorLevel=1, AncestorType={x:Type ItemsControl}}}"
|
||||
RecognizesAccessKey="True"
|
||||
SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
|
||||
VerticalAlignment="{Binding VerticalContentAlignment, RelativeSource={RelativeSource FindAncestor, AncestorLevel=1, AncestorType={x:Type ItemsControl}}}"/>
|
||||
</Border>
|
||||
</Grid>
|
||||
<ControlTemplate.Triggers>
|
||||
<Trigger Property="IsSelected" Value="True">
|
||||
<Setter Property="Background" Value="{DynamicResource {ComponentResourceKey ResourceId=BaseColor2, TypeInTargetAssembly={x:Type dock:AeroColors}}}"/>
|
||||
<Setter Property="Foreground" Value="{DynamicResource {ComponentResourceKey ResourceId=BaseColor3, TypeInTargetAssembly={x:Type dock:AeroColors}}}"/>
|
||||
<Setter Property="Panel.ZIndex" Value="1"/>
|
||||
<Setter Property="Margin" Value="0,0,0,0"/>
|
||||
</Trigger>
|
||||
<MultiTrigger>
|
||||
<MultiTrigger.Conditions>
|
||||
<Condition Property="IsMouseOver" Value="True"/>
|
||||
<Condition Property="IsSelected" Value="False"/>
|
||||
</MultiTrigger.Conditions>
|
||||
<Setter Property="BorderBrush" Value="{DynamicResource {ComponentResourceKey ResourceId=BaseColor32, TypeInTargetAssembly={x:Type dock:AeroColors}}}"/>
|
||||
<Setter Property="Background" Value="{DynamicResource {ComponentResourceKey ResourceId=BaseColor27, TypeInTargetAssembly={x:Type dock:AeroColors}}}"/>
|
||||
<Setter Property="Panel.ZIndex" Value="0"/>
|
||||
</MultiTrigger>
|
||||
<Trigger Property="IsEnabled" Value="False">
|
||||
<Setter Property="BorderBrush" Value="{DynamicResource {ComponentResourceKey ResourceId=BaseColor13, TypeInTargetAssembly={x:Type dock:AeroColors}}}"/>
|
||||
<Setter Property="Background" Value="{DynamicResource {ComponentResourceKey ResourceId=BaseColor9, TypeInTargetAssembly={x:Type dock:AeroColors}}}"/>
|
||||
<Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.GrayTextBrushKey}}"/>
|
||||
</Trigger>
|
||||
</ControlTemplate.Triggers>
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
<Style.Triggers>
|
||||
<DataTrigger Binding="{Binding Items.Count, RelativeSource={RelativeSource FindAncestor, AncestorLevel=1, AncestorType={x:Type TabControl}}}" Value="1">
|
||||
<Setter Property="Visibility" Value="Collapsed"/>
|
||||
</DataTrigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
<Setter Property="ItemTemplate">
|
||||
<Setter.Value>
|
||||
<DataTemplate>
|
||||
<dock:LayoutAnchorableTabItem Model="{Binding}"/>
|
||||
</DataTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
<Setter Property="ContentTemplate">
|
||||
<Setter.Value>
|
||||
<DataTemplate>
|
||||
<dock:LayoutAnchorableControl Model="{Binding}"/>
|
||||
</DataTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
</Style>
|
||||
|
||||
</dock:DockingManager.AnchorablePaneControlStyle>
|
||||
<dock:LayoutRoot x:Name="_layoutRoot" >
|
||||
<dock:LayoutPanel Orientation="Horizontal" IsMaximized="True" DockHeight="*" >
|
||||
<dock:LayoutAnchorablePane Name="NavigationPane" DockWidth="250" DockHeight="*">
|
||||
<dock:LayoutAnchorable ContentId="NavigationRegionPanel" IsMaximized="True" AutoHideWidth="100" CanClose="False" CanHide="False" CanAutoHide="True" CanFloat="False" >
|
||||
<ContentControl x:Name="NavigationRegion" prism:RegionManager.RegionName="{x:Static classes:RegionNames.NavigationRegion}"
|
||||
Width="250" VerticalAlignment="Stretch" HorizontalAlignment="Left">
|
||||
<ContentControl.Template >
|
||||
<ControlTemplate TargetType="{x:Type ContentControl}">
|
||||
<Grid>
|
||||
<Label Content="Left"/>
|
||||
<ContentPresenter Content="{TemplateBinding Content}" MinWidth="240" />
|
||||
</Grid>
|
||||
</ControlTemplate>
|
||||
</ContentControl.Template>
|
||||
|
||||
</ContentControl>
|
||||
</dock:LayoutAnchorable>
|
||||
</dock:LayoutAnchorablePane>
|
||||
<dock:LayoutPanel Orientation="Vertical" IsMaximized="True" DockHeight="*" DockWidth="Auto">
|
||||
<dock:LayoutAnchorablePane Name="GraphPane" DockWidth="*" DockHeight="*">
|
||||
<dock:LayoutAnchorable CanAutoHide="False" CanClose="False" CanHide="False">
|
||||
<ContentControl x:Name="GraphRegion" prism:RegionManager.RegionName="{x:Static classes:RegionNames.ViewerGraphsRegion}"
|
||||
VerticalAlignment="Stretch" HorizontalAlignment="Stretch"
|
||||
Height="Auto" Width="Auto" MinHeight="500" MinWidth="500">
|
||||
<ContentControl.Template>
|
||||
<ControlTemplate TargetType="{x:Type ContentControl}">
|
||||
<Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
|
||||
<ContentPresenter Content="{TemplateBinding Content}" />
|
||||
</Grid>
|
||||
</ControlTemplate>
|
||||
</ContentControl.Template>
|
||||
</ContentControl>
|
||||
</dock:LayoutAnchorable>
|
||||
</dock:LayoutAnchorablePane>
|
||||
<dock:LayoutAnchorablePane Name="TestPane" DockMinHeight="100" DockWidth="*" DockHeight="*" >
|
||||
<dock:LayoutAnchorable ContentId="TestRegionPanel" x:Name="TestRegionPanel" Title="Tests" CanClose="False" CanHide="False" CanAutoHide="True" CanFloat="True" >
|
||||
<ContentControl x:Name="TestsRegion" prism:RegionManager.RegionName="ViewerTestsRegion2"
|
||||
Width="{Binding Path=ActualWidth, ElementName=TestPane, Converter={StaticResource WidthConverter}, ConverterParameter='1'}"
|
||||
Height="{Binding Path=ActualHeight, ElementName=TestPane, Converter={StaticResource WidthConverter}, ConverterParameter='1'}"
|
||||
VerticalAlignment="Top" HorizontalAlignment="Stretch" >
|
||||
<ContentControl.Template>
|
||||
<ControlTemplate TargetType="{x:Type ContentControl}">
|
||||
<Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
|
||||
<ContentPresenter Content="{TemplateBinding Content}" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" />
|
||||
</Grid>
|
||||
</ControlTemplate>
|
||||
</ContentControl.Template>
|
||||
</ContentControl>
|
||||
</dock:LayoutAnchorable>
|
||||
<dock:LayoutAnchorable ContentId="GraphRegionPanel" x:Name="GraphListPanel" Title="Graphs" CanClose="False" CanHide="False" CanAutoHide="True" CanFloat="True">
|
||||
<ContentControl x:Name="GraphListRegion" prism:RegionManager.RegionName="{x:Static classes:RegionNames.ViewerGraphListRegion}"
|
||||
Height="Auto" Width="Auto" VerticalAlignment="Top" HorizontalAlignment="Stretch">
|
||||
<ContentControl.Template>
|
||||
<ControlTemplate TargetType="{x:Type ContentControl}">
|
||||
<Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
|
||||
<ContentPresenter Content="{TemplateBinding Content}" />
|
||||
</Grid>
|
||||
</ControlTemplate>
|
||||
</ContentControl.Template>
|
||||
</ContentControl>
|
||||
</dock:LayoutAnchorable>
|
||||
<dock:LayoutAnchorable ContentId="SettingsRegionPanel" x:Name="SettingsPanel" Title="Settings" CanClose="False" CanHide="False" CanAutoHide="True" CanFloat="True">
|
||||
<ContentControl x:Name="SettingsRegion" prism:RegionManager.RegionName="{x:Static classes:RegionNames.ViewerSettingsRegion}"
|
||||
Height="Auto" Width="Auto" VerticalAlignment="Top" HorizontalAlignment="Stretch">
|
||||
<ContentControl.Template>
|
||||
<ControlTemplate TargetType="{x:Type ContentControl}">
|
||||
<Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
|
||||
<ContentPresenter Content="{TemplateBinding Content}" />
|
||||
</Grid>
|
||||
</ControlTemplate>
|
||||
</ContentControl.Template>
|
||||
</ContentControl>
|
||||
</dock:LayoutAnchorable>
|
||||
<dock:LayoutAnchorable ContentId="LegendRegionPanel" Title="Legend" CanClose="False" CanHide="False" CanAutoHide="True" CanFloat="True">
|
||||
<ContentControl x:Name="LegendRegion" prism:RegionManager.RegionName="{x:Static classes:RegionNames.ViewerLegendRegion}"
|
||||
Height="Auto" Width="Auto" VerticalAlignment="Top" HorizontalAlignment="Stretch">
|
||||
<ContentControl.Template>
|
||||
<ControlTemplate TargetType="{x:Type ContentControl}">
|
||||
<Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
|
||||
<ContentPresenter Content="{TemplateBinding Content}" />
|
||||
</Grid>
|
||||
</ControlTemplate>
|
||||
</ContentControl.Template>
|
||||
</ContentControl>
|
||||
</dock:LayoutAnchorable>
|
||||
</dock:LayoutAnchorablePane>
|
||||
</dock:LayoutPanel>
|
||||
<dock:LayoutPanel Orientation="Vertical" DockWidth="320" DockMinWidth="300" DockHeight="Auto" >
|
||||
<dock:LayoutAnchorablePane Name="DiagnosticPane" DockWidth="300" DockMinWidth="300" DockHeight="*" IsMaximized="True" >
|
||||
<dock:LayoutAnchorable ContentId="DiagRegionPanel" Title="Diag" CanClose="False" CanHide="False" CanAutoHide="True" CanFloat="False" >
|
||||
<ContentControl x:Name="DiagRegion" prism:RegionManager.RegionName="{x:Static classes:RegionNames.ViewerDiagRegion}"
|
||||
Width="300" VerticalAlignment="Stretch" HorizontalAlignment="Right">
|
||||
<ContentControl.Template>
|
||||
<ControlTemplate TargetType="{x:Type ContentControl}">
|
||||
<Grid>
|
||||
<ContentPresenter Content="{TemplateBinding Content}" />
|
||||
</Grid>
|
||||
</ControlTemplate>
|
||||
</ContentControl.Template>
|
||||
</ContentControl>
|
||||
</dock:LayoutAnchorable>
|
||||
<dock:LayoutAnchorable ContentId="StatsRegionPanel" Title="Stats" CanClose="False" CanHide="False" CanAutoHide="True" CanFloat="False" >
|
||||
<ContentControl x:Name="StatsRegion" prism:RegionManager.RegionName="{x:Static classes:RegionNames.ViewerStatsRegion}"
|
||||
Width="300" VerticalAlignment="Stretch" HorizontalAlignment="Right">
|
||||
<ContentControl.Template>
|
||||
<ControlTemplate TargetType="{x:Type ContentControl}">
|
||||
<Grid>
|
||||
<ContentPresenter Content="{TemplateBinding Content}" />
|
||||
</Grid>
|
||||
</ControlTemplate>
|
||||
</ContentControl.Template>
|
||||
</ContentControl>
|
||||
</dock:LayoutAnchorable>
|
||||
<dock:LayoutAnchorable ContentId="CursorRegionPanel" Title="Cursor" CanClose="False" CanHide="False" CanAutoHide="True" CanFloat="False" >
|
||||
<ContentControl x:Name="CursorRegion" prism:RegionManager.RegionName="{x:Static classes:RegionNames.ViewerCursorRegion}"
|
||||
Width="300" VerticalAlignment="Stretch" HorizontalAlignment="Right">
|
||||
<ContentControl.Template>
|
||||
<ControlTemplate TargetType="{x:Type ContentControl}">
|
||||
<Grid>
|
||||
<ContentPresenter Content="{TemplateBinding Content}" />
|
||||
</Grid>
|
||||
</ControlTemplate>
|
||||
</ContentControl.Template>
|
||||
</ContentControl>
|
||||
</dock:LayoutAnchorable>
|
||||
</dock:LayoutAnchorablePane>
|
||||
<dock:LayoutAnchorablePane Name="ModificationPane" DockWidth="300" DockMinWidth="300" DockHeight="*" IsMaximized="True" >
|
||||
<dock:LayoutAnchorable ContentId="ChartOptionsPanel" Title="Display" CanClose="False" CanHide="False" CanAutoHide="True" CanFloat="False" >
|
||||
<ContentControl x:Name="ChartOptionsRegion" prism:RegionManager.RegionName="{x:Static classes:RegionNames.ViewerChartOptionsRegion}"
|
||||
Width="300" VerticalAlignment="Stretch" HorizontalAlignment="Right" >
|
||||
<ContentControl.Template>
|
||||
<ControlTemplate TargetType="{x:Type ContentControl}">
|
||||
<Grid>
|
||||
<ContentPresenter Content="{TemplateBinding Content}" />
|
||||
</Grid>
|
||||
</ControlTemplate>
|
||||
</ContentControl.Template>
|
||||
</ContentControl>
|
||||
</dock:LayoutAnchorable>
|
||||
<dock:LayoutAnchorable ContentId="ModifyRegionPanel" Title="Modify" CanClose="False" CanHide="False" CanAutoHide="True" CanFloat="False" >
|
||||
<ContentControl x:Name="TestModificationRegion" prism:RegionManager.RegionName="{x:Static classes:RegionNames.ViewerTestModificationRegion}"
|
||||
Width="300" VerticalAlignment="Stretch" HorizontalAlignment="Right" >
|
||||
<ContentControl.Template>
|
||||
<ControlTemplate TargetType="{x:Type ContentControl}">
|
||||
<Grid>
|
||||
<ContentPresenter Content="{TemplateBinding Content}" />
|
||||
</Grid>
|
||||
</ControlTemplate>
|
||||
</ContentControl.Template>
|
||||
</ContentControl>
|
||||
</dock:LayoutAnchorable>
|
||||
<dock:LayoutAnchorable ContentId="AddRegionPanel" Title="Add" CanClose="False" CanHide="False" CanAutoHide="True" CanFloat="False" >
|
||||
<ContentControl x:Name="AddRegion" prism:RegionManager.RegionName="{x:Static classes:RegionNames.PropertyAddRegion}"
|
||||
Width="300" VerticalAlignment="Stretch" HorizontalAlignment="Right" >
|
||||
<ContentControl.Template>
|
||||
<ControlTemplate TargetType="{x:Type ContentControl}">
|
||||
<Grid>
|
||||
<ContentPresenter Content="{TemplateBinding Content}" />
|
||||
</Grid>
|
||||
</ControlTemplate>
|
||||
</ContentControl.Template>
|
||||
</ContentControl>
|
||||
</dock:LayoutAnchorable>
|
||||
</dock:LayoutAnchorablePane>
|
||||
</dock:LayoutPanel>
|
||||
</dock:LayoutPanel>
|
||||
</dock:LayoutRoot>
|
||||
</dock:DockingManager>
|
||||
<!--</Grid>-->
|
||||
</DockPanel>
|
||||
</toolkit:BusyIndicator>
|
||||
</base:BaseView>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user