Clean up shift-key checking and add it to more places

This commit is contained in:
Nate Weaver
2020-05-20 19:59:05 -05:00
parent 24338b135e
commit 1e1fc06e7b
4 changed files with 4 additions and 8 deletions

View File

@@ -264,10 +264,8 @@ class MainWindowController : NSWindowController, NSUserInterfaceValidations {
}
@IBAction func openArticleInBrowser(_ sender: Any?) {
let invert = NSApp.currentEvent?.modifierFlags.contains(.shift) ?? false
if let link = currentLink {
Browser.open(link, invertPreference: invert)
Browser.open(link, invertPreference: NSApp.currentEvent?.modifierFlags.contains(.shift) ?? false)
}
}