notifications refactor with duplication bugfix

This commit is contained in:
choco
2025-10-09 11:13:47 +02:00
parent 3fdc9dd958
commit 2b118df892
10 changed files with 434 additions and 585 deletions

View File

@@ -1,4 +1,4 @@
using Dalamud.Interface;
using Dalamud.Interface;
using Dalamud.Interface.ImGuiFileDialog;
using Dalamud.Interface.Windowing;
using LightlessSync.LightlessConfiguration;
@@ -23,7 +23,7 @@ public sealed class UiService : DisposableMediatorSubscriberBase
IEnumerable<WindowMediatorSubscriberBase> windows,
UiFactory uiFactory, FileDialogManager fileDialogManager,
LightlessMediator lightlessMediator,
LightlessNotificationService lightlessNotificationService) : base(logger, lightlessMediator)
NotificationService notificationService) : base(logger, lightlessMediator)
{
_logger = logger;
_logger.LogTrace("Creating {type}", GetType().Name);
@@ -41,12 +41,6 @@ public sealed class UiService : DisposableMediatorSubscriberBase
foreach (var window in windows)
{
_windowSystem.AddWindow(window);
// Connect the notification service to the notification UI
if (window is LightlessNotificationUI notificationUI)
{
lightlessNotificationService.SetNotificationUI(notificationUI);
}
}
Mediator.Subscribe<ProfileOpenStandaloneMessage>(this, (msg) =>