epsidoe progresses fixes

This commit is contained in:
Francesco 2025-05-31 18:33:39 +02:00
parent 73f940f818
commit 893ab70a53
2 changed files with 5 additions and 0 deletions

View file

@ -243,6 +243,9 @@ struct EpisodeCell: View {
.onReceive(NotificationCenter.default.publisher(for: NSNotification.Name("downloadCompleted"))) { _ in
updateDownloadStatus()
}
.onReceive(NotificationCenter.default.publisher(for: NSNotification.Name("episodeProgressChanged"))) { _ in
updateProgress()
}
}
private var episodeThumbnail: some View {

View file

@ -779,6 +779,8 @@ struct MediaInfoView: View {
userDefaults.set(value, forKey: key)
}
userDefaults.synchronize()
NotificationCenter.default.post(name: NSNotification.Name("episodeProgressChanged"), object: nil)
Logger.shared.log(
"Marked \(ep.number - 1) episodes watched within series \"\(title)\".",
type: "General"