<UserControl
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
             xmlns:dx="http://schemas.devexpress.com/winfx/2008/xaml/core" 
             x:Class="VIZ.TVP.CBA.Module.MainView"
             xmlns:moduel="clr-namespace:VIZ.TVP.CBA.Module"
             mc:Ignorable="d"
             d:DesignHeight="800" d:DesignWidth="1300">


    <UserControl.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <ResourceDictionary Source="/VIZ.TVP.CBA.Module;component/Style/DataGrid.xaml"></ResourceDictionary>
                <ResourceDictionary Source="/VIZ.TVP.CBA.Module;component/Style/CheckBox_Default.xaml"></ResourceDictionary>
            </ResourceDictionary.MergedDictionaries>
        </ResourceDictionary>
    </UserControl.Resources>

    <Grid>

        <Grid.RowDefinitions>
            <RowDefinition Height="40"/>
            <RowDefinition Height="*"/>
        </Grid.RowDefinitions>


        <WrapPanel  Grid.Row="0" >

            <Grid>
                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="100"/>
                    <ColumnDefinition Width="200"/>
                    <ColumnDefinition Width="100"/>
                    <ColumnDefinition Width="200"/>
                    <ColumnDefinition Width="200"/>
                    <ColumnDefinition Width="450"/>
                </Grid.ColumnDefinitions>

                <!--<TextBlock Text="比赛日期:" Grid.Column="0" FontSize="20" Foreground="White" HorizontalAlignment="Center" VerticalAlignment="Center"/>

                <DatePicker Grid.Column="1" HorizontalAlignment="Center" Name="Date_MatchDateInfo" Width="200" 
                              SelectedDate="{Binding MatchDate,Mode=TwoWay}" FontSize="20" Style="{StaticResource DatePicker_Black}" SelectedDateChanged="Date_MatchDateInfo_SelectedDateChanged" >
                </DatePicker>

                <TextBlock Text="赛程:" Grid.Column="2" FontSize="20" Foreground="White" HorizontalAlignment="Center" VerticalAlignment="Center"/>

                <ComboBox  Grid.Column="3" Style="{StaticResource ComboBoxStyle}"   HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="20"
                          Width="200" ItemsSource="{Binding Path=MatchItems,Mode=TwoWay}" 
                          SelectedItem="{Binding Path=SelectMatchItems,Mode=TwoWay}" SelectionChanged="ComboBox_SelectionChanged">
                </ComboBox>

                <TextBox Grid.Column="4" Foreground="White" Background="Black" FontSize="20" HorizontalAlignment="Center" VerticalAlignment="Center" Text="{Binding MatchStatus,Mode=TwoWay}" Width="80"/>-->


                <StackPanel Orientation="Horizontal" Margin="0,0,5,0" HorizontalAlignment="Right" Grid.Column="5">
                    <CheckBox Style="{StaticResource CheckBox_VizConnection}" IsChecked="{Binding Path=IsConnected,Mode=TwoWay}" 
                          IsHitTestVisible="False"></CheckBox>
                    <ComboBox Height="20" Width="200" Margin="10,0,0,0"
                              ItemsSource="{Binding Path=VizConnections}" 
                              SelectedValue="{Binding Path=SelectedVizConnection,Mode=TwoWay}">
                        <ComboBox.ItemTemplate>
                            <DataTemplate>
                                <StackPanel Orientation="Horizontal">
                                    <TextBlock VerticalAlignment="Center" Text="{Binding Path=IP}"></TextBlock>
                                    <TextBlock VerticalAlignment="Center" Text=":" Margin="5,0,5,0"></TextBlock>
                                    <TextBlock VerticalAlignment="Center" Text="{Binding Path=Port}"></TextBlock>
                                </StackPanel>
                            </DataTemplate>
                        </ComboBox.ItemTemplate>
                    </ComboBox>
                    <!-- 主库连接按钮 -->
                    <Button Grid.Column="4" Height="20" Width="80" Content="连接" Margin="10,0,0,0" 
                        Command="{Binding Path=ConnectCommand}"
                        IsEnabled="{Binding Path=IsConnectButtonEnabled}"></Button>
                    <Button Grid.Column="4" Height="20" Width="80" Content="断开" Margin="10,0,0,0" 
                        Command="{Binding Path=DisconnectCommand}"
                        IsEnabled="{Binding Path=IsConnectButtonEnabled}"></Button>
                </StackPanel>

            </Grid>
        </WrapPanel>
        <!--<dx:DXTabControl Grid.Row="1" Background="Black">
            <dx:DXTabItem Header="今日赛程" Background="Black">
                <Grid Background="Black">
                    <my:DayMatchUI>
                    </my:DayMatchUI>
                </Grid>
            </dx:DXTabItem>
            
            <dx:DXTabItem Header="球队排行榜" Background="Black">
                <Grid Background="Black">
                    <team:TeamStandingUI>
                    </team:TeamStandingUI>
                </Grid>
            </dx:DXTabItem>

            <dx:DXTabItem Header="本轮和下轮对阵" Background="Black">
                <Grid>
                    <round:RoundMatchUI>
                        
                    </round:RoundMatchUI>
                </Grid>
            </dx:DXTabItem>

            <dx:DXTabItem Header="球队数据对比" Background="Black">
                <Grid>
                    <teamStats:TeamStatsUI>
                        
                    </teamStats:TeamStatsUI>
                </Grid>
            </dx:DXTabItem>

            <dx:DXTabItem Header="单人球员" Background="Black">
                <Grid>
                    <single:SinglePlayerUI>
                        
                    </single:SinglePlayerUI>
                </Grid>
            </dx:DXTabItem>

            <dx:DXTabItem Header="球队数据对比" Background="Black">
                <Grid>
                    <playCom:PlayerComPareUI>
                        
                    </playCom:PlayerComPareUI>
                </Grid>
            </dx:DXTabItem>
        </dx:DXTabControl>-->

        <TabControl Grid.Row="1" >


            <!--<TabItem Header="text" FontSize="20">
                <Grid>
                    <moduel:DayMatchNewView>

                    </moduel:DayMatchNewView>
                </Grid>
            </TabItem>-->
            
            <TabItem Header="设置" FontSize="20">
                <Grid>
                    <moduel:HttpUrlConfigView>

                    </moduel:HttpUrlConfigView>
                </Grid>
            </TabItem>

            <TabItem Header="今日赛程"  FontSize="20">
                <Grid >
                    <moduel:DayMatchView>
                    </moduel:DayMatchView>
                </Grid>
            </TabItem>

            <TabItem Header="球队排行榜"  FontSize="20">
                <Grid >
                    <moduel:TeamStandingView>
                    </moduel:TeamStandingView>
                </Grid>
            </TabItem>

            <TabItem Header="本轮和下轮对阵" FontSize="20">
                <Grid>
                    <moduel:RoundMatchView>

                    </moduel:RoundMatchView>
                </Grid>
            </TabItem>

            <TabItem Header="球队数据对比"  FontSize="20">
                <Grid>
                    <moduel:TeamStatsView>

                    </moduel:TeamStatsView>
                </Grid>
            </TabItem>

            <TabItem Header="单人球员"  FontSize="20">
                <Grid>

                    <moduel:SinglePlayerView>

                    </moduel:SinglePlayerView>
                </Grid>
            </TabItem>


            <TabItem Header="球员数据对比" FontSize="20">
                <Grid>

                    <moduel:PlayerComPareView>

                    </moduel:PlayerComPareView>
                </Grid>
            </TabItem>

            <TabItem Header="查看" FontSize="20">
                <Grid>
                    <moduel:DateHeaderView>
                        
                    </moduel:DateHeaderView>
                </Grid>
            </TabItem>


            <TabItem Header="新球员对比" FontSize="20">
                <Grid>
                    <moduel:NewPlayerComPareView>
                        
                    </moduel:NewPlayerComPareView>
                </Grid>
            </TabItem>

            <TabItem Header="新球队数据对比" FontSize="20">
                <Grid>
                    <moduel:NewTeamStatsView>
                    </moduel:NewTeamStatsView>
                </Grid>
            </TabItem>


            <TabItem Header="新单个球员数据" FontSize="20">
                <Grid>
                    <moduel:NewSinglePlayerView>
                        
                    </moduel:NewSinglePlayerView>
                </Grid>
            </TabItem>
            <TabItem Header="MVP球员" FontSize="20">
                <Grid>
                    <moduel:MvpPlayerView>
                        
                    </moduel:MvpPlayerView>
                </Grid>
            </TabItem>




        </TabControl>

    </Grid>
</UserControl>
