public void OpenBookEditor(object o) { if (ChosenBook == null) return; BookEditor re = new BookEditor(); ViewModelBookEditor redc = re.DataContext as ViewModelBookEditor; redc.SetAsEditor(this, ChosenBook); re.ShowDialog(); }
public void OpenBookAdder(object o) { BookEditor re = new BookEditor(); ViewModelBookEditor redc = re.DataContext as ViewModelBookEditor; redc.SetAsAdder(this); re.ShowDialog(); }