<Window xmlns:Broadcasting="clr-namespace:ksBroadcastingTestClient.Broadcasting"  xmlns:ClientConnections="clr-namespace:ksBroadcastingTestClient.ClientConnections"  x:Class="ksBroadcastingTestClient.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
        xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
        xmlns:local="clr-namespace:ksBroadcastingTestClient"
        xmlns:autopilot="clr-namespace:ksBroadcastingTestClient.Autopilot"
        mc:Ignorable="d"
        Title="ACC broadcasting example implementation v7" Height="450" Width="800" Closing="Window_Closing">
    <Window.DataContext>
        <local:MainViewModel />
    </Window.DataContext>
    <Grid>
        <TabControl SelectedIndex="{Binding ActiveIndexPage}">
            <TabItem Header="Sys">
                <ClientConnections:ClientPanel DataContext="{Binding ClientPanelVM}" HorizontalAlignment="Left" Width="220" />
            </TabItem>
            <TabItem Header="Broadcasting">
                <Grid>
                    <Grid.RowDefinitions>
                        <RowDefinition Height="160"/>
                        <RowDefinition Height="*"/>
                    </Grid.RowDefinitions>
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition Width="700"/>
                        <ColumnDefinition Width="400"/>
                        <ColumnDefinition Width="*"/>
                    </Grid.ColumnDefinitions>
                    <ScrollViewer Grid.RowSpan="2" >
                        <Broadcasting:EntryListView DataContext="{Binding BroadcastingVM}" />
                    </ScrollViewer>
                    <Broadcasting:SessionInfoView DataContext="{Binding SessionInfoVM}" Grid.Column="1" />
                    <Broadcasting:TrackCameraView DataContext="{Binding BroadcastingVM.TrackVM}"  Grid.Column="1" Grid.ColumnSpan="2" Grid.Row="1" />
                    <Broadcasting:ReplayControlView DataContext="{Binding ReplayVM}" Grid.Column="2" Grid.RowSpan="2" />
                </Grid>
            </TabItem>
            <TabItem Header="Autopilot">
                <autopilot:AutopilotView DataContext="{Binding AutopilotVM}" />
            </TabItem>
        </TabControl>
    </Grid>
</Window>
