mirror of
https://github.com/Ranchero-Software/NetNewsWire
synced 2025-08-12 06:26:36 +00:00
Change refresh behavior so that it doesn't rely on the debug menu. Fixes #2905
This commit is contained in:
@@ -246,10 +246,17 @@ class AppDelegate: NSObject, NSApplicationDelegate, NSUserInterfaceValidations,
|
||||
UNUserNotificationCenter.current().delegate = self
|
||||
userNotificationManager = UserNotificationManager()
|
||||
|
||||
#if DEBUG
|
||||
refreshTimer!.update()
|
||||
syncTimer!.update()
|
||||
#else
|
||||
DispatchQueue.main.async {
|
||||
self.refreshTimer!.timedRefresh(nil)
|
||||
self.syncTimer!.timedRefresh(nil)
|
||||
}
|
||||
#endif
|
||||
|
||||
if AppDefaults.shared.showDebugMenu {
|
||||
refreshTimer!.update()
|
||||
syncTimer!.update()
|
||||
|
||||
// The Web Inspector uses SPI and can never appear in a MAC_APP_STORE build.
|
||||
#if MAC_APP_STORE
|
||||
let debugMenu = debugMenuItem.submenu!
|
||||
@@ -260,10 +267,6 @@ class AppDelegate: NSObject, NSApplicationDelegate, NSUserInterfaceValidations,
|
||||
#endif
|
||||
} else {
|
||||
debugMenuItem.menu?.removeItem(debugMenuItem)
|
||||
DispatchQueue.main.async {
|
||||
self.refreshTimer!.timedRefresh(nil)
|
||||
self.syncTimer!.timedRefresh(nil)
|
||||
}
|
||||
}
|
||||
|
||||
#if !MAC_APP_STORE
|
||||
|
||||
Reference in New Issue
Block a user