JianGongYun/JianGongYun/TRTC/Windows/LiveWindow.xaml

281 lines
30 KiB
XML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<Metro:MetroWindow x:Class="JianGongYun.TRTC.Windows.LiveWindow"
xmlns:Metro="clr-namespace:AduSkin.Controls.Metro;assembly=AduSkin"
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:JianGongYun.TRTC.Windows"
xmlns:live="clr-namespace:JianGongYun.TRTC"
mc:Ignorable="d"
Title="建工云课堂" MinWidth="1000" MinHeight="650"
d:DesignHeight="1200" d:DesignWidth="1600"
BorderThickness="0" WindowStyle="None"
WindowStartupLocation="CenterOwner"
Background="#232428">
<!--窗口填满-->
<Metro:MetroWindow.Resources>
<Geometry x:Key="Icon_Setting">M372.134088 1004.846981a509.94041 509.94041 0 0 1-159.298198-76.821527l2.164315-103.514738a93.088793 93.088793 0 0 0-74.238313-93.088794l-101.536602-20.991523A509.428422 509.428422 0 0 1 0.011636 537.983409l82.243949-62.834935a93.088793 93.088793 0 0 0 26.507034-116.104998l-46.89348-92.390627A514.152678 514.152678 0 0 1 172.225904 128.415991l100.419536 25.133974a93.088793 93.088793 0 0 0 107.284834-51.664281l43.007023-94.252403a515.246472 515.246472 0 0 1 88.434354-7.610009c30.137497 0 59.669917 2.606486 88.411081 7.610009l43.007023 94.252403a93.088793 93.088793 0 0 0 107.284834 51.664281l100.396264-25.133974a514.152678 514.152678 0 0 1 110.356765 138.236858l-46.870208 92.390627a93.088793 93.088793 0 0 0 26.483762 116.104998l82.243949 62.834935a509.428422 509.428422 0 0 1-39.213654 172.44699l-101.51333 20.968251a93.088793 93.088793 0 0 0-74.238312 93.088793l2.141042 103.538011a509.94041 509.94041 0 0 1-159.298198 76.798255l-79.684007-66.279221a93.088793 93.088793 0 0 0-119.060567 0l-79.684007 66.302493zM511.348378 721.461421a209.449785 209.449785 0 1 0 0-418.89957 209.449785 209.449785 0 0 0 0 418.89957z</Geometry>
<Geometry x:Key="Icon_Camera">M512 85.33312C323.499138 85.33312 170.66752 238.164738 170.66752 426.6656s152.831618 341.33248 341.33248 341.33248 341.33248-152.831618 341.33248-341.33248S700.500862 85.33312 512 85.33312zM85.3344 426.6656C85.3344 191.032411 276.366811 0 512 0c235.661633 0 426.6656 191.032411 426.6656 426.6656 0 235.661633-191.003967 426.6656-426.6656 426.6656-235.633189 0-426.6656-191.003967-426.6656-426.6656z m127.99968 554.66528A42.66656 42.66656 0 0 1 256.00064 938.66432h511.99872a42.66656 42.66656 0 1 1 0 85.33312H256.00064a42.66656 42.66656 0 0 1-42.66656-42.66656z M459.776131 775.166062a42.239894 42.239894 0 0 1 19.114618 56.888747l-85.560675 169.642242a42.951004 42.951004 0 0 1-56.774969 17.806178 42.239894 42.239894 0 0 1-19.71195-55.722527l85.560675-169.642243a42.951004 42.951004 0 0 1 57.372301-18.972397z m132.892112 0a42.239894 42.239894 0 0 0-19.114619 56.888747l85.560675 169.642242a42.951004 42.951004 0 0 0 56.774969 17.806178 42.239894 42.239894 0 0 0 19.711951-55.722527l-85.560675-169.642243a42.951004 42.951004 0 0 0-57.372301-18.972397zM526.222187 321.136975c-61.439846 0-111.2175 49.350988-111.2175 110.250391 0 60.927848 49.777653 110.278835 111.2175 110.278835s111.2175-49.350988 111.217499-110.278835c0-60.870959-49.777653-110.250391-111.217499-110.250391z m-196.806619 110.250391c0-107.747286 88.120669-195.099957 196.806619-195.099957 108.685951 0 196.806619 87.352671 196.806619 195.128401 0 107.747286-88.120669 195.099957-196.806619 195.099957-108.685951 0-196.806619-87.352671-196.806619-195.128401zM526.222187 28.444373c23.60883 0 42.780337 19.000841 42.780337 42.410561v63.630063c0 23.409719-19.143063 42.382116-42.780337 42.382116-23.60883 0-42.780337-18.972397-42.780338-42.382116V70.82649c0-23.409719 19.143063-42.410561 42.780338-42.410561z</Geometry>
<Geometry x:Key="Icon_Screen">M864 159.872L160 160c-17.696 0-32 14.176-32 31.872v448a32 32 0 0 0 32 32h704a32 32 0 0 0 32-32v-448a32 32 0 0 0-32-32zM864 640H160V191.872h704V640z M928 32H96a96 96 0 0 0-96 96v640a95.904 95.904 0 0 0 95.68 95.936H416v38.944l-199.744 25.952A31.968 31.968 0 0 0 224 991.872h576a32 32 0 0 0 7.744-63.072L608 902.88v-38.944h320.32A95.904 95.904 0 0 0 1024 768V128a96 96 0 0 0-96-96z m32 736c0 17.632-14.368 32-32 32H96c-17.664 0-32-14.368-32-32V128a32 32 0 0 1 32-32h832c17.632 0 32 14.336 32 32v640z</Geometry>
<Geometry x:Key="Icon_Mic">M486.4 972.8v-128.9728A332.8 332.8 0 0 1 179.2 512a25.6 25.6 0 0 1 51.2 0 281.6 281.6 0 0 0 563.2 0 25.6 25.6 0 1 1 51.2 0 332.8 332.8 0 0 1-307.2 331.8272V972.8h153.6a25.6 25.6 0 1 1 0 51.2h-358.4a25.6 25.6 0 1 1 0-51.2h153.6zM512 51.2a153.6 153.6 0 0 0-153.6 153.6v307.2a153.6 153.6 0 0 0 307.2 0V204.8a153.6 153.6 0 0 0-153.6-153.6z m0-51.2a204.8 204.8 0 0 1 204.8 204.8v307.2a204.8 204.8 0 1 1-409.6 0V204.8a204.8 204.8 0 0 1 204.8-204.8z</Geometry>
<Geometry x:Key="Icon_User">M511.626 1.896C229.572 1.896 0.927 230.541 0.927 512.595c0 282.055 228.645 510.699 510.699 510.699s510.698-228.645 510.698-510.699S793.68 1.896 511.626 1.896z m0 69.641c243.606 0 441.058 197.474 441.058 441.058 0 87.347-25.392 168.762-69.194 237.271-73.419-77.609-170.944-132.204-280.597-151.829 70.004-33.755 118.404-105.164 118.404-188.066 0-115.388-93.535-208.922-208.923-208.922S303.452 294.583 303.452 409.97c0 82.902 48.399 154.311 118.403 188.066-110.093 19.704-207.96 74.661-281.479 152.77-44.177-68.704-69.808-150.465-69.808-238.211 0-243.584 197.496-441.058 441.058-441.058z</Geometry>
<Geometry x:Key="Icon_ChangeScreen">M447.5904 819.1488H166.4a89.6 89.6 0 0 1-89.6-89.4976V166.4c0-49.3568 40.192-89.5488 89.6-89.5488h563.2c49.4592 0 89.6512 40.192 89.6512 89.5488v281.6H896v-281.6A166.5536 166.5536 0 0 0 729.6 0h-563.2A166.5536 166.5536 0 0 0 0 166.4v563.2512A166.656 166.656 0 0 0 166.4 896h281.1904v-76.8512z M947.2 238.5408V857.6c0 49.408-40.192 89.6-89.6 89.6H242.7904V1024H857.6A166.6048 166.6048 0 0 0 1024 857.6V238.5408h-76.8z M577.8944 813.8752h235.9808v-236.032h-76.8v104.96l-395.776-395.8784h104.9088V210.176H210.1248v235.9808h76.8V341.248l395.9296 395.8784h-104.96z</Geometry>
<Geometry x:Key="Icon_Ban">M2.896 921.614L924.656 0l102.385 102.386L105.354 1024z</Geometry>
<BooleanToVisibilityConverter x:Key="VisibilityOfBool" />
<live:UnBooleanToVisibilityConverter x:Key="UnVisibilityOfBool" />
<!--直播方式数据类型转换-->
<live:LiveTypeToBoolConverter x:Key="LiveTypeConverter"></live:LiveTypeToBoolConverter>
<!--可分享屏幕自定义容器-->
<ControlTemplate x:Key="ShareListTemplate">
<WrapPanel IsItemsHost="True"></WrapPanel>
</ControlTemplate>
<!--可分享屏幕自定义选项-->
<DataTemplate x:Key="ShareListItemTemplate">
<StackPanel Orientation="Vertical" Width="300" Height="230" Background="#232428" Margin="5">
<Image Margin="10 5 10 0" Width="280" Height="200" Source="{Binding Thumb}"></Image>
<TextBlock HorizontalAlignment="Center" Width="280" TextAlignment="Left" TextTrimming="CharacterEllipsis" Text="{Binding Path=SourceName}" Foreground="White"></TextBlock>
</StackPanel>
</DataTemplate>
</Metro:MetroWindow.Resources>
<Metro:MetroWindow.Menu>
<Metro:MetroTitleMenu Visibility="{Binding IsLive, Converter={StaticResource VisibilityOfBool}}" Height="40" HorizontalAlignment="Center">
<Metro:MetroTitleMenuItem Header="收起窗口" Click="PackUp_Click">
</Metro:MetroTitleMenuItem>
</Metro:MetroTitleMenu>
</Metro:MetroWindow.Menu>
<Canvas x:Name="Root" Background="Transparent">
<!--父容器填满-->
<DockPanel Panel.ZIndex="0" Height="{Binding ElementName=Root,Path=ActualHeight}" Width="{Binding ElementName=Root,Path=ActualWidth}">
<!--上方标题面板-->
<Canvas DockPanel.Dock="Top" Height="60" Background="#232428">
<StackPanel Height="30">
<TextBlock VerticalAlignment="Center" FontSize="16" Padding="20 6" Foreground="White">
<Bold>
<Run Text="{Binding ClassroomEntity.ClassHead,Mode=OneTime}"></Run>
</Bold>
</TextBlock>
</StackPanel>
<StackPanel FlowDirection="LeftToRight" Orientation="Horizontal" Canvas.Top="30" Height="25">
<TextBlock FontSize="14" Padding="25 0 0 0" Foreground="#bbbbbb" Text="{Binding ClassroomEntity.ClassSubHead,Mode=OneTime}"></TextBlock>
<TextBlock FontSize="14" Padding="15 0 0 0" Foreground="#bbbbbb" Text="当前教室共有:"></TextBlock>
<TextBlock FontSize="14" Foreground="#3d7cf9" Text="{Binding StudentCount,Mode=OneWay}"></TextBlock>
<TextBlock FontSize="14" Padding="3 0 0 0" Foreground="#bbbbbb" Text="人"></TextBlock>
</StackPanel>
<Metro:AduFlatButton Content="开始直播" Click="StartLive_Click" Tag="True" Canvas.Bottom="13" Canvas.Right="25" Visibility="{Binding IsLive, Converter={StaticResource UnVisibilityOfBool}}"></Metro:AduFlatButton>
<Metro:AduFlatButton Content="结束直播" x:Name="stoplive" Click="StartLive_Click" Tag="False" Type="error" Canvas.Bottom="13" Canvas.Right="25" Visibility="{Binding IsLive, Converter={StaticResource VisibilityOfBool}}"></Metro:AduFlatButton>
<StackPanel Visibility="{Binding IsLive, Converter={StaticResource VisibilityOfBool}}" Orientation="Horizontal" Canvas.Bottom="20" Canvas.Right="150">
<Ellipse VerticalAlignment="Center" Width="10" Fill="#00cc66" Height="10"></Ellipse>
<TextBlock FontSize="15" Foreground="White" Margin="7 0 0 0">直播中</TextBlock>
<TextBlock FontSize="15" Foreground="White" Margin="7 0 0 0" Text="{Binding LiveTimeCount}"></TextBlock>
</StackPanel>
</Canvas>
<!--右方聊天学员面板-->
<Canvas x:Name="ChatWrap" DockPanel.Dock="Right" Width="280" Background="#2f3035">
<DockPanel Height="{Binding ElementName=ChatWrap,Path=ActualHeight}" Width="{Binding ElementName=ChatWrap,Path=ActualWidth}">
<DockPanel Height="60" DockPanel.Dock="Bottom">
<Button PreviewKeyDown="Button_PreviewKeyDown" Click="Button_Click" Foreground="White" Background="#3e7fff" Margin="0 12 12 12" Width="70" DockPanel.Dock="Right">发 送</Button>
<TextBox x:Name="ChatIpt" PreviewKeyDown="TextBox_PreviewKeyDown" VerticalContentAlignment="Center" Padding="12 0" Foreground="White" Background="Transparent" Margin="12 12 0 12"></TextBox>
</DockPanel>
<Border BorderBrush="#888" BorderThickness="0 0 0 1">
<Grid>
<local:ScrollingListBox x:Name="ChatList" BorderThickness="0" ScrollViewer.HorizontalScrollBarVisibility="Disabled" ItemsSource="{Binding Chats}" Background="Transparent">
<ListBox.Resources>
<Style TargetType="ScrollViewer" BasedOn="{StaticResource CusScroll}"></Style>
<Style TargetType="local:ScrollingListBox">
<Setter Property="ItemContainerStyle">
<Setter.Value>
<Style TargetType="ListBoxItem">
<Setter Property="HorizontalContentAlignment" Value="Stretch"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type ListBoxItem}">
<Border x:Name="Border" BorderThickness="0">
<Label x:Name="Label" VerticalAlignment="Center" Padding="12" HorizontalAlignment="Left" FontSize="13px">
<ContentPresenter></ContentPresenter>
</Label>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsSelected" Value="True">
<Setter TargetName="Border" Property="BorderBrush" Value="#efefef"></Setter>
<!--<Setter TargetName="Border" Property="Background" Value="{StaticResource itembg}"></Setter>-->
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</Setter.Value>
</Setter>
</Style>
</ListBox.Resources>
<ListBox.ItemTemplate>
<!--自定义ListBox项样式-->
<DataTemplate>
<StackPanel>
<StackPanel Orientation="Horizontal">
<TextBlock Foreground="#3c77eb" TextWrapping="Wrap" Text="{Binding Path=Nick}">
</TextBlock>
<TextBlock Margin="6 0 0 0" Foreground="#888888" TextWrapping="Wrap" Text="{Binding Path=Date}">
</TextBlock>
</StackPanel>
<TextBlock Margin="0 6 0 0" Foreground="White" TextWrapping="Wrap" Text="{Binding Path=Body}">
</TextBlock>
</StackPanel>
</DataTemplate>
</ListBox.ItemTemplate>
</local:ScrollingListBox>
</Grid>
</Border>
</DockPanel>
</Canvas>
<!--下方教程面板-->
<Canvas DockPanel.Dock="Bottom" Height="30" Background="#2a2b30">
</Canvas>
<!--下方设置面板-->
<Canvas DockPanel.Dock="Bottom" Height="70" Background="#232428">
<!--设置按钮-->
<Button Click="Setting_Btn_Click" Visibility="{Binding IsLive, Converter={StaticResource UnVisibilityOfBool}}" Style="{StaticResource CusIconBtn}" Canvas.Left="27" Canvas.Top="15" Background="Transparent" BorderThickness="0">
<Button.Content>
<StackPanel>
<Path Width="18" Height="18" Fill="#aaaaaa" Shape.Stretch="Fill" Data="{StaticResource Icon_Setting}" />
<TextBlock Foreground="#aaaaaa" Margin="0 3 0 0">设置</TextBlock>
</StackPanel>
</Button.Content>
</Button>
<StackPanel Visibility="{Binding IsLive, Converter={StaticResource VisibilityOfBool}}" Orientation="Horizontal" Canvas.Right="27" Canvas.Top="10" Height="50">
<Canvas HorizontalAlignment="Right" Height="50" Width="50">
<Metro:AduSysButton ToolTip="禁用/启用声音" Click="SetMute_Click" Foreground="#aaaaaa" IconHeight="25" IconWidth="18" CornerRadius="6" Height="50" Width="50" Icon="{StaticResource Icon_Mic}" Content="" />
<Metro:AduSysButton ToolTip="禁用/启用声音" Click="SetMute_Click" Visibility="{Binding MicMute, Converter={StaticResource VisibilityOfBool}}" Foreground="#aaaaaa" IconHeight="25" IconWidth="25" CornerRadius="6" Height="50" Width="50" Icon="{StaticResource Icon_Ban}" Content="" />
</Canvas>
<Canvas HorizontalAlignment="Right" Height="50" Width="50">
<Metro:AduSysButton ToolTip="禁用/启用摄像头" Click="SetCamera_Click" Foreground="#aaaaaa" IconHeight="25" IconWidth="20" CornerRadius="6" Height="50" Width="50" Icon="{StaticResource Icon_Camera}" Content="" />
<Metro:AduSysButton ToolTip="禁用/启用摄像头" Click="SetCamera_Click" Visibility="{Binding CameraRunning, Converter={StaticResource UnVisibilityOfBool}}" Foreground="#aaaaaa" IconHeight="25" IconWidth="25" CornerRadius="6" Height="50" Width="50" Icon="{StaticResource Icon_Ban}" Content="" />
</Canvas>
<Canvas HorizontalAlignment="Right" Height="50" Width="50">
<Metro:AduSysButton ToolTip="禁用/启用桌面分享" Click="SetScreen_Click" Foreground="#aaaaaa" IconHeight="25" IconWidth="24" CornerRadius="6" Height="50" Width="50" Icon="{StaticResource Icon_Screen}" Content="" />
<Metro:AduSysButton ToolTip="禁用/启用桌面分享" Click="SetScreen_Click" Visibility="{Binding ScreenRunning, Converter={StaticResource UnVisibilityOfBool}}" Foreground="#aaaaaa" IconHeight="25" IconWidth="25" CornerRadius="6" Height="50" Width="50" Icon="{StaticResource Icon_Ban}" Content="" />
</Canvas>
<Canvas HorizontalAlignment="Right" Height="50" Width="50">
<Metro:AduSysButton Click="ChangeWin_Click" ToolTip="切换分享窗口" Foreground="#aaaaaa" IconHeight="25" IconWidth="24" CornerRadius="6" Height="50" Width="50" Icon="{StaticResource Icon_ChangeScreen}" Content="" />
</Canvas>
</StackPanel>
</Canvas>
<!--中间面板-->
<Canvas x:Name="CusContent" Background="#151618">
<!--直播前-->
<Grid Canvas.Top="0" Canvas.Left="0" Background="#aa151618" Height="{Binding ElementName=CusContent,Path=ActualHeight}" Width="{Binding ElementName=CusContent,Path=ActualWidth}" Visibility="{Binding IsLive, Converter={StaticResource UnVisibilityOfBool}}">
<Canvas x:Name="BeforeLivePanel">
<!--屏幕预览容器-->
<Grid x:Name="BeforeLiveSubViewWrap" Width="{Binding ElementName=BeforeLivePanel,Path=ActualWidth}" Height="{Binding ElementName=BeforeLivePanel,Path=ActualHeight}" Canvas.Top="0" Canvas.Left="0"></Grid>
<!--标题和直播类型选项-->
<Grid Width="{Binding ElementName=BeforeLivePanel,Path=ActualWidth}" Height="{Binding ElementName=BeforeLivePanel,Path=ActualHeight}" Canvas.Top="0" Canvas.Left="0">
<StackPanel Width="500" VerticalAlignment="Center">
<TextBlock FontSize="30" Foreground="#999999" HorizontalAlignment="Center">请选择授课方式</TextBlock>
<TextBlock HorizontalAlignment="Center" FontSize="16" Margin="0 10 0 0" Foreground="#999999">您可在上课期间随时调整授课方式</TextBlock>
<Grid Margin="0 30 0 0" Height="300">
<Grid.ColumnDefinitions>
<!--<ColumnDefinition></ColumnDefinition>
<ColumnDefinition></ColumnDefinition>-->
<ColumnDefinition></ColumnDefinition>
<ColumnDefinition></ColumnDefinition>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition></RowDefinition>
<RowDefinition></RowDefinition>
</Grid.RowDefinitions>
<!--Grid.RowSpan="2" Grid.ColumnSpan="2"-->
<Grid Margin="5" Grid.Row="0" Grid.Column="0" Background="#2f3035">
<Canvas x:Name="CameraPrew">
<Grid Width="{Binding ElementName=CameraPrew,Path=ActualWidth}" Height="{Binding ElementName=CameraPrew,Path=ActualHeight}" Canvas.Top="0" Canvas.Left="0">
<Path Margin="0 0 0 30" Width="111" Height="111" Fill="#cccccc" Shape.Stretch="Fill" Data="{StaticResource Icon_User}" />
</Grid>
<!--摄像头预览容器-->
<Grid x:Name="BeforeLiveViewWrap" Width="{Binding ElementName=CameraPrew,Path=ActualWidth}" Height="{Binding ElementName=CameraPrew,Path=ActualHeight}" Canvas.Top="0" Canvas.Left="0"></Grid>
<TextBlock Width="{Binding ElementName=CameraPrew,Path=ActualWidth}" Canvas.Bottom="0" Canvas.Left="0" Padding="5" FontSize="14" Foreground="#cccccc" Background="#65888888" TextAlignment="Center">摄像头预览</TextBlock>
</Canvas>
</Grid>
<!--<Grid Margin="5" Background="#2f3035" Grid.Row="0" Grid.Column="2">
<StackPanel VerticalAlignment="Center" HorizontalAlignment="Center">
<StackPanel Margin="0 0 0 20" HorizontalAlignment="Center" Orientation="Horizontal">
<Path Width="30" Height="35" Fill="#cccccc" Shape.Stretch="Fill" Data="{StaticResource Icon_Camera}" />
<TextBlock FontSize="30" Margin="10 0" Foreground="#cccccc">+</TextBlock>
<Path Width="30" Height="30" Fill="#cccccc" Shape.Stretch="Fill" Data="{StaticResource Icon_Screen}" />
</StackPanel>
<Metro:AduRadioButton x:Name="Rad1" Click="Tpye_Click" GroupName="LiveType" Foreground="#cccccc" Content="摄像头+屏幕分享" FontSize="14" IconWidth="16" IsChecked="{Binding LiveType,Converter={StaticResource LiveTypeConverter},ConverterParameter=CameraAndScreen}" />
</StackPanel>
</Grid>-->
<Grid Margin="5" Background="#2f3035" Grid.Row="1" Grid.Column="0">
<StackPanel VerticalAlignment="Center" HorizontalAlignment="Center">
<Path Margin="0 0 0 30" Width="30" Height="30" Fill="#cccccc" Shape.Stretch="Fill" Data="{StaticResource Icon_Screen}" />
<Metro:AduRadioButton x:Name="Rad2" Click="Tpye_Click" GroupName="LiveType" Foreground="#cccccc" Content="屏幕分享" FontSize="14" IconWidth="16" IsChecked="{Binding LiveType,Converter={StaticResource LiveTypeConverter},ConverterParameter=OnlyScreen}" />
</StackPanel>
</Grid>
<Grid Margin="5" Background="#2f3035" Grid.Row="0" Grid.Column="1">
<StackPanel VerticalAlignment="Center" HorizontalAlignment="Center">
<Path Margin="0 0 0 25" Width="30" Height="35" Fill="#cccccc" Shape.Stretch="Fill" Data="{StaticResource Icon_Camera}" />
<Metro:AduRadioButton x:Name="Rad3" Click="Tpye_Click" GroupName="LiveType" Foreground="#cccccc" Content="摄像头" FontSize="14" IconWidth="16" IsChecked="{Binding LiveType,Converter={StaticResource LiveTypeConverter},ConverterParameter=OnlyCamera}" />
</StackPanel>
</Grid>
<Grid Margin="5" Background="#2f3035" Grid.Row="1" Grid.Column="1">
<StackPanel VerticalAlignment="Center" HorizontalAlignment="Center">
<Path Margin="0 0 0 15" Width="30" Height="45" Fill="#cccccc" Shape.Stretch="Fill" Data="{StaticResource Icon_Mic}" />
<Metro:AduRadioButton x:Name="Rad4" Click="Tpye_Click" GroupName="LiveType" Foreground="#cccccc" Content="仅声音" FontSize="14" IconWidth="16" IsChecked="{Binding LiveType,Converter={StaticResource LiveTypeConverter},ConverterParameter=OnlyAudio}" />
</StackPanel>
</Grid>
</Grid>
</StackPanel>
</Grid>
</Canvas>
</Grid>
<!--直播中-->
<Grid Canvas.Top="0" Canvas.Left="0" Height="{Binding ElementName=CusContent,Path=ActualHeight}" Width="{Binding ElementName=CusContent,Path=ActualWidth}" Visibility="{Binding IsLive, Converter={StaticResource VisibilityOfBool}}">
<Canvas x:Name="AfterLivePanel">
<Grid Visibility="{Binding MicMute, Converter={StaticResource UnVisibilityOfBool}}" Width="{Binding ElementName=AfterLivePanel,Path=ActualWidth}" Height="{Binding ElementName=AfterLivePanel,Path=ActualHeight}" Canvas.Top="0" Canvas.Left="0">
<TextBlock HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#aaaaaa" FontSize="14" >仅开启声音</TextBlock>
</Grid>
<Grid Visibility="{Binding MicMute, Converter={StaticResource VisibilityOfBool}}" Width="{Binding ElementName=AfterLivePanel,Path=ActualWidth}" Height="{Binding ElementName=AfterLivePanel,Path=ActualHeight}" Canvas.Top="0" Canvas.Left="0">
<TextBlock HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="#aaaaaa" FontSize="14" >所有设备被关闭</TextBlock>
</Grid>
<!--屏幕预览容器-->
<Grid x:Name="AfterLiveSubViewWrap" Width="{Binding ElementName=AfterLivePanel,Path=ActualWidth}" Height="{Binding ElementName=AfterLivePanel,Path=ActualHeight}" Canvas.Top="0" Canvas.Left="0"></Grid>
<!--摄像头预览容器-->
<Grid Width="{Binding ElementName=AfterLivePanel,Path=ActualWidth}" Height="{Binding ElementName=AfterLivePanel,Path=ActualHeight}" Canvas.Top="0" Canvas.Left="0">
<Grid Style="{Binding MainBigWrapStyle}" Width="{Binding ElementName=AfterLivePanel,Path=ActualHeight}">
<Border Style="{Binding MainSmallWrapStyle}" Visibility="{Binding CameraRunning, Converter={StaticResource VisibilityOfBool}}" BorderBrush="#efefef">
<Grid x:Name="AfterLiveViewWrap"></Grid>
</Border>
</Grid>
</Grid>
</Canvas>
</Grid>
</Canvas>
</DockPanel>
<Grid x:Name="CountdownWrap" Visibility="Hidden" Canvas.Top="0" Canvas.Left="0" Background="Transparent" Panel.ZIndex="10" Height="{Binding ElementName=Root,Path=ActualHeight}" Width="{Binding ElementName=Root,Path=ActualWidth}"></Grid>
<!--可分享屏幕列表-->
<Grid x:Name="ShareScreenListWrap" Visibility="{Binding ShowShareScreenList, Converter={StaticResource VisibilityOfBool}}" Canvas.Top="0" Canvas.Left="0" Background="Transparent" Panel.ZIndex="5" Height="{Binding ElementName=Root,Path=ActualHeight}" Width="{Binding ElementName=Root,Path=ActualWidth}">
<Border Width="970" Height="530" BorderBrush="#efefef" BorderThickness="2" CornerRadius="5">
<Canvas x:Name="ScrollWrap" Width="970" Height="530" HorizontalAlignment="Center" VerticalAlignment="Center" Background="#f12f3035">
<!--标题-->
<StackPanel Width="{Binding ElementName=ScrollWrap,Path=ActualWidth}">
<TextBlock Foreground="White" FontSize="20" FontWeight="Bold" Padding="10" HorizontalAlignment="Center" VerticalAlignment="Center">请选择要分享的屏幕或前台窗口(上课期间可随时切换)</TextBlock>
</StackPanel>
<!--列表视图-->
<!--Style="{StaticResource CusScroll}"-->
<ScrollViewer Style="{StaticResource CusScroll}" Canvas.Right="0" Canvas.Top="50" Height="480" Width="{Binding ElementName=ScrollWrap,Path=ActualWidth}">
<ListBox MouseUp="ShareList_Selected" SelectedValuePath="Info" SelectedValue="{Binding CurrentShareScreen}" ItemsSource="{Binding LiveScreens}" Template="{StaticResource ShareListTemplate}" ItemTemplate="{StaticResource ShareListItemTemplate}"></ListBox>
</ScrollViewer>
<!--关闭按钮-->
<Button Click="CloseShareList_Click" Style="{StaticResource CusIconBtn}" Canvas.Right="10" Canvas.Top="0" Background="Transparent" BorderThickness="0">
<Button.Content>
<StackPanel>
<TextBlock FontSize="30" Foreground="#fff" Margin="0 0 0 0">×</TextBlock>
</StackPanel>
</Button.Content>
</Button>
</Canvas>
</Border>
</Grid>
</Canvas>
</Metro:MetroWindow>