public MenuViewPlotSettingsViewModel(IEventAggregator eventAggregator, IPlotSettingService plotSettingService) { OpenPlotSettingsCommand = new DelegateCommand(OpenPlotSettingsAction); _plotSettingsViewModel = new PlotSettingsViewModel(eventAggregator, plotSettingService); }
public ZonePlotViewModel(IEventAggregator eventAggregator, IPlotModelHelper plotModelHelper, IPlotSettingService plotSettingService) { PointsInZones = new ObservableCollection <string>(); _plotModelHelper = plotModelHelper; CalculateCommand = new DelegateCommand(CalculateAction); var zoneUserSettingsService = new ZoneUserSettingsService(); _zones = zoneUserSettingsService.LoadZones(eventAggregator); _eventAggregator = eventAggregator; _eventAggregator.GetEvent <PlotSettingsEvent>().Subscribe(ApplyPlotSettings); _eventAggregator.GetEvent <PipelineCompletedEvent>().Subscribe(OnPipelineCompletedEvent); _eventAggregator.GetEvent <ZoneChangeEvent>().Subscribe(PlotZone); Settings = plotSettingService.LoadPlotSettings(); ApplyPlotSettings(Settings); _pointsInsideZones = new List <int>(); }
public LinePlotViewModel(IEventAggregator eventAggregator, IPlotModelHelper plotModelHelper, IPlotSettingService plotSettingService) { _plotModelHelper = plotModelHelper; PipelineHistory = new ObservableCollection <PipelineCompletedEventModel>(); eventAggregator.GetEvent <PlotSettingsEvent>().Subscribe(ApplyPlotSettings); eventAggregator.GetEvent <PipelineCompletedEvent>().Subscribe(OnPipelineCompletedEvent); Settings = plotSettingService.LoadPlotSettings(); ApplyPlotSettings(Settings); }