private void mainWindow_Loaded(object sender, RoutedEventArgs e) { PTManager manager = (PTManager)this.DataContext; manager.SetObserver(this); dateView.ItemsSource = manager.GetDateTable().DefaultView; }
public void update() { PTManager manager = (PTManager)this.DataContext; dateView.ItemsSource = manager.GetDateTable().DefaultView; if (dateView.SelectedItem != null) { DateTime datetime = (DateTime)((DataRowView)dateView.SelectedItem).Row.ItemArray[0]; processInfoView.ItemsSource = manager.GetProcessInfoTableForDate(datetime).DefaultView; } }