星火微课系统客户端
Nelze vybrat více než 25 témat Téma musí začínat písmenem nebo číslem, může obsahovat pomlčky („-“) a může být dlouhé až 35 znaků.

FileDirectoryWindow.xaml 8.4KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186
  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="9"
  37. Rows="1">
  38. <!--题号-->
  39. <TextBlock
  40. HorizontalAlignment="Center"
  41. VerticalAlignment="Center"
  42. FontSize="15"
  43. Text="{Binding SerialNumber}" />
  44. <!--题型-->
  45. <TextBlock
  46. HorizontalAlignment="Center"
  47. VerticalAlignment="Center"
  48. FontSize="15"
  49. Text="{Binding VideoName}" />
  50. <!--分值-->
  51. <TextBlock
  52. HorizontalAlignment="Center"
  53. VerticalAlignment="Center"
  54. FontSize="15"
  55. Text="{Binding VideoDuration}" />
  56. <!--平均时长-->
  57. <TextBlock
  58. HorizontalAlignment="Center"
  59. VerticalAlignment="Center"
  60. FontSize="15"
  61. Text="{Binding VideoSize}" />
  62. <!--最短时长-->
  63. <TextBlock
  64. HorizontalAlignment="Center"
  65. VerticalAlignment="Center"
  66. FontSize="15"
  67. Text="{Binding VideoTime}" />
  68. <Grid>
  69. <Button Cursor="Hand" Content="详情" FontSize="15"
  70. Background="Transparent"
  71. Foreground="#2D8CF0"
  72. BorderThickness="0"
  73. >
  74. </Button>
  75. </Grid>
  76. </UniformGrid>
  77. </DataTemplate>
  78. </Window.Resources>
  79. <Viewbox>
  80. <Grid Height="729" Width="1030" >
  81. <!--分4行-->
  82. <Grid.RowDefinitions>
  83. <RowDefinition Height="45"/>
  84. <RowDefinition Height="*"/>
  85. <RowDefinition Height="80"/>
  86. </Grid.RowDefinitions>
  87. <!--第一行 标题-->
  88. <Border Grid.Row="0" Background="#2D8CF0">
  89. <Grid MouseLeftButtonDown="Window_MouseLeftButtonDown">
  90. <TextBlock Text="文件目录" Foreground="#FFFFFF" FontSize="16" Padding="10,13,0,0"/>
  91. <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"/>
  92. </Grid>
  93. </Border>
  94. <!--第二行 内容-->
  95. <Grid Grid.Row="1" Margin="0,15,0,0">
  96. <Grid.RowDefinitions>
  97. <RowDefinition Height="45"/>
  98. <RowDefinition Height="*"/>
  99. </Grid.RowDefinitions>
  100. <UniformGrid x:Name="uniStatisticsByTitle"
  101. Grid.Row="0"
  102. Margin="10,0,10,0"
  103. Background="#2D8CF0"
  104. Columns="6"
  105. Rows="1">
  106. <TextBlock
  107. HorizontalAlignment="Center"
  108. VerticalAlignment="Center"
  109. FontSize="15"
  110. Text="序号" Foreground="White" />
  111. <TextBlock
  112. HorizontalAlignment="Center"
  113. VerticalAlignment="Center"
  114. FontSize="15"
  115. Text="视频名称" Foreground="White" />
  116. <TextBlock
  117. HorizontalAlignment="Center"
  118. VerticalAlignment="Center"
  119. FontSize="15"
  120. Text="视频时长" Foreground="White" />
  121. <TextBlock
  122. HorizontalAlignment="Center"
  123. VerticalAlignment="Center"
  124. FontSize="15"
  125. Text="视频大小" Foreground="White" />
  126. <TextBlock
  127. HorizontalAlignment="Center"
  128. VerticalAlignment="Center"
  129. FontSize="15"
  130. Text="日期" Foreground="White" />
  131. <TextBlock
  132. HorizontalAlignment="Center"
  133. VerticalAlignment="Center"
  134. FontSize="15"
  135. Text="操作" Foreground="White" />
  136. </UniformGrid>
  137. <ListBox Grid.Row="1"
  138. x:Name="listView1"
  139. BorderThickness="0"
  140. FontSize="20"
  141. ItemContainerStyle="{StaticResource ListBoxItemContainerStyle}"
  142. ItemTemplate="{StaticResource TongjiItem}"
  143. ItemsSource="{Binding menuList}" />
  144. </Grid>
  145. <!--第三行 删除 上传 按钮-->
  146. <StackPanel Grid.Row="3" Orientation="Horizontal" HorizontalAlignment="Center">
  147. <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">
  148. <Button.Template>
  149. <ControlTemplate TargetType="{x:Type Button}">
  150. <Border
  151. BorderBrush="{TemplateBinding Control.BorderBrush}"
  152. BorderThickness="1"
  153. CornerRadius="2">
  154. <Border.Background>#F0582B</Border.Background>
  155. <ContentPresenter
  156. HorizontalAlignment="Center"
  157. VerticalAlignment="Center"
  158. Content="{TemplateBinding ContentControl.Content}" />
  159. </Border>
  160. </ControlTemplate>
  161. </Button.Template>
  162. </Button>
  163. <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">
  164. <Button.Template>
  165. <ControlTemplate TargetType="{x:Type Button}">
  166. <Border
  167. BorderBrush="{TemplateBinding Control.BorderBrush}"
  168. BorderThickness="1"
  169. CornerRadius="2">
  170. <Border.Background>#2D8CF0</Border.Background>
  171. <ContentPresenter
  172. HorizontalAlignment="Center"
  173. VerticalAlignment="Center"
  174. Content="{TemplateBinding ContentControl.Content}" />
  175. </Border>
  176. </ControlTemplate>
  177. </Button.Template>
  178. </Button>
  179. </StackPanel>
  180. </Grid>
  181. </Viewbox>
  182. </Window>