LoadPort.xaml.cs 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Reflection.Metadata.Ecma335;
  5. using System.Text;
  6. using System.Threading.Tasks;
  7. using System.Windows;
  8. using System.Windows.Controls;
  9. using System.Windows.Data;
  10. using System.Windows.Documents;
  11. using System.Windows.Input;
  12. using System.Windows.Media;
  13. using System.Windows.Media.Imaging;
  14. using System.Windows.Navigation;
  15. using System.Windows.Shapes;
  16. namespace SummaryModule.Controls.BaseMotion
  17. {
  18. /// <summary>
  19. /// Interaction logic for LoadPort.xaml
  20. /// </summary>
  21. public partial class LoadPort : UserControl
  22. {
  23. public LoadPort()
  24. {
  25. InitializeComponent();
  26. }
  27. public string Header
  28. {
  29. get { return (string)GetValue(HeaderProperty); }
  30. set { SetValue(HeaderProperty, value); }
  31. }
  32. // Using a DependencyProperty as the backing store for Header. This enables animation, styling, binding, etc...
  33. public static readonly DependencyProperty HeaderProperty =
  34. DependencyProperty.Register(nameof(Header), typeof(string), typeof(LoadPort), new PropertyMetadata(default));
  35. public ICommand Command
  36. {
  37. get { return (ICommand)GetValue(CommandProperty); }
  38. set { SetValue(CommandProperty, value); }
  39. }
  40. // Using a DependencyProperty as the backing store for Command. This enables animation, styling, binding, etc...
  41. public static readonly DependencyProperty CommandProperty =
  42. DependencyProperty.Register(nameof(Command), typeof(ICommand), typeof(LoadPort), new PropertyMetadata(default));
  43. public object CommandParameter
  44. {
  45. get { return (object)GetValue(CommandParameterProperty); }
  46. set { SetValue(CommandParameterProperty, value); }
  47. }
  48. // Using a DependencyProperty as the backing store for CommandParameter. This enables animation, styling, binding, etc...
  49. public static readonly DependencyProperty CommandParameterProperty =
  50. DependencyProperty.Register(nameof(CommandParameter), typeof(object), typeof(LoadPort), new PropertyMetadata(default));
  51. public bool FoupLoaded
  52. {
  53. get { return (bool)GetValue(FoupLoadedProperty); }
  54. set { SetValue(FoupLoadedProperty, value); }
  55. }
  56. // Using a DependencyProperty as the backing store for FoupLoaded. This enables animation, styling, binding, etc...
  57. public static readonly DependencyProperty FoupLoadedProperty =
  58. DependencyProperty.Register(nameof(FoupLoaded), typeof(bool), typeof(LoadPort), new PropertyMetadata(false));
  59. }
  60. }