public MainWindow() { InitializeComponent(); var context = new ClockViewModel(); DataContext = context; KeyUp += context.WindowKeyPress; }
/// <summary> /// Constructor /// </summary> public MainWindow() { InitializeComponent(); _mainViewModel = new(); Loaded += MainWindowLoaded; }