Merge branch 'master' of https://github.com/brentsimmons/NetNewsWire
This commit is contained in:
commit
3dc2bc2c49
|
@ -19,7 +19,7 @@ class TimelineTableCellView: NSTableCellView {
|
||||||
private let feedNameView = TimelineTableCellView.singleLineTextField()
|
private let feedNameView = TimelineTableCellView.singleLineTextField()
|
||||||
|
|
||||||
private lazy var avatarImageView: NSImageView = {
|
private lazy var avatarImageView: NSImageView = {
|
||||||
let imageView = TimelineTableCellView.imageView(with: AppImages.genericFeedImage, scaling: .scaleProportionallyDown)
|
let imageView = TimelineTableCellView.imageView(with: AppImages.genericFeedImage, scaling: .scaleNone)
|
||||||
imageView.wantsLayer = true
|
imageView.wantsLayer = true
|
||||||
return imageView
|
return imageView
|
||||||
}()
|
}()
|
||||||
|
|
|
@ -10,6 +10,10 @@ import AppKit
|
||||||
|
|
||||||
class TimelineTableRowView : NSTableRowView {
|
class TimelineTableRowView : NSTableRowView {
|
||||||
|
|
||||||
|
override var isOpaque: Bool {
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
|
||||||
init() {
|
init() {
|
||||||
super.init(frame: NSRect.zero)
|
super.init(frame: NSRect.zero)
|
||||||
}
|
}
|
||||||
|
|
|
@ -24,6 +24,10 @@ class TimelineTableView: NSTableView {
|
||||||
|
|
||||||
// MARK: - NSView
|
// MARK: - NSView
|
||||||
|
|
||||||
|
override var isOpaque: Bool {
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
|
||||||
override func viewWillStartLiveResize() {
|
override func viewWillStartLiveResize() {
|
||||||
if let scrollView = self.enclosingScrollView {
|
if let scrollView = self.enclosingScrollView {
|
||||||
scrollView.hasVerticalScroller = false
|
scrollView.hasVerticalScroller = false
|
||||||
|
|
|
@ -85,17 +85,18 @@ struct TimelineStringFormatter {
|
||||||
return ""
|
return ""
|
||||||
}
|
}
|
||||||
|
|
||||||
if let cachedBody = summaryCache[body] {
|
let key = article.articleID + article.accountID
|
||||||
|
if let cachedBody = summaryCache[key] {
|
||||||
return cachedBody
|
return cachedBody
|
||||||
}
|
}
|
||||||
var s = body.rsparser_stringByDecodingHTMLEntities()
|
var s = body.rsparser_stringByDecodingHTMLEntities()
|
||||||
s = s.rs_string(byStrippingHTML: 300)
|
s = s.rs_string(byStrippingHTML: 150)
|
||||||
s = s.rs_stringByTrimmingWhitespace()
|
s = s.rs_stringByTrimmingWhitespace()
|
||||||
s = s.rs_stringWithCollapsedWhitespace()
|
s = s.rs_stringWithCollapsedWhitespace()
|
||||||
if s == "Comments" { // Hacker News.
|
if s == "Comments" { // Hacker News.
|
||||||
s = ""
|
s = ""
|
||||||
}
|
}
|
||||||
summaryCache[body] = s
|
summaryCache[key] = s
|
||||||
return s
|
return s
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Subproject commit 6ab0683e6d2fb2dc09b5625a7da62459dbc0d9af
|
Subproject commit 9c268f00e93f758a79dae04dd8f18d27449221b0
|
Loading…
Reference in New Issue