Move refresh-all to end of applicationDidFinishLaunching.

This commit is contained in:
Brent Simmons 2017-12-25 10:23:12 -08:00
parent 3994e19199
commit 6a09a2d6ef
1 changed files with 6 additions and 6 deletions

View File

@ -147,12 +147,6 @@ class AppDelegate: NSObject, NSApplicationDelegate, NSUserInterfaceValidations,
createAndShowMainWindow() createAndShowMainWindow()
#if RELEASE
DispatchQueue.main.async {
self.refreshAll(self)
}
#endif
NSAppleEventManager.shared().setEventHandler(self, andSelector: #selector(AppDelegate.getURL(_:_:)), forEventClass: AEEventClass(kInternetEventClass), andEventID: AEEventID(kAEGetURL)) NSAppleEventManager.shared().setEventHandler(self, andSelector: #selector(AppDelegate.getURL(_:_:)), forEventClass: AEEventClass(kInternetEventClass), andEventID: AEEventID(kAEGetURL))
NotificationCenter.default.addObserver(self, selector: #selector(feedSettingDidChange(_:)), name: .FeedSettingDidChange, object: nil) NotificationCenter.default.addObserver(self, selector: #selector(feedSettingDidChange(_:)), name: .FeedSettingDidChange, object: nil)
@ -160,6 +154,12 @@ class AppDelegate: NSObject, NSApplicationDelegate, NSUserInterfaceValidations,
DispatchQueue.main.async { DispatchQueue.main.async {
self.unreadCount = AccountManager.shared.unreadCount self.unreadCount = AccountManager.shared.unreadCount
} }
#if RELEASE
DispatchQueue.main.async {
self.refreshAll(self)
}
#endif
} }
func applicationShouldHandleReopen(_ sender: NSApplication, hasVisibleWindows flag: Bool) -> Bool { func applicationShouldHandleReopen(_ sender: NSApplication, hasVisibleWindows flag: Bool) -> Bool {