WaitImportDlg.xaml.cs 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. using System;
  2. using System.Collections.Generic;
  3. using System.ComponentModel;
  4. using System.Linq;
  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.Shapes;
  15. namespace MeterVision.Dlg
  16. {
  17. /// <summary>
  18. /// WaitImportDlg.xaml 的交互逻辑
  19. /// </summary>
  20. public partial class WaitImportDlg : Window, INotifyPropertyChanged
  21. {
  22. public event PropertyChangedEventHandler PropertyChanged;
  23. protected void OnPropertyChanged(string propertyName)
  24. {
  25. PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
  26. }
  27. public string TitleInfo { get; set; }
  28. private int _prgCount;
  29. public int PrgCount
  30. {
  31. get => _prgCount;
  32. set
  33. {
  34. if(_prgCount != value)
  35. {
  36. _prgCount = value;
  37. OnPropertyChanged(nameof(PrgCount));
  38. }
  39. }
  40. }
  41. private int _prgIndex;
  42. public int PrgIndex
  43. {
  44. get => _prgIndex;
  45. set
  46. {
  47. if(_prgIndex != value)
  48. {
  49. _prgIndex = value;
  50. OnPropertyChanged(nameof(PrgIndex));
  51. }
  52. }
  53. }
  54. public WaitImportDlg(string titleInfo)
  55. {
  56. InitializeComponent();
  57. TitleInfo = titleInfo;
  58. this.DataContext = this;
  59. }
  60. }
  61. }