public IDialogService GetDialogService <TViewModel>(TViewModel viewModel) { var view = locator.GetView(typeof(TViewModel)); var window = windowProvider.Create(view, viewModel); window.Closed += Window_Closed; windowMap[viewModel] = window; return(new DefaultDialogService(window)); }
public IDialogService GetDialogService <TViewModel>(TViewModel viewModel) { var view = locator.GetView(typeof(TViewModel)); var window = windowProvider.Create(view, viewModel); window.Closed += Window_Closed; windowMap[viewModel] = window; return(new DefaultDialogService(window)); void Window_Closed(object sender, EventArgs e) { windowMap.Remove(viewModel); } }