VibrationControl.xaml 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276
  1. <UserControl x:Class="TeamAAS_VP.Controls.VibrationControl"
  2. xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  3. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  4. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  5. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  6. xmlns:local="clr-namespace:TeamAAS_VP.Controls"
  7. xmlns:icon="http://metro.mahapps.com/winfx/xaml/iconpacks"
  8. xmlns:mah="http://metro.mahapps.com/winfx/xaml/controls"
  9. xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
  10. xmlns:b="http://schemas.microsoft.com/xaml/behaviors"
  11. xmlns:sys="clr-namespace:System;assembly=mscorlib"
  12. xmlns:lex="http://wpflocalizeextension.codeplex.com"
  13. lex:LocalizeDictionary.DesignCulture="zh-CN"
  14. lex:ResxLocalizationProvider.DefaultAssembly="TeamAAS-VP"
  15. lex:ResxLocalizationProvider.DefaultDictionary="Lang"
  16. mc:Ignorable="d"
  17. d:Background="White"
  18. FontFamily="{DynamicResource DefaultFont}">
  19. <UserControl.Resources>
  20. <Style TargetType="Button"
  21. BasedOn="{StaticResource MaterialDesignIconForegroundButton}">
  22. <Setter Property="Background"
  23. Value="Transparent" />
  24. <Setter Property="BorderBrush"
  25. Value="Transparent" />
  26. <Setter Property="HorizontalAlignment"
  27. Value="Center" />
  28. <Setter Property="VerticalAlignment"
  29. Value="Center" />
  30. <Setter Property="Width"
  31. Value="48" />
  32. <Setter Property="Height"
  33. Value="48" />
  34. </Style>
  35. <Style TargetType="TextBlock">
  36. <Setter Property="Margin"
  37. Value="0,30,0,0" />
  38. <Setter Property="FontSize"
  39. Value="16" />
  40. <Setter Property="Foreground"
  41. Value="#ff0078d7" />
  42. </Style>
  43. <Style TargetType="materialDesign:PackIcon">
  44. <Setter Property="FontSize"
  45. Value="30" />
  46. <Setter Property="Width"
  47. Value="50" />
  48. <Setter Property="Height"
  49. Value="50" />
  50. </Style>
  51. </UserControl.Resources>
  52. <Viewbox Stretch="Uniform">
  53. <Grid Width="400" Height="250">
  54. <Grid.Background>
  55. <ImageBrush ImageSource="pack://application:,,,/TeamAAS-VP;component/Resources/Images/FFFEEDER.png"
  56. Stretch="Fill" />
  57. </Grid.Background>
  58. <Grid Margin="43,18,107,20">
  59. <Grid.ColumnDefinitions>
  60. <ColumnDefinition Width="*" />
  61. <ColumnDefinition Width="*" />
  62. <ColumnDefinition Width="*" />
  63. </Grid.ColumnDefinitions>
  64. <Grid.RowDefinitions>
  65. <RowDefinition />
  66. <RowDefinition />
  67. <RowDefinition />
  68. </Grid.RowDefinitions>
  69. <Button Grid.Row="0"
  70. Grid.Column="0"
  71. HorizontalAlignment="Center"
  72. VerticalAlignment="Center"
  73. Width="50"
  74. Height="50"
  75. Command="{Binding ActionCommand}"
  76. CommandParameter="6">
  77. <Grid>
  78. <materialDesign:PackIcon HorizontalAlignment="Center"
  79. VerticalAlignment="Center"
  80. Kind="ArrowBottomRightThick" />
  81. <TextBlock HorizontalAlignment="Right"
  82. VerticalAlignment="Bottom"
  83. Text="G" />
  84. </Grid>
  85. </Button>
  86. <Button Grid.Row="0"
  87. Grid.Column="1"
  88. Command="{Binding ActionCommand}"
  89. CommandParameter="3">
  90. <Grid>
  91. <materialDesign:PackIcon Margin="1"
  92. HorizontalAlignment="Center"
  93. VerticalAlignment="Center"
  94. Kind="ArrowDownBold" />
  95. <TextBlock HorizontalAlignment="Right"
  96. VerticalAlignment="Bottom"
  97. Text="D" />
  98. </Grid>
  99. </Button>
  100. <Button Grid.Row="1"
  101. Grid.Column="1"
  102. Command="{Binding ActionCommand}"
  103. CommandParameter="8">
  104. <Grid>
  105. <materialDesign:PackIcon Margin="1"
  106. HorizontalAlignment="Center"
  107. VerticalAlignment="Center"
  108. Kind="ArrowExpandAll" />
  109. <TextBlock HorizontalAlignment="Right"
  110. VerticalAlignment="Bottom"
  111. Text="I" />
  112. </Grid>
  113. </Button>
  114. <Button Grid.Row="2"
  115. Grid.Column="1"
  116. Command="{Binding ActionCommand}"
  117. CommandParameter="4">
  118. <Grid>
  119. <materialDesign:PackIcon Margin="1"
  120. HorizontalAlignment="Center"
  121. VerticalAlignment="Center"
  122. Kind="ArrowUpBold" />
  123. <TextBlock HorizontalAlignment="Right"
  124. VerticalAlignment="Bottom"
  125. Text="E" />
  126. </Grid>
  127. <!--<icon:PackIconMaterial
  128. Width="{Binding IconWidth}"
  129. Height="{Binding IconHeight}"
  130. Kind="ArrowUp" />-->
  131. </Button>
  132. <Button Grid.Row="1"
  133. Grid.Column="0"
  134. Command="{Binding ActionCommand}"
  135. CommandParameter="5">
  136. <Grid>
  137. <materialDesign:PackIcon Margin="1"
  138. HorizontalAlignment="Center"
  139. VerticalAlignment="Center"
  140. Kind="ArrowRightBold" />
  141. <TextBlock HorizontalAlignment="Right"
  142. VerticalAlignment="Bottom"
  143. Text="F" />
  144. </Grid>
  145. </Button>
  146. <Button Grid.Row="2"
  147. Grid.Column="0"
  148. Command="{Binding ActionCommand}"
  149. CommandParameter="7">
  150. <Grid>
  151. <materialDesign:PackIcon Margin="1"
  152. HorizontalAlignment="Center"
  153. VerticalAlignment="Center"
  154. Kind="ArrowTopRightThick" />
  155. <TextBlock HorizontalAlignment="Right"
  156. VerticalAlignment="Bottom"
  157. Text="H" />
  158. </Grid>
  159. </Button>
  160. <Button Grid.Row="0"
  161. Grid.Column="2"
  162. Command="{Binding ActionCommand}"
  163. CommandParameter="1">
  164. <Grid>
  165. <materialDesign:PackIcon Margin="1"
  166. HorizontalAlignment="Center"
  167. VerticalAlignment="Center"
  168. Kind="ArrowBottomLeftThick" />
  169. <TextBlock HorizontalAlignment="Right"
  170. VerticalAlignment="Bottom"
  171. Text="B" />
  172. </Grid>
  173. </Button>
  174. <Button Grid.Row="1"
  175. Grid.Column="2"
  176. Command="{Binding ActionCommand}"
  177. CommandParameter="0">
  178. <Grid>
  179. <materialDesign:PackIcon Margin="1"
  180. HorizontalAlignment="Center"
  181. VerticalAlignment="Center"
  182. Kind="ArrowLeftBold" />
  183. <TextBlock HorizontalAlignment="Right"
  184. VerticalAlignment="Bottom"
  185. Text="A" />
  186. </Grid>
  187. </Button>
  188. <Button Grid.Row="2"
  189. Grid.Column="2"
  190. Command="{Binding ActionCommand}"
  191. CommandParameter="2">
  192. <Grid>
  193. <materialDesign:PackIcon Margin="1"
  194. HorizontalAlignment="Center"
  195. VerticalAlignment="Center"
  196. Kind="ArrowTopLeftThick" />
  197. <TextBlock HorizontalAlignment="Right"
  198. VerticalAlignment="Bottom"
  199. Text="C" />
  200. </Grid>
  201. </Button>
  202. </Grid>
  203. <Grid Margin="318,16,15,16">
  204. <Grid.RowDefinitions>
  205. <RowDefinition Height="*" />
  206. <RowDefinition Height="*" />
  207. <RowDefinition Height="*" />
  208. </Grid.RowDefinitions>
  209. <Button Grid.Row="0"
  210. Command="{Binding ActionCommand}"
  211. CommandParameter="9">
  212. <Grid>
  213. <materialDesign:PackIcon Margin="1"
  214. Foreground="White"
  215. HorizontalAlignment="Center"
  216. VerticalAlignment="Center"
  217. Kind="ArrowCollapseHorizontal" />
  218. <TextBlock HorizontalAlignment="Right"
  219. VerticalAlignment="Bottom"
  220. Text="J" />
  221. </Grid>
  222. </Button>
  223. <Button Grid.Row="1"
  224. Command="{Binding ActionCommand}"
  225. CommandParameter="10">
  226. <Grid>
  227. <materialDesign:PackIcon Margin="1"
  228. Foreground="White"
  229. HorizontalAlignment="Center"
  230. VerticalAlignment="Center"
  231. Kind="ArrowCollapseVertical" />
  232. <TextBlock HorizontalAlignment="Right"
  233. VerticalAlignment="Bottom"
  234. Text="K" />
  235. </Grid>
  236. </Button>
  237. <Button Grid.Row="2"
  238. Command="{Binding ActionCommand}"
  239. CommandParameter="-1">
  240. <Grid>
  241. <materialDesign:PackIcon Margin="1"
  242. Foreground="White"
  243. HorizontalAlignment="Center"
  244. VerticalAlignment="Center"
  245. Kind="{Binding LightKind}">
  246. <materialDesign:PackIcon.Style>
  247. <Style TargetType="materialDesign:PackIcon">
  248. <Style.Triggers>
  249. <Trigger Property="Kind"
  250. Value="LightbulbOnOutline">
  251. <Setter Property="Foreground"
  252. Value="Orange" />
  253. </Trigger>
  254. <Trigger Property="Kind"
  255. Value="LightbulbOutline">
  256. <Setter Property="Foreground"
  257. Value="Black" />
  258. </Trigger>
  259. </Style.Triggers>
  260. </Style>
  261. </materialDesign:PackIcon.Style>
  262. </materialDesign:PackIcon>
  263. </Grid>
  264. </Button>
  265. </Grid>
  266. </Grid>
  267. </Viewbox>
  268. </UserControl>