From 7f731164a36f859cf7440d501617e0d7332b768a Mon Sep 17 00:00:00 2001 From: Brent Simmons Date: Sat, 26 Jan 2019 21:45:22 -0800 Subject: [PATCH] Switch to Advanced prefs pane on click on toolbar item. --- NetNewsWire/Preferences/PreferencesWindowController.swift | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/NetNewsWire/Preferences/PreferencesWindowController.swift b/NetNewsWire/Preferences/PreferencesWindowController.swift index 63a370956..21efae3a9 100644 --- a/NetNewsWire/Preferences/PreferencesWindowController.swift +++ b/NetNewsWire/Preferences/PreferencesWindowController.swift @@ -58,8 +58,10 @@ class PreferencesWindowController : NSWindowController, NSToolbarDelegate { // MARK: Actions @objc func toolbarItemClicked(_ sender: Any?) { - - + guard let toolbarItem = sender as? NSToolbarItem else { + return + } + switchToView(identifier: toolbarItem.itemIdentifier.rawValue) } // MARK: NSToolbarDelegate