mirror of
https://github.com/Ranchero-Software/NetNewsWire.git
synced 2024-12-24 16:51:19 +01:00
Draw using proper background color when selected but not emphasized. Fix #152.
This commit is contained in:
parent
b077dfafd1
commit
00ff9016bc
@ -36,6 +36,7 @@ class TimelineTableCellView: NSTableCellView {
|
||||
dateView.emphasized = isEmphasized
|
||||
feedNameView.emphasized = isEmphasized
|
||||
titleView.emphasized = isEmphasized
|
||||
needsDisplay = true
|
||||
}
|
||||
}
|
||||
|
||||
@ -115,7 +116,14 @@ class TimelineTableCellView: NSTableCellView {
|
||||
|
||||
override func draw(_ dirtyRect: NSRect) {
|
||||
|
||||
isSelected ? NSColor.alternateSelectedControlColor.set() : NSColor.white.set()
|
||||
let color: NSColor
|
||||
if isSelected {
|
||||
color = isEmphasized ? NSColor.alternateSelectedControlColor : NSColor.secondarySelectedControlColor
|
||||
}
|
||||
else {
|
||||
color = NSColor.white
|
||||
}
|
||||
color.set()
|
||||
dirtyRect.fill()
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user