星火微课系统客户端
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.

DeviceWindow.xaml 31KB

3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
3 jaren geleden
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687
  1. <Window
  2. x:Class="XHWK.WKTool.DeviceWindow"
  3. xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  4. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  5. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  6. xmlns:gif="http://wpfanimatedgif.codeplex.com"
  7. xmlns:local="clr-namespace:XHWK.WKTool"
  8. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  9. xmlns:view="clr-namespace:XHWK.WKTool.View"
  10. Title="设备检测"
  11. Width="569"
  12. Height="367"
  13. AllowsTransparency="True"
  14. BorderBrush="#FFE9E9E9"
  15. BorderThickness="1"
  16. ShowInTaskbar="True"
  17. WindowStartupLocation="CenterScreen"
  18. WindowStyle="None"
  19. mc:Ignorable="d">
  20. <Window.Resources>
  21. <!-- 摄像头样式 -->
  22. <Style x:Key="stlToggleButton" TargetType="ToggleButton">
  23. <Setter Property="Foreground" Value="White" />
  24. <Setter Property="Template">
  25. <Setter.Value>
  26. <ControlTemplate>
  27. <Border
  28. x:Name="Back"
  29. Background="#FFFFFFFF"
  30. BorderBrush="Transparent"
  31. BorderThickness="0">
  32. <Path
  33. Name="PathFill"
  34. Width="8"
  35. Height="6"
  36. Data="M5,0 L10,10 L0,10 z"
  37. Fill="Black"
  38. RenderTransformOrigin="0.5,0.5"
  39. Stretch="Fill"
  40. StrokeThickness="0">
  41. <Path.RenderTransform>
  42. <TransformGroup>
  43. <ScaleTransform />
  44. <SkewTransform />
  45. <RotateTransform Angle="180" />
  46. <TranslateTransform />
  47. </TransformGroup>
  48. </Path.RenderTransform>
  49. </Path>
  50. </Border>
  51. <ControlTemplate.Triggers>
  52. <Trigger Property="IsMouseOver" Value="True">
  53. <Setter TargetName="PathFill" Property="Fill" Value="White" />
  54. <Setter TargetName="Back" Property="Background" Value="#FFDCDCDC" />
  55. <Setter TargetName="Back" Property="BorderBrush" Value="#FFDCDCDC" />
  56. </Trigger>
  57. </ControlTemplate.Triggers>
  58. </ControlTemplate>
  59. </Setter.Value>
  60. </Setter>
  61. </Style>
  62. <Style x:Key="stlComboBox" TargetType="ComboBox">
  63. <Setter Property="SnapsToDevicePixels" Value="True" />
  64. <Setter Property="ScrollViewer.HorizontalScrollBarVisibility" Value="Auto" />
  65. <Setter Property="ScrollViewer.VerticalScrollBarVisibility" Value="Auto" />
  66. <Setter Property="ScrollViewer.CanContentScroll" Value="True" />
  67. <Setter Property="HorizontalAlignment" Value="Left" />
  68. <Setter Property="Foreground" Value="Black" />
  69. <Setter Property="Height" Value="30" />
  70. <Setter Property="Margin" Value="0,0,0,0" />
  71. <Setter Property="Template">
  72. <Setter.Value>
  73. <ControlTemplate TargetType="ComboBox">
  74. <Grid Background="#F7FDF7">
  75. <Grid.ColumnDefinitions>
  76. <ColumnDefinition Width="0.8*" />
  77. <ColumnDefinition Width="0.2*" MaxWidth="20" />
  78. </Grid.ColumnDefinitions>
  79. <TextBox
  80. Grid.Column="0"
  81. VerticalContentAlignment="Center"
  82. IsReadOnly="True"
  83. Text="{TemplateBinding Text}" />
  84. <Border
  85. Grid.Column="0"
  86. BorderBrush="#FFDCDCDC"
  87. BorderThickness="1,1,1,1"
  88. CornerRadius="1,0,0,1" />
  89. <Border
  90. Grid.Column="1"
  91. BorderBrush="#FFDCDCDC"
  92. BorderThickness="0,1,1,1"
  93. CornerRadius="0,1,1,0">
  94. <ToggleButton
  95. ClickMode="Press"
  96. IsChecked="{Binding Path=IsDropDownOpen, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}"
  97. Style="{StaticResource stlToggleButton}" />
  98. </Border>
  99. <Popup
  100. x:Name="Popup"
  101. AllowsTransparency="True"
  102. Focusable="False"
  103. IsOpen="{TemplateBinding IsDropDownOpen}"
  104. Placement="Bottom"
  105. PopupAnimation="Slide">
  106. <Border
  107. x:Name="DropDown"
  108. MinWidth="{TemplateBinding ActualWidth}"
  109. MaxHeight="{TemplateBinding MaxDropDownHeight}"
  110. CornerRadius="1"
  111. SnapsToDevicePixels="True">
  112. <Border.Effect>
  113. <DropShadowEffect
  114. BlurRadius="2"
  115. Opacity="0.5"
  116. ShadowDepth="0"
  117. Color="Black" />
  118. </Border.Effect>
  119. <ScrollViewer
  120. MaxHeight="{TemplateBinding MaxDropDownHeight}"
  121. Margin="4,6,4,6"
  122. CanContentScroll="True"
  123. HorizontalScrollBarVisibility="Auto"
  124. SnapsToDevicePixels="True"
  125. Style="{DynamicResource ScrollViewerStyle}"
  126. VerticalScrollBarVisibility="Auto">
  127. <!-- StackPanel 用于显示子级,方法是将 IsItemsHost 设置为 True -->
  128. <StackPanel
  129. Background="White"
  130. IsItemsHost="True"
  131. KeyboardNavigation.DirectionalNavigation="Contained" />
  132. </ScrollViewer>
  133. </Border>
  134. </Popup>
  135. </Grid>
  136. </ControlTemplate>
  137. </Setter.Value>
  138. </Setter>
  139. </Style>
  140. </Window.Resources>
  141. <Grid>
  142. <Grid.RowDefinitions>
  143. <RowDefinition Height="42" />
  144. <RowDefinition Height="*" />
  145. </Grid.RowDefinitions>
  146. <Grid
  147. x:Name="GridTitle_Black"
  148. Grid.Row="0"
  149. Margin="0,0"
  150. Background="#3f6fff"
  151. MouseLeftButtonDown="Window_MouseLeftButtonDown">
  152. <TextBlock
  153. Grid.RowSpan="2"
  154. Padding="10,13,0,0"
  155. FontSize="16"
  156. Foreground="White"
  157. Text="设备检测" />
  158. <Button
  159. x:Name="btnDown_Black"
  160. Grid.Row="0"
  161. Width="46"
  162. HorizontalAlignment="Right"
  163. Click="BtnDown_Click"
  164. Content="×"
  165. Cursor="Hand"
  166. FontSize="30"
  167. Foreground="White" />
  168. </Grid>
  169. <Grid Grid.Row="1">
  170. <Grid.ColumnDefinitions>
  171. <ColumnDefinition Width="140" />
  172. <ColumnDefinition Width="*" />
  173. </Grid.ColumnDefinitions>
  174. <Grid Grid.Column="0">
  175. <Border BorderBrush="#FFE9E9E9" BorderThickness="0,0,1,0">
  176. <StackPanel Margin="0,10" VerticalAlignment="Top">
  177. <Button
  178. x:Name="BtnCamera"
  179. Height="40"
  180. Margin="0,0,0,0"
  181. HorizontalAlignment="Stretch"
  182. VerticalAlignment="Stretch"
  183. IsEnabled="False"
  184. Style="{StaticResource {x:Static ToolBar.ButtonStyleKey}}">
  185. <StackPanel Orientation="Horizontal">
  186. <Image
  187. Height="18"
  188. Margin="6,0"
  189. HorizontalAlignment="Left"
  190. Source="/BlackImages/Device_Camera.png" />
  191. <TextBlock
  192. Width="100"
  193. Padding="0,0,0,0"
  194. HorizontalAlignment="Center"
  195. FontSize="16"
  196. Text="摄像头" />
  197. </StackPanel>
  198. </Button>
  199. <Button
  200. x:Name="BtnSpeaker"
  201. Height="40"
  202. Margin="0,0,0,0"
  203. HorizontalAlignment="Stretch"
  204. VerticalAlignment="Stretch"
  205. IsEnabled="False"
  206. Style="{StaticResource {x:Static ToolBar.ButtonStyleKey}}">
  207. <StackPanel Orientation="Horizontal">
  208. <Image
  209. Height="18"
  210. Margin="6,0"
  211. HorizontalAlignment="Left"
  212. Source="/BlackImages/Device_Voice.png" />
  213. <TextBlock
  214. Width="100"
  215. Padding="0,0,0,0"
  216. HorizontalAlignment="Center"
  217. FontSize="16"
  218. Text="扬声器" />
  219. </StackPanel>
  220. </Button>
  221. <Button
  222. x:Name="BtnMicrophone"
  223. Height="40"
  224. Margin="0,0,0,0"
  225. HorizontalAlignment="Stretch"
  226. VerticalAlignment="Stretch"
  227. Cursor="Hand"
  228. IsEnabled="False"
  229. Style="{StaticResource {x:Static ToolBar.ButtonStyleKey}}">
  230. <StackPanel Orientation="Horizontal">
  231. <Image
  232. Height="18"
  233. Margin="6,0"
  234. HorizontalAlignment="Left"
  235. Source="/BlackImages/Device_Microphone.png" />
  236. <TextBlock
  237. Width="100"
  238. Padding="0,0,0,0"
  239. HorizontalAlignment="Center"
  240. FontSize="16"
  241. Text="麦克风" />
  242. </StackPanel>
  243. </Button>
  244. <Button
  245. x:Name="BtnDetectionPage"
  246. Height="40"
  247. Margin="0,0,0,0"
  248. HorizontalAlignment="Stretch"
  249. VerticalAlignment="Stretch"
  250. IsEnabled="False"
  251. Style="{StaticResource {x:Static ToolBar.ButtonStyleKey}}">
  252. <StackPanel Orientation="Horizontal">
  253. <Image
  254. Height="18"
  255. Margin="6,0"
  256. HorizontalAlignment="Left"
  257. Source="/BlackImages/Device_JC.png" />
  258. <TextBlock
  259. Width="100"
  260. Padding="0,0,0,0"
  261. HorizontalAlignment="Center"
  262. FontSize="16"
  263. Text="检测结果" />
  264. </StackPanel>
  265. </Button>
  266. </StackPanel>
  267. </Border>
  268. </Grid>
  269. <Grid
  270. x:Name="GridCamera"
  271. Grid.Column="1"
  272. Visibility="Visible">
  273. <Grid.RowDefinitions>
  274. <RowDefinition Height="64" />
  275. <RowDefinition Height="*" />
  276. <RowDefinition Height="64" />
  277. </Grid.RowDefinitions>
  278. <StackPanel
  279. Grid.Row="0"
  280. Margin="30,0,0,0"
  281. Orientation="Horizontal">
  282. <TextBlock
  283. Margin="0,5,0,0"
  284. HorizontalAlignment="Left"
  285. VerticalAlignment="Center"
  286. FontSize="16"
  287. Foreground="#FF000000"
  288. Text="摄像头" />
  289. <ComboBox
  290. x:Name="CmbCameraList"
  291. Width="236"
  292. Margin="16,0,0,0"
  293. Padding="30,0,0,0"
  294. HorizontalAlignment="Left"
  295. VerticalAlignment="Center"
  296. HorizontalContentAlignment="Center"
  297. VerticalContentAlignment="Center"
  298. Background="White"
  299. BorderThickness="0"
  300. Cursor="Hand"
  301. DisplayMemberPath="Name"
  302. FontSize="14"
  303. SelectionChanged="CmbCameraList_SelectionChanged"
  304. Style="{StaticResource stlComboBox}"
  305. Text="请选择" />
  306. </StackPanel>
  307. <Grid
  308. Grid.Row="1"
  309. Width="300"
  310. Height="160"
  311. Margin="30,0,0,0"
  312. HorizontalAlignment="Left"
  313. VerticalAlignment="Top">
  314. <Image
  315. x:Name="imgPlayer"
  316. RenderTransformOrigin="0.5,0.5"
  317. Stretch="Fill"
  318. Visibility="Visible">
  319. <Image.RenderTransform>
  320. <ScaleTransform ScaleX="-1" />
  321. </Image.RenderTransform>
  322. </Image>
  323. </Grid>
  324. <StackPanel
  325. Grid.Row="2"
  326. Margin="30,0,0,0"
  327. HorizontalAlignment="Right"
  328. Orientation="Horizontal">
  329. <Button
  330. x:Name="btn_camera_good"
  331. Width="100"
  332. Height="30"
  333. Margin="0,0,10,0"
  334. HorizontalAlignment="Right"
  335. VerticalAlignment="Center"
  336. Background="#3f6fff"
  337. Click="btn_camera_good_Click"
  338. Content="可以看见"
  339. Cursor="Hand"
  340. FontSize="15"
  341. Foreground="White"
  342. IsDefault="True" />
  343. <Button
  344. x:Name="btn_camera_bad"
  345. Width="100"
  346. Height="30"
  347. Margin="0,0,10,0"
  348. HorizontalAlignment="Right"
  349. VerticalAlignment="Center"
  350. Background="#F1F2F3"
  351. Click="btn_camera_bad_Click"
  352. Content="看不见"
  353. Cursor="Hand"
  354. FontSize="15"
  355. Foreground="#333333"
  356. IsDefault="True" />
  357. </StackPanel>
  358. </Grid>
  359. <Grid
  360. x:Name="GridSpeaker"
  361. Grid.Column="1"
  362. Visibility="Collapsed">
  363. <Grid.RowDefinitions>
  364. <RowDefinition Height="64" />
  365. <RowDefinition Height="*" />
  366. <RowDefinition Height="64" />
  367. </Grid.RowDefinitions>
  368. <Grid Grid.Row="0">
  369. <StackPanel
  370. Margin="30,20,0,0"
  371. HorizontalAlignment="Left"
  372. VerticalAlignment="Top"
  373. Orientation="Horizontal">
  374. <Button
  375. x:Name="BtnSpeakerDetection"
  376. Grid.Row="2"
  377. Width="100"
  378. Height="30"
  379. Margin="0"
  380. HorizontalAlignment="Stretch"
  381. VerticalAlignment="Stretch"
  382. Click="BtnSpeakerDetection_Click"
  383. Content="播放音频"
  384. Cursor="Hand"
  385. FontSize="15"
  386. Foreground="White"
  387. IsDefault="True"
  388. Style="{StaticResource {x:Static ToolBar.ButtonStyleKey}}">
  389. <Button.Template>
  390. <ControlTemplate TargetType="{x:Type Button}">
  391. <Border
  392. BorderBrush="{TemplateBinding BorderBrush}"
  393. BorderThickness="1"
  394. CornerRadius="7">
  395. <Border.Background>
  396. <Brush>#3f6fff</Brush>
  397. </Border.Background>
  398. <ContentPresenter
  399. HorizontalAlignment="Center"
  400. VerticalAlignment="Center"
  401. Content="{TemplateBinding Content}" />
  402. </Border>
  403. </ControlTemplate>
  404. </Button.Template>
  405. </Button>
  406. <MediaElement
  407. x:Name="MediaAudio"
  408. Width="0"
  409. LoadedBehavior="Manual"
  410. MediaEnded="MediaAudio_MediaEnded"
  411. MediaOpened="MediaAudio_MediaOpened"
  412. Stretch="Fill"
  413. Visibility="Hidden"
  414. Volume="1" />
  415. </StackPanel>
  416. </Grid>
  417. <Grid Grid.Row="1">
  418. <Grid
  419. Width="300"
  420. Height="100"
  421. Margin="30,0,0,0"
  422. HorizontalAlignment="Left"
  423. VerticalAlignment="Top"
  424. Background="#FFF1F2F8">
  425. <Image
  426. x:Name="ImgAcousticWave"
  427. HorizontalAlignment="Center"
  428. VerticalAlignment="Center"
  429. gif:ImageBehavior.AnimatedSource="/SkinImages/Other/Dev_AcousticWave2.gif"
  430. gif:ImageBehavior.AutoStart="True"
  431. gif:ImageBehavior.RepeatBehavior="Forever"
  432. Visibility="Hidden" />
  433. </Grid>
  434. </Grid>
  435. <Grid Grid.Row="2">
  436. <StackPanel
  437. Grid.Row="2"
  438. Margin="30,0,0,0"
  439. HorizontalAlignment="Right"
  440. Orientation="Horizontal">
  441. <Button
  442. x:Name="btn_speaker_good"
  443. Width="100"
  444. Height="30"
  445. Margin="0,0,10,0"
  446. HorizontalAlignment="Right"
  447. VerticalAlignment="Center"
  448. Background="#3f6fff"
  449. Click="btn_speaker_good_Click"
  450. Content="可以听见"
  451. Cursor="Hand"
  452. FontSize="15"
  453. Foreground="White"
  454. IsDefault="True" />
  455. <Button
  456. x:Name="btn_speaker_bad"
  457. Width="100"
  458. Height="30"
  459. Margin="0,0,10,0"
  460. HorizontalAlignment="Right"
  461. VerticalAlignment="Center"
  462. Background="#F1F2F3"
  463. Click="btn_speaker_bad_Click"
  464. Content="听不见"
  465. Cursor="Hand"
  466. FontSize="15"
  467. Foreground="#333333"
  468. IsDefault="True" />
  469. </StackPanel>
  470. </Grid>
  471. </Grid>
  472. <Grid
  473. x:Name="GridMicrophone"
  474. Grid.Column="1"
  475. Visibility="Collapsed">
  476. <Grid.RowDefinitions>
  477. <RowDefinition Height="64" />
  478. <RowDefinition Height="*" />
  479. <RowDefinition Height="64" />
  480. </Grid.RowDefinitions>
  481. <StackPanel
  482. Grid.Row="0"
  483. Margin="30,0,0,0"
  484. HorizontalAlignment="Left"
  485. VerticalAlignment="Center"
  486. Orientation="Horizontal">
  487. <TextBlock
  488. Margin="0,5,0,0"
  489. HorizontalAlignment="Left"
  490. VerticalAlignment="Top"
  491. FontSize="16"
  492. Foreground="#FF000000"
  493. Text="麦克风" />
  494. <ComboBox
  495. x:Name="CmbMicrophoneList"
  496. Width="236"
  497. Margin="16,0,0,0"
  498. Padding="30,0,0,0"
  499. HorizontalAlignment="Left"
  500. VerticalAlignment="Top"
  501. HorizontalContentAlignment="Center"
  502. VerticalContentAlignment="Center"
  503. Background="White"
  504. BorderThickness="0"
  505. Cursor="Hand"
  506. DisplayMemberPath="Value"
  507. FontSize="14"
  508. SelectedValuePath="Key"
  509. SelectionChanged="CmbMicrophoneList_SelectionChanged"
  510. Style="{StaticResource stlComboBox}"
  511. Text="请选择" />
  512. </StackPanel>
  513. <Grid Grid.Row="1">
  514. <Grid.RowDefinitions>
  515. <RowDefinition Height="Auto" />
  516. <RowDefinition Height="64" />
  517. </Grid.RowDefinitions>
  518. <view:ZClippingBorder
  519. x:Name="GridMicImg"
  520. Width="300"
  521. Height="20"
  522. Margin="30,0,0,0"
  523. HorizontalAlignment="Left"
  524. VerticalAlignment="Top"
  525. Background="#FFF1F2F8"
  526. ClipToBounds="True"
  527. CornerRadius="10"
  528. Visibility="Visible">
  529. <ProgressBar
  530. x:Name="volumeProgressBar"
  531. BorderThickness="0"
  532. Maximum="100" />
  533. </view:ZClippingBorder>
  534. </Grid>
  535. <Grid Grid.Row="2">
  536. <StackPanel
  537. Grid.Row="2"
  538. Margin="30,0,0,0"
  539. HorizontalAlignment="Right"
  540. Orientation="Horizontal">
  541. <Button
  542. x:Name="btn_microphone_good"
  543. Width="100"
  544. Height="30"
  545. Margin="0,0,10,0"
  546. HorizontalAlignment="Right"
  547. VerticalAlignment="Center"
  548. Background="#3f6fff"
  549. Click="btn_microphone_good_Click"
  550. Content="可以看见"
  551. Cursor="Hand"
  552. FontSize="15"
  553. Foreground="White"
  554. IsDefault="True" />
  555. <Button
  556. x:Name="btn_microphone_bad"
  557. Width="100"
  558. Height="30"
  559. Margin="0,0,10,0"
  560. HorizontalAlignment="Right"
  561. VerticalAlignment="Center"
  562. Background="#F1F2F3"
  563. Click="btn_microphone_bad_Click"
  564. Content="看不见"
  565. Cursor="Hand"
  566. FontSize="15"
  567. Foreground="#333333"
  568. IsDefault="True" />
  569. </StackPanel>
  570. </Grid>
  571. </Grid>
  572. <Grid
  573. x:Name="GridDetection"
  574. Grid.Column="1"
  575. Margin="25,15"
  576. Visibility="Collapsed">
  577. <Grid.ColumnDefinitions>
  578. <ColumnDefinition Width="50*" />
  579. <ColumnDefinition Width="50*" />
  580. </Grid.ColumnDefinitions>
  581. <Grid.RowDefinitions>
  582. <RowDefinition Height="50*" />
  583. <RowDefinition Height="50*" />
  584. <RowDefinition Height="50*" />
  585. <RowDefinition Height="50*" />
  586. <RowDefinition Height="50*" />
  587. <RowDefinition Height="50*" />
  588. <RowDefinition Height="50*" />
  589. </Grid.RowDefinitions>
  590. <Grid Grid.Row="0" Grid.Column="0">
  591. <TextBlock
  592. HorizontalAlignment="Center"
  593. VerticalAlignment="Center"
  594. FontSize="16"
  595. Foreground="#FF999999"
  596. Text="设备名称" />
  597. </Grid>
  598. <Grid Grid.Row="0" Grid.Column="1">
  599. <TextBlock
  600. HorizontalAlignment="Center"
  601. VerticalAlignment="Center"
  602. FontSize="16"
  603. Foreground="#FF999999"
  604. Text="检测结果" />
  605. </Grid>
  606. <!-- 摄像头 -->
  607. <Grid Grid.Row="1" Grid.Column="0">
  608. <TextBlock
  609. HorizontalAlignment="Center"
  610. VerticalAlignment="Center"
  611. FontSize="16"
  612. Foreground="#FF000000"
  613. Text="摄像头" />
  614. </Grid>
  615. <Grid Grid.Row="1" Grid.Column="1">
  616. <TextBlock
  617. x:Name="TxbCamera"
  618. HorizontalAlignment="Center"
  619. VerticalAlignment="Center"
  620. FontSize="16"
  621. Foreground="#FF000000"
  622. Text="" />
  623. </Grid>
  624. <!-- 扬声器 -->
  625. <Grid Grid.Row="2" Grid.Column="0">
  626. <TextBlock
  627. HorizontalAlignment="Center"
  628. VerticalAlignment="Center"
  629. FontSize="16"
  630. Foreground="#FF000000"
  631. Text="扬声器" />
  632. </Grid>
  633. <Grid Grid.Row="2" Grid.Column="1">
  634. <TextBlock
  635. x:Name="TxbSpeaker"
  636. HorizontalAlignment="Center"
  637. VerticalAlignment="Center"
  638. FontSize="16"
  639. Foreground="#FF000000"
  640. Text="" />
  641. </Grid>
  642. <!-- 麦克风 -->
  643. <Grid Grid.Row="3" Grid.Column="0">
  644. <TextBlock
  645. HorizontalAlignment="Center"
  646. VerticalAlignment="Center"
  647. FontSize="16"
  648. Foreground="#FF000000"
  649. Text="麦克风" />
  650. </Grid>
  651. <Grid Grid.Row="3" Grid.Column="1">
  652. <TextBlock
  653. x:Name="TxbMicrophone"
  654. HorizontalAlignment="Center"
  655. VerticalAlignment="Center"
  656. FontSize="16"
  657. Foreground="#FF000000"
  658. Text="" />
  659. </Grid>
  660. <Grid Grid.Row="6" Grid.Column="1">
  661. <Button
  662. x:Name="BtnDetection"
  663. Grid.Row="2"
  664. Width="116"
  665. Height="30"
  666. Margin="0"
  667. HorizontalAlignment="Right"
  668. VerticalAlignment="Stretch"
  669. Background="#3f6fff"
  670. Click="BtnDetection_Click"
  671. Content="重新检测"
  672. Cursor="Hand"
  673. FontSize="14"
  674. Foreground="White"
  675. IsDefault="True" />
  676. </Grid>
  677. </Grid>
  678. </Grid>
  679. </Grid>
  680. </Window>