<UserControl x:Class="OVCS.ClientWpf.MultiVideoChatContainer"
             xmlns:omcs="clr-namespace:OMCS.Windows;assembly=OMCS"
             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:local="clr-namespace:OVCS.ClientWpf" 
             mc:Ignorable="d" Background="White" 
             xmlns:tools ="clr-namespace:OVCS.ClientWpf.Tools">
    <Grid Width="Auto" VerticalAlignment="Stretch" Height="Auto">
        <Grid.RowDefinitions>
            <RowDefinition Height="auto"/>
            <RowDefinition Height="*"/>
            <RowDefinition Height="50"/>
            <RowDefinition Height="auto"/>
        </Grid.RowDefinitions>
        <Grid  Grid.Row="0"  x:Name="topNav"  VerticalAlignment="Center" Background="DeepSkyBlue" Height="56">
            <Grid.ColumnDefinitions>
                <ColumnDefinition Width="auto"/>
                <ColumnDefinition Width="auto"/>
                <ColumnDefinition Width="*"/>
                <ColumnDefinition Width="auto"/>
            </Grid.ColumnDefinitions>
            <Grid  Grid.Column="0" Margin="10,0" >
                <Grid.RowDefinitions>
                    <RowDefinition Height="*"/>
                    <RowDefinition Height="*"/>
                </Grid.RowDefinitions>
                <StackPanel  Orientation = "Horizontal" Grid.Row="0">
                    <Label Content="主持人：" FontSize="15" Foreground="#FFFFFF"/>
                    <Label x:Name="skinLabel_userID" Content="" FontSize="15" Foreground="#FFFFFF" HorizontalContentAlignment="Left"/>
                </StackPanel>
                <StackPanel Orientation="Horizontal" Grid.Row="1">
                    <Label Content="人   数：" FontSize="15" Foreground="#FFFFFF"/>
                    <Label  x:Name="skinLabel_totalNum" Content="" FontSize="15" Foreground="#FFFFFF" HorizontalContentAlignment="Left"/>
                </StackPanel>
            </Grid>
            <StackPanel Grid.Column="1" Orientation="Horizontal">
                <Image  ToolTip="摄像头：开"  Source="Resources/CameraSelect.png"  Margin="8" x:Name="skinCheckBox_camera" MouseDown="skinCheckBox_camera_MouseDown" Width="35" Height="35"/>
                <Image  ToolTip="扬声器：开"  Source="Resources/SpeakerSelect.png" Margin="8" x:Name="skinCheckBox_speaker" MouseDown="skinCheckBox_speaker_MouseDown" Width="35" Height="35"/>
                <Image  ToolTip="麦克风：关"  Source="Resources/MicNoSelect.png" Margin="8" x:Name="skinCheckBox_mic" MouseDown="skinCheckBox_mic_MouseDown" Width="40" Height="40"/>
                <Image  ToolTip="远程桌面共享：关"  Source="Resources/DesktopNoSelect.png" Margin="8" x:Name="skinCheckBox_desk" MouseDown="skinCheckBox_desk_MouseDown" Width="40" Height="40"/>
                <Image  ToolTip="电子白板（主持人才有权限）：关" Visibility="Collapsed" Source="Resources/WhiteBoardNoSelect.png" Margin="8" x:Name="skinCheckBox_whilebord" MouseDown="skinCheckBox_whilebord_MouseDown" Width="40" Height="40"/>
                <Image  ToolTip="开始录制" x:Name="skinCheckBox_record"  Source="Resources/StartRecord.png" Width="35" Height="35" Margin="8" MouseDown="skinCheckBox_record_MouseDown"/>
                <Label  Visibility="Collapsed" Content="00:00:00" VerticalAlignment="Center" Foreground="#FFFFFF" x:Name="record_time"/>
                <Label  Visibility="Collapsed" Content="您正在共享桌面！" FontSize="15" VerticalAlignment="Center" Foreground="#FFFFFF" x:Name="deskTop_myself"/>
            </StackPanel>
            <Image  Visibility="Hidden" Source="Resources/FullScreen.png"  x:Name="deskTopFullScreen" MouseDown="deskTopFullScreen_MouseDown" ToolTip="" Height="32" Grid.Column="2" VerticalAlignment="Bottom" HorizontalAlignment="Right"/>
            <StackPanel HorizontalAlignment="Right" VerticalAlignment="Bottom" Orientation="Horizontal" Grid.Column="3" Background="Transparent" Margin="4,0,0,0">
                <Border  Background="#D5D5D5" x:Name="whiteBoardBtn" Height="30" Visibility="Collapsed" HorizontalAlignment="Right"  Width="60" MouseDown="whiteBoardBtn_Click">
                    <TextBlock  Block.TextAlignment="Center"  Text="电子白板"  VerticalAlignment="Center"/>
                </Border>
                <!--<Border x:Name="deskTopBtn" Background="#D5D5D5" Height="30" Visibility="Collapsed" HorizontalAlignment="Right" Margin="1,0,0,0" Width="60"  MouseDown="deskTopBtn_Click" >
                    <TextBlock Block.TextAlignment="Center" Text="远程桌面"  VerticalAlignment="Center" />
                </Border>-->
                <Border  x:Name="VideoBtn" Background="#87CEFA" Height="30" HorizontalAlignment="Right" Width="60" Margin="1,0,0,0" MouseDown="VideoBtn_Click" >
                    <TextBlock Block.TextAlignment="Center" VerticalAlignment="Center" Text="视频" />
                </Border>
            </StackPanel>
        </Grid>
        <Grid Grid.Row="1" Background="#121212">
            <tools:AutoScaleContainer x:Name="cameraViewbox" 
                        Width="{Binding RelativeSource={RelativeSource Mode=FindAncestor,AncestorType={x:Type Grid}},Path=ActualWidth}"
                        Height="{Binding RelativeSource={RelativeSource Mode=FindAncestor,AncestorType={x:Type Grid}},Path=ActualHeight}">
            </tools:AutoScaleContainer>
            <!--<omcs:WpfDesktopPanel Visibility="Hidden"  x:Name="desktopPanel" Background="White"/>-->
            <omcs:WpfWhiteBoardConnector Background="White" Visibility="Hidden" x:Name="whiteBoardConnecter"/>
        </Grid>
        <Grid Grid.Row="2"  Background="#202020">
            <ScrollViewer HorizontalScrollBarVisibility="Disabled" VerticalScrollBarVisibility="Auto" 
                          Margin="0,2,0,0"
                          Width="{Binding RelativeSource={RelativeSource Mode=FindAncestor,AncestorType={x:Type Grid}},Path=ActualWidth}" >
                <WrapPanel Orientation="Horizontal"  Background="#202020" x:Name="flowLayoutPanel2">
                    
                </WrapPanel>
            </ScrollViewer>
        </Grid>
        <Grid Grid.Row="3"  VerticalAlignment="Bottom" Background="DeepSkyBlue" Height="36" >
            <StackPanel Orientation="Horizontal">
                <TextBlock HorizontalAlignment="Left" Margin="10,0,0,0" Text="当前登录：" FontSize="15" VerticalAlignment="Center" Foreground="#FFF" />
                <TextBlock x:Name="myselfId" HorizontalAlignment="Left"  Text="aa01" FontSize="15" VerticalAlignment="Center" Foreground="#FFF" />
            </StackPanel>
            <TextBlock HorizontalAlignment="Right" Margin="0,0,20,0" x:Name="userDeviceState" Text="" FontSize="15" VerticalAlignment="Center" Foreground="#FFF" />
        </Grid>
    </Grid>
</UserControl>
