/// <summary> /// Initialises a new instance of the <see cref="SessionModel"/> class. /// </summary> public SessionModel() { InnerDrivers = new SortableObservableCollection<DriverModel>((x, y) => { return x.Position.CompareTo(y.Position); }); Drivers = new ReadOnlyObservableCollection<DriverModel>(InnerDrivers); DriversById = new Dictionary<int, DriverModel>(25); Feed = new FeedModel(); Grid = GridModelBase.Create(SessionType.None); FastestTimes = new FastestTimesModel(this); Messages = new MessageModel(); OneSecondTimer = new DispatcherTimer(DispatcherPriority.Normal); OneSecondTimer.Interval = OneSecond; OneSecondTimer.Tick += (s, e) => OnOneSecondElapsed(); SessionStatus = SessionStatus.Finished; SpeedCaptures = new SpeedCapturesModel(this); Weather = new WeatherModel(); Builder = new SessionModelBuilder(this); }