summaryrefslogtreecommitdiffstats
path: root/osdep
diff options
context:
space:
mode:
authorder richter <der.richter@gmx.de>2024-04-01 01:10:13 +0200
committerder richter <der.richter@gmx.de>2024-04-01 22:13:39 +0200
commit67c48ed92230c174272c36c42d84049e5e6366fd (patch)
tree05d07a4b0866de1ada4ffbad861579f57fa20ed0 /osdep
parent3c5149795480a15bf00c1a14045294f389e37af5 (diff)
downloadmpv-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.swift9
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