PageRenderTime 20ms CodeModel.GetById 17ms app.highlight 1ms RepoModel.GetById 1ms app.codeStats 0ms

/V4/Quickstarts/UIComposition/EmployeeModule/Views/EmployeeSummaryView.xaml

#
XAML | 46 lines | 38 code | 5 blank | 3 comment | 0 complexity | f611edf47de5b78e4ace6987f864245d MD5 | raw file
 1<UserControl x:Class="UIComposition.EmployeeModule.Views.EmployeeSummaryView"
 2             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
 3             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
 4             xmlns:sdk="http://schemas.microsoft.com/winfx/2006/xaml/presentation/sdk"
 5             xmlns:prism="http://www.codeplex.com/prism">
 6
 7	<Grid x:Name="LayoutRoot">
 8		<Grid.Background>
 9			<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
10				<GradientStop Color="#FF7B97D4" />
11				<GradientStop Color="#FF244C8D" Offset="1" />
12			</LinearGradientBrush>
13		</Grid.Background>
14		<Grid.ColumnDefinitions>
15			<ColumnDefinition Width="*" />
16		</Grid.ColumnDefinitions>
17		<Grid.RowDefinitions>
18			<RowDefinition Height="Auto" />
19			<RowDefinition Height="*" />
20		</Grid.RowDefinitions>
21
22		<TextBlock Grid.Row="0" Text="Employee Summary View" TextWrapping="Wrap" FontSize="18" Foreground="#FF2F3806" Margin="8" />
23
24        <!--The Tab control defines a region, TabRegion, into which the EmployeeDetailsView and EmployeeProjectsView will be displayed.-->
25        <!--The TabRegion defines a RegionContext which provides a reference to the currently selected employee.-->
26        <sdk:TabControl Grid.Row="1" AutomationProperties.AutomationId="EmployeeSummaryTabControl" Margin="8"
27                        prism:RegionManager.RegionName="TabRegion"
28                        prism:RegionManager.RegionContext="{Binding CurrentEmployee}"
29                        Width="Auto" Height="Auto" HorizontalAlignment="Stretch">
30			<prism:TabControlRegionAdapter.ItemContainerStyle>
31				<Style TargetType="sdk:TabItem">
32					<Setter Property="HeaderTemplate">
33						<Setter.Value>
34                            <!--Display the child view name on the tab header-->
35							<DataTemplate>
36								<TextBlock Text="{Binding ViewName}" />
37							</DataTemplate>
38						</Setter.Value>
39					</Setter>
40				</Style>
41			</prism:TabControlRegionAdapter.ItemContainerStyle>
42		</sdk:TabControl>
43
44	</Grid>
45
46</UserControl>