small service cleanup
This commit is contained in:
@@ -66,7 +66,7 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
_currentDownloads.TryRemove(msg.DownloadId, out _);
|
_currentDownloads.TryRemove(msg.DownloadId, out _);
|
||||||
if (!_currentDownloads.Any())
|
if (!_currentDownloads.Any())
|
||||||
{
|
{
|
||||||
_notificationService.DismissPairDownloadNotification();
|
Mediator.Publish(new LightlessNotificationDismissMessage("pair_download_progress"));
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
Mediator.Subscribe<GposeStartMessage>(this, (_) => IsOpen = false);
|
Mediator.Subscribe<GposeStartMessage>(this, (_) => IsOpen = false);
|
||||||
@@ -117,7 +117,7 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
}
|
}
|
||||||
catch
|
catch
|
||||||
{
|
{
|
||||||
// ignore errors thrown from UI
|
_logger.LogDebug("Error drawing upload progress");
|
||||||
}
|
}
|
||||||
|
|
||||||
try
|
try
|
||||||
@@ -129,7 +129,7 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
|
|
||||||
if (useNotifications)
|
if (useNotifications)
|
||||||
{
|
{
|
||||||
// Use notification system - only update when data actually changes
|
// Use notification system
|
||||||
if (_currentDownloads.Any())
|
if (_currentDownloads.Any())
|
||||||
{
|
{
|
||||||
UpdateDownloadNotificationIfChanged(limiterSnapshot);
|
UpdateDownloadNotificationIfChanged(limiterSnapshot);
|
||||||
@@ -137,13 +137,14 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
}
|
}
|
||||||
else if (!_notificationDismissed)
|
else if (!_notificationDismissed)
|
||||||
{
|
{
|
||||||
_notificationService.DismissPairDownloadNotification();
|
Mediator.Publish(new LightlessNotificationDismissMessage("pair_download_progress"));
|
||||||
_notificationDismissed = true;
|
_notificationDismissed = true;
|
||||||
_lastDownloadStateHash = 0;
|
_lastDownloadStateHash = 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
// Use text overlay
|
||||||
if (limiterSnapshot.IsEnabled)
|
if (limiterSnapshot.IsEnabled)
|
||||||
{
|
{
|
||||||
var queueColor = limiterSnapshot.Waiting > 0 ? ImGuiColors.DalamudYellow : ImGuiColors.DalamudGrey;
|
var queueColor = limiterSnapshot.Waiting > 0 ? ImGuiColors.DalamudYellow : ImGuiColors.DalamudGrey;
|
||||||
@@ -185,7 +186,7 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
}
|
}
|
||||||
catch
|
catch
|
||||||
{
|
{
|
||||||
// ignore errors thrown from UI
|
_logger.LogDebug("Error drawing download progress");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -257,7 +258,7 @@ public class DownloadUi : WindowMediatorSubscriberBase
|
|||||||
}
|
}
|
||||||
catch
|
catch
|
||||||
{
|
{
|
||||||
// ignore errors thrown on UI
|
_logger.LogDebug("Error drawing upload progress");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user