You've already forked Sonarr
mirror of
https://github.com/Sonarr/Sonarr.git
synced 2025-11-06 09:19:38 +02:00
Updated task notification UI. Last message will stay on screen for an extra 3 seconds if there are no new messages.
This commit is contained in:
@@ -52,8 +52,8 @@ namespace NzbDrone.Core.Providers.Jobs
|
||||
updatedSeries.Title);
|
||||
_episodeProvider.RefreshEpisodeInfo(updatedSeries.SeriesId);
|
||||
|
||||
notification.CurrentStatus = String.Format("Scanning series folder {0}",
|
||||
updatedSeries.Path);
|
||||
notification.CurrentStatus = String.Format("Scanning disk for {0} files",
|
||||
updatedSeries.Title);
|
||||
_mediaFileProvider.Scan(_seriesProvider.GetSeries(updatedSeries.SeriesId));
|
||||
}
|
||||
|
||||
|
||||
@@ -44,6 +44,7 @@ namespace NzbDrone.Core.Providers.Jobs
|
||||
_seriesProvider.UpdateSeriesInfo(series.SeriesId);
|
||||
notification.CurrentStatus = "Updating episode info for " + series.Title;
|
||||
_episodeProvider.RefreshEpisodeInfo(series.SeriesId);
|
||||
notification.CurrentStatus = "Update completed for " + series.Title;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -24,9 +24,17 @@ namespace NzbDrone.Core.Providers
|
||||
{
|
||||
get
|
||||
{
|
||||
return
|
||||
new List<ProgressNotification>(
|
||||
_progressNotification.Values.Where(p => p.Status == ProgressNotificationStatus.InProgress));
|
||||
|
||||
var activeNotification = _progressNotification.Values.Where(p => p.Status == ProgressNotificationStatus.InProgress).ToList();
|
||||
|
||||
if (activeNotification.Count == 0)
|
||||
{
|
||||
//Get notifications that were recently done
|
||||
activeNotification = _progressNotification.Values.Where(p => p.CompletedTime >= DateTime.Now.AddSeconds(-3)).OrderByDescending(c => c.CompletedTime).ToList();
|
||||
|
||||
}
|
||||
|
||||
return activeNotification.ToList();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user