JetEventView.xaml.cs 1007 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Windows;
  6. using System.Windows.Controls;
  7. using System.Windows.Data;
  8. using System.Windows.Documents;
  9. using System.Windows.Input;
  10. using System.Windows.Media;
  11. using System.Windows.Media.Imaging;
  12. using System.Windows.Navigation;
  13. using System.Windows.Shapes;
  14. using Aitex.Core.UI.MVVM;
  15. using Triton160.UI.ViewModel;
  16. namespace Aitex.Triton160.UI.Views
  17. {
  18. /// <summary>
  19. /// Interaction logic for EventView.xaml
  20. /// </summary>
  21. public partial class JetEventView : UserControl
  22. {
  23. public JetEventView()
  24. {
  25. InitializeComponent();
  26. this.DataContext = new JetEventViewModel();
  27. this.IsVisibleChanged += JetEventView_IsVisibleChanged;
  28. }
  29. void JetEventView_IsVisibleChanged(object sender, DependencyPropertyChangedEventArgs e)
  30. {
  31. (this.DataContext as TimerViewModelBase).EnableTimer(this.IsVisible);
  32. }
  33. }
  34. }