diff --git a/UI/Services/DialogService.cs b/UI/Services/DialogService.cs index c700b52..c4a0af9 100644 --- a/UI/Services/DialogService.cs +++ b/UI/Services/DialogService.cs @@ -15,7 +15,7 @@ public class DialogService { public async Task ShowDialog(Window dialog, object? dataContext = null) { - var ownerWindow = this.GetOwnerWindow(); + var ownerWindow = GetOwnerWindow(); dialog.DataContext = dataContext; return await dialog.ShowDialog(ownerWindow); } @@ -25,13 +25,7 @@ public class DialogService return this.ShowDialog(new ErrorDialog(), new ErrorDialogViewModel(message)); } - public Task ShowAmbiguousSaveDialog(Tag tag, List parentTags) - { - var viewModel = new SaveAmbiguousViewModel(tag, parentTags); - return this.ShowDialog(new SaveAmbiguousDialog(), viewModel); - } - - private Window GetOwnerWindow() + private static Window GetOwnerWindow() { if (Application.Current?.ApplicationLifetime is not IClassicDesktopStyleApplicationLifetime desktop) throw new InvalidOperationException("Not in a desktop environment.");