From 19edf6793615204ef0affa943e38f5ae8738c3e6 Mon Sep 17 00:00:00 2001 From: Flaky Date: Sun, 10 May 2026 14:23:26 +0100 Subject: [PATCH] remove unused function lol, forgor that it was directly using ShowDialog. --- UI/Services/DialogService.cs | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/UI/Services/DialogService.cs b/UI/Services/DialogService.cs index c700b52..8c823fa 100644 --- a/UI/Services/DialogService.cs +++ b/UI/Services/DialogService.cs @@ -1,11 +1,9 @@ using System; -using System.Collections.Generic; using System.Linq; using System.Threading.Tasks; using Avalonia; using Avalonia.Controls; using Avalonia.Controls.ApplicationLifetimes; -using TagHierarchyManager.Models; using TagHierarchyManager.UI.ViewModels; using TagHierarchyManager.UI.Views; @@ -15,7 +13,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 +23,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."); -- 2.51.2