public TimingOverlayViewModel(IWindowManager windowManager, IEventAggregator eventAggregator, F1Manager f1Manager) { F1Manager _f1Manager = f1Manager; _f1Manager.LapPacketReceived += _f1Manager_LapPacketReceived; _f1Manager.CarTelemetryReceived += _f1Manager_CarTelemetryReceived; _f1Manager.CarStatusReceived += _f1Manager_CarStatusReceived; _f1Manager.SessionChanged += _f1Manager_SessionChanged; _f1Manager.SessionPacketReceived += _f1Manager_SessionPacketReceived; _f1Manager.ParticipantsPacketReceived += _f1Manager_ParticipantsPacketReceived; }
public MainViewModel( IWindowManager windowManager, IEventAggregator eventAggregator, F1Manager f1Manager) { IWindowManager _windowManager = windowManager; _eventAggregator = eventAggregator; F1Manager _f1Manager = f1Manager; _f1Manager.NewLap += _f1Manager_NewLap; _f1Manager.LapPacketReceived += _f1Manager_LapPacketReceived; _f1Manager.CarTelemetryReceived += _f1Manager_CarTelemetryReceived; _f1Manager.SessionChanged += _f1Manager_SessionChanged; _f1Manager.CarStatusReceived += _f1Manager_CarStatusReceived; _f1Manager.Start(); InitGraphSettings(); _windowManager.ShowWindow(new TimingOverlayViewModel(_windowManager, _eventAggregator, _f1Manager)); }