MainWindow.xaml 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. <Window x:Class="ReadVideoDemo.MainWindow"
  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:ReadVideoDemo"
  7. mc:Ignorable="d"
  8. Title="MainWindow" Height="450" Width="1200" Closing="OnWindowClosing">
  9. <Grid>
  10. <Grid.RowDefinitions>
  11. <RowDefinition Height="*"/>
  12. <RowDefinition Height="40"/>
  13. </Grid.RowDefinitions>
  14. <Grid.ColumnDefinitions>
  15. <ColumnDefinition Width="*"/>
  16. <ColumnDefinition Width="*"/>
  17. </Grid.ColumnDefinitions>
  18. <Grid Grid.Row="0" Grid.Column="0">
  19. <Image x:Name="TestImage1"/>
  20. </Grid>
  21. <Grid Grid.Row="0" Grid.Column="1">
  22. <Image x:Name="TestImage2"/>
  23. </Grid>
  24. <Grid Grid.Row="1" Grid.Column="0">
  25. <StackPanel Orientation="Horizontal">
  26. <Button Content="加载视频" FontSize="12" Margin="4,4,4,4" Width="100" Click="OnLoadVideo1Click"/>
  27. <Button Content="加载图片" FontSize="12" Margin="4,4,4,4" Width="100" Click="OnLoadImagesClick"/>
  28. <Button Content="解冻" FontSize="12" Margin="4,4,4,4" Width="100" Click="OnUnfreezeClick"/>
  29. <ProgressBar x:Name ="VideoProgressBar1" Width="120" Margin="4,8,4,8"/>
  30. <Button Content="停止" FontSize="12" Margin="4,4,4,4" Width="80" Click="OnStopReading1Click"/>
  31. <TextBlock x:Name="StatusText1" Width="80" Margin="4,4,4,4" VerticalAlignment="Center"/>
  32. </StackPanel>
  33. </Grid>
  34. <Grid Grid.Row="1" Grid.Column="1">
  35. <StackPanel Orientation="Horizontal">
  36. <Button Content="加载视频" FontSize="12" Margin="4,4,4,4" Width="100" Click="OnLoadVideo2Click"/>
  37. <ProgressBar x:Name ="VideoProgressBar2" Width="120" Margin="4,8,4,8"/>
  38. <Button Content="停止" FontSize="12" Margin="4,4,4,4" Width="80" Click="OnStopReading2Click"/>
  39. <TextBlock x:Name="StatusText2" Width="80" Margin="4,4,4,4" VerticalAlignment="Center"/>
  40. </StackPanel>
  41. </Grid>
  42. </Grid>
  43. </Window>