Create a pseudoFeeds array held by the app delegate. Create the Today feed at startup.

This commit is contained in:
Brent Simmons 2017-11-19 12:46:29 -08:00
parent 83cee90929
commit d901bbb218
1 changed files with 5 additions and 0 deletions

View File

@ -40,6 +40,8 @@ class AppDelegate: NSObject, NSApplicationDelegate, NSUserInterfaceValidations {
private let appNewsURLString = "https://ranchero.com/evergreen/feed.json"
private let dockBadge = DockBadge()
var pseudoFeeds = [PseudoFeed]()
var unreadCount = 0 {
didSet {
if unreadCount != oldValue {
@ -93,6 +95,9 @@ class AppDelegate: NSObject, NSApplicationDelegate, NSUserInterfaceValidations {
DefaultFeedsImporter.importIfNeeded(isFirstRun, account: localAccount)
currentTheme = themeLoader.defaultTheme
let todayFeed = PseudoFeed(delegate: TodayFeedDelegate())
pseudoFeeds += [todayFeed]
createAndShowMainWindow()