diff options
author | der richter <der.richter@gmx.de> | 2024-04-01 01:10:13 +0200 |
---|---|---|
committer | der richter <der.richter@gmx.de> | 2024-04-01 22:13:39 +0200 |
commit | 67c48ed92230c174272c36c42d84049e5e6366fd (patch) | |
tree | 05d07a4b0866de1ada4ffbad861579f57fa20ed0 /osdep | |
parent | 3c5149795480a15bf00c1a14045294f389e37af5 (diff) | |
download | mpv-67c48ed92230c174272c36c42d84049e5e6366fd.tar.bz2 mpv-67c48ed92230c174272c36c42d84049e5e6366fd.tar.xz |
mac/menu: remove redundant quit func and use identical command func
Diffstat (limited to 'osdep')
-rw-r--r-- | osdep/mac/menu_bar.swift | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/osdep/mac/menu_bar.swift b/osdep/mac/menu_bar.swift index 8768348db7..b58367a7a6 100644 --- a/osdep/mac/menu_bar.swift +++ b/osdep/mac/menu_bar.swift @@ -110,8 +110,8 @@ class MenuBar: NSObject { Config(name: "Hide Others", key: "h", modifiers: [.command, .option], action: #selector(NSApp.hideOtherApplications(_:))), Config(name: "Show All", action: #selector(NSApp.unhideAllApplications(_:))), Config(type: .separator), - Config(name: "Quit and Remember Position", action: #selector(quit(_:)), target: self, command: "quit-watch-later"), - Config(name: "Quit mpv", key: "q", action: #selector(quit(_:)), target: self, command: "quit"), + Config(name: "Quit and Remember Position", action: #selector(command(_:)), target: self, command: "quit-watch-later"), + Config(name: "Quit mpv", key: "q", action: #selector(command(_:)), target: self, command: "quit"), ] let fileMenuConfigs = [ @@ -320,11 +320,6 @@ class MenuBar: NSObject { } } - @objc func quit(_ menuItem: MenuItem) { - guard let menuConfig = menuItem.config else { return } - appHub.input.command(menuConfig.command) - } - @objc func openFiles() { let panel = NSOpenPanel() panel.allowsMultipleSelection = true |