CellStatusControl.xaml.cs 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6. using System.Windows;
  7. using System.Windows.Controls;
  8. using System.Windows.Data;
  9. using System.Windows.Documents;
  10. using System.Windows.Input;
  11. using System.Windows.Media;
  12. using System.Windows.Media.Imaging;
  13. using System.Windows.Navigation;
  14. using System.Windows.Shapes;
  15. namespace CyberX8_Themes.UserControls
  16. {
  17. /// <summary>
  18. /// CellStatusControl.xaml 的交互逻辑
  19. /// </summary>
  20. public partial class CellStatusControl : UserControl
  21. {
  22. public CellStatusControl()
  23. {
  24. InitializeComponent();
  25. }
  26. #region 属性
  27. public static readonly DependencyProperty ModuleNameProperty = DependencyProperty.Register(
  28. "ModuleName", typeof(string), typeof(CellStatusControl),
  29. new FrameworkPropertyMetadata("", FrameworkPropertyMetadataOptions.AffectsRender));
  30. /// <summary>
  31. /// 模块名称
  32. /// </summary>
  33. public string ModuleName
  34. {
  35. get
  36. {
  37. return (string)this.GetValue(ModuleNameProperty);
  38. }
  39. set
  40. {
  41. this.SetValue(ModuleNameProperty, value);
  42. }
  43. }
  44. public static readonly DependencyProperty AnodeAFlowProperty = DependencyProperty.Register(
  45. "AnodeAFlow", typeof(double), typeof(CellStatusControl),
  46. new FrameworkPropertyMetadata((double)0, FrameworkPropertyMetadataOptions.AffectsRender));
  47. /// <summary>
  48. /// Anode A Flow
  49. /// </summary>
  50. public double AnodeAFlow
  51. {
  52. get
  53. {
  54. return (double)this.GetValue(AnodeAFlowProperty);
  55. }
  56. set
  57. {
  58. this.SetValue(AnodeAFlowProperty, value);
  59. }
  60. }
  61. public static readonly DependencyProperty AnodeAStatusProperty = DependencyProperty.Register(
  62. "AnodeAStatus", typeof(string), typeof(CellStatusControl),
  63. new FrameworkPropertyMetadata("", FrameworkPropertyMetadataOptions.AffectsRender));
  64. /// <summary>
  65. /// Anode A Status
  66. /// </summary>
  67. public string AnodeAStatus
  68. {
  69. get
  70. {
  71. return (string)this.GetValue(AnodeAStatusProperty);
  72. }
  73. set
  74. {
  75. this.SetValue(AnodeAStatusProperty, value);
  76. }
  77. }
  78. public static readonly DependencyProperty AnodeBFlowProperty = DependencyProperty.Register(
  79. "AnodeBFlow", typeof(double), typeof(CellStatusControl),
  80. new FrameworkPropertyMetadata((double)0, FrameworkPropertyMetadataOptions.AffectsRender));
  81. /// <summary>
  82. /// Anode B Flow
  83. /// </summary>
  84. public double AnodeBFlow
  85. {
  86. get
  87. {
  88. return (double)this.GetValue(AnodeBFlowProperty);
  89. }
  90. set
  91. {
  92. this.SetValue(AnodeBFlowProperty, value);
  93. }
  94. }
  95. public static readonly DependencyProperty AnodeBStatusProperty = DependencyProperty.Register(
  96. "AnodeBStatus", typeof(string), typeof(CellStatusControl),
  97. new FrameworkPropertyMetadata("", FrameworkPropertyMetadataOptions.AffectsRender));
  98. /// <summary>
  99. /// Anode B Status
  100. /// </summary>
  101. public string AnodeBStatus
  102. {
  103. get
  104. {
  105. return (string)this.GetValue(AnodeBStatusProperty);
  106. }
  107. set
  108. {
  109. this.SetValue(AnodeBStatusProperty, value);
  110. }
  111. }
  112. public static readonly DependencyProperty CellFlowProperty = DependencyProperty.Register(
  113. "CellFlow", typeof(double), typeof(CellStatusControl),
  114. new FrameworkPropertyMetadata((double)0, FrameworkPropertyMetadataOptions.AffectsRender));
  115. /// <summary>
  116. /// Cell Flow
  117. /// </summary>
  118. public double CellFlow
  119. {
  120. get
  121. {
  122. return (double)this.GetValue(CellFlowProperty);
  123. }
  124. set
  125. {
  126. this.SetValue(CellFlowProperty, value);
  127. }
  128. }
  129. #endregion
  130. }
  131. }