mirror of
https://github.com/Ranchero-Software/NetNewsWire.git
synced 2025-01-12 01:33:51 +01:00
Queue a reload of all visible cells anytime a favicon is downloaded. Issue #995
This commit is contained in:
parent
809c2fdfc5
commit
0e7d971e65
@ -513,18 +513,8 @@ final class TimelineViewController: NSViewController, UndoableCommandRunner, Unr
|
|||||||
}
|
}
|
||||||
|
|
||||||
@objc func faviconDidBecomeAvailable(_ note: Notification) {
|
@objc func faviconDidBecomeAvailable(_ note: Notification) {
|
||||||
guard showAvatars, let faviconURL = note.userInfo?[FaviconDownloader.UserInfoKey.faviconURL] as? String else {
|
if showAvatars {
|
||||||
return
|
queueReloadAvailableCells()
|
||||||
}
|
|
||||||
|
|
||||||
let indexesToReload = tableView.indexesOfAvailableRowsPassingTest { (row) -> Bool in
|
|
||||||
guard let article = articles.articleAtRow(row) else {
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
return article.feed?.faviconURL == faviconURL
|
|
||||||
}
|
|
||||||
if let indexesToReload = indexesToReload {
|
|
||||||
reloadCells(for: indexesToReload)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user