public void InitializeBeforeShowingTheWindow() { // if necessary, add references of main window to view models that // contain dialogs, so they could have parent window var notes = mainRepository.LoadNotes().Select(n => n.FromDisk()).ToList(); centralPanelVM.InitializeNotes(notes); var counterValue = dailyTimeCalculation.CalculateTimeForToday(notes); totalCounterVM.InitCounter(counterValue); }