星火微课系统客户端
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

FileDirectoryWindow.xaml 9.7KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221
  1. <Window x:Class="XHWK.WKTool.FileDirectoryWindow"
  2. xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  3. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  4. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  5. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  6. xmlns:local="clr-namespace:XHWK.WKTool"
  7. mc:Ignorable="d"
  8. Title="FileDirectoryWindow" Height="729" Width="1030" AllowsTransparency="True"
  9. ShowInTaskbar="False"
  10. WindowStartupLocation="CenterOwner"
  11. WindowStyle="None">
  12. <Window.Resources>
  13. <!-- ListBox容器样式 -->
  14. <Style x:Key="ListBoxItemContainerStyle" TargetType="{x:Type ListBoxItem}">
  15. <Setter Property="HorizontalContentAlignment" Value="Stretch" />
  16. <Setter Property="HorizontalAlignment" Value="Stretch" />
  17. <Setter Property="Template">
  18. <Setter.Value>
  19. <ControlTemplate TargetType="{x:Type ListBoxItem}">
  20. <Border
  21. x:Name="itemBox"
  22. Background="Transparent"
  23. BorderBrush="Transparent"
  24. BorderThickness="0">
  25. <ContentPresenter />
  26. </Border>
  27. <ControlTemplate.Triggers />
  28. </ControlTemplate>
  29. </Setter.Value>
  30. </Setter>
  31. </Style>
  32. <DataTemplate x:Key="TongjiItem">
  33. <UniformGrid
  34. Height="36"
  35. Margin="0,0,0,0"
  36. Columns="6"
  37. Rows="1">
  38. <!--题号-->
  39. <TextBlock
  40. HorizontalAlignment="Center"
  41. VerticalAlignment="Center"
  42. FontSize="15"
  43. Text="{Binding SerialNumber}" />
  44. <Grid>
  45. <StackPanel Orientation="Horizontal">
  46. <TextBlock
  47. HorizontalAlignment="Center"
  48. VerticalAlignment="Center"
  49. FontSize="15"
  50. Text="{Binding VideoName}" />
  51. <Button Background="Transparent"
  52. Cursor="Hand"
  53. BorderThickness="0">
  54. <Grid>
  55. <Image Source="./Images/fileDirectory1.png"/>
  56. <Image Source="./Images/fileDirectory2.png" Visibility="Collapsed"/>
  57. </Grid>
  58. </Button>
  59. </StackPanel>
  60. </Grid>
  61. <!--分值-->
  62. <TextBlock
  63. HorizontalAlignment="Center"
  64. VerticalAlignment="Center"
  65. FontSize="15"
  66. Text="{Binding VideoDuration}" />
  67. <!--平均时长-->
  68. <TextBlock
  69. HorizontalAlignment="Center"
  70. VerticalAlignment="Center"
  71. FontSize="15"
  72. Text="{Binding VideoSize}" />
  73. <!--最短时长-->
  74. <TextBlock
  75. HorizontalAlignment="Center"
  76. VerticalAlignment="Center"
  77. FontSize="15"
  78. Text="{Binding VideoTime}" />
  79. <Grid>
  80. <StackPanel Orientation="Horizontal">
  81. <Button Cursor="Hand" Content="播放" FontSize="15"
  82. Background="Transparent"
  83. Foreground="#2D8CF0"
  84. BorderThickness="0"
  85. >
  86. </Button>
  87. <Button Cursor="Hand" Content="上传" FontSize="15"
  88. Background="Transparent"
  89. Foreground="#2D8CF0"
  90. BorderThickness="0"
  91. >
  92. </Button>
  93. <Button Cursor="Hand" Content="删除" FontSize="15"
  94. Background="Transparent"
  95. Foreground="#2D8CF0"
  96. BorderThickness="0"
  97. >
  98. </Button>
  99. </StackPanel>
  100. </Grid>
  101. </UniformGrid>
  102. </DataTemplate>
  103. </Window.Resources>
  104. <Viewbox>
  105. <Grid Height="729" Width="1030" >
  106. <!--分4行-->
  107. <Grid.RowDefinitions>
  108. <RowDefinition Height="45"/>
  109. <RowDefinition Height="*"/>
  110. <RowDefinition Height="80"/>
  111. </Grid.RowDefinitions>
  112. <!--第一行 标题-->
  113. <Border Grid.Row="0" Background="#2D8CF0">
  114. <Grid MouseLeftButtonDown="Window_MouseLeftButtonDown">
  115. <TextBlock Text="文件目录" Foreground="#FFFFFF" FontSize="16" Padding="10,13,0,0"/>
  116. <Button Cursor="Hand" Grid.Row="0" x:Name="btnDown" Content="×" Foreground="#FFFFFF" FontSize="25" Padding="10,0,10,0" HorizontalAlignment="Right" Style="{StaticResource {x:Static ToolBar.ButtonStyleKey}}" Click="btnDown_Click"/>
  117. </Grid>
  118. </Border>
  119. <!--第二行 内容-->
  120. <Grid Grid.Row="1" Margin="0,15,0,0">
  121. <Grid.RowDefinitions>
  122. <RowDefinition Height="45"/>
  123. <RowDefinition Height="*"/>
  124. </Grid.RowDefinitions>
  125. <UniformGrid x:Name="uniStatisticsByTitle"
  126. Grid.Row="0"
  127. Margin="10,0,10,0"
  128. Background="#2D8CF0"
  129. Columns="6"
  130. Rows="1">
  131. <TextBlock
  132. HorizontalAlignment="Center"
  133. VerticalAlignment="Center"
  134. FontSize="15"
  135. Text="序号" Foreground="White" />
  136. <TextBlock
  137. HorizontalAlignment="Center"
  138. VerticalAlignment="Center"
  139. FontSize="15"
  140. Text="视频名称" Foreground="White" />
  141. <TextBlock
  142. HorizontalAlignment="Center"
  143. VerticalAlignment="Center"
  144. FontSize="15"
  145. Text="视频时长" Foreground="White" />
  146. <TextBlock
  147. HorizontalAlignment="Center"
  148. VerticalAlignment="Center"
  149. FontSize="15"
  150. Text="视频大小" Foreground="White" />
  151. <TextBlock
  152. HorizontalAlignment="Center"
  153. VerticalAlignment="Center"
  154. FontSize="15"
  155. Text="日期" Foreground="White" />
  156. <TextBlock
  157. HorizontalAlignment="Center"
  158. VerticalAlignment="Center"
  159. FontSize="15"
  160. Text="操作" Foreground="White" />
  161. </UniformGrid>
  162. <ListBox Grid.Row="1"
  163. x:Name="listView1"
  164. BorderThickness="0"
  165. FontSize="20"
  166. ItemContainerStyle="{StaticResource ListBoxItemContainerStyle}"
  167. ItemTemplate="{StaticResource TongjiItem}"
  168. ItemsSource="{Binding menuList}" />
  169. </Grid>
  170. <!--第三行 删除 上传 按钮-->
  171. <StackPanel Grid.Row="3" Orientation="Horizontal" HorizontalAlignment="Center">
  172. <Button Cursor="Hand" x:Name="btnDelete" Content="删除" FontSize="18" Foreground="#FFFFFF" Style="{StaticResource {x:Static ToolBar.ButtonStyleKey}}" Width="115" Height="45" Margin="0,0,30,0">
  173. <Button.Template>
  174. <ControlTemplate TargetType="{x:Type Button}">
  175. <Border
  176. BorderBrush="{TemplateBinding Control.BorderBrush}"
  177. BorderThickness="1"
  178. CornerRadius="2">
  179. <Border.Background>#F0582B</Border.Background>
  180. <ContentPresenter
  181. HorizontalAlignment="Center"
  182. VerticalAlignment="Center"
  183. Content="{TemplateBinding ContentControl.Content}" />
  184. </Border>
  185. </ControlTemplate>
  186. </Button.Template>
  187. </Button>
  188. <Button Cursor="Hand" x:Name="btnUpload" Content="上传" FontSize="18" Foreground="#FFFFFF" Style="{StaticResource {x:Static ToolBar.ButtonStyleKey}}" Width="115" Height="45" Margin="30,0,0,0">
  189. <Button.Template>
  190. <ControlTemplate TargetType="{x:Type Button}">
  191. <Border
  192. BorderBrush="{TemplateBinding Control.BorderBrush}"
  193. BorderThickness="1"
  194. CornerRadius="2">
  195. <Border.Background>#2D8CF0</Border.Background>
  196. <ContentPresenter
  197. HorizontalAlignment="Center"
  198. VerticalAlignment="Center"
  199. Content="{TemplateBinding ContentControl.Content}" />
  200. </Border>
  201. </ControlTemplate>
  202. </Button.Template>
  203. </Button>
  204. </StackPanel>
  205. </Grid>
  206. </Viewbox>
  207. </Window>