Update only the favicon in the sidebar when a favicon is downloaded — no need to update the rest of the cell.

This commit is contained in:
Brent Simmons 2017-12-13 21:16:52 -08:00
parent db1db7b701
commit e6dee88e2e

View File

@ -86,7 +86,7 @@ import RSCore
@objc func faviconDidBecomeAvailable(_ note: Notification) {
configureAvailableCells()
applyToAvailableCells(configureFavicon)
}
@objc func feedSettingDidChange(_ note: Notification) {
@ -342,7 +342,7 @@ private extension SidebarViewController {
cell.objectValue = node
cell.name = nameFor(node)
configureUnreadCount(cell, node)
cell.image = imageFor(node)
configureFavicon(cell, node)
cell.shouldShowImage = node.representedObject is Feed
}
@ -351,6 +351,11 @@ private extension SidebarViewController {
cell.unreadCount = unreadCountFor(node)
}
func configureFavicon(_ cell: SidebarCell, _ node: Node) {
cell.image = imageFor(node)
}
func configureGroupCell(_ cell: NSTableCellView, _ node: Node) {
cell.objectValue = node