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

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