perf: menubar takes a few frame less to compute

This commit is contained in:
Louis Pontoise authored and lwouis committed 2020-09-05 04:01:32 +09:00
1 parent cbc4c39aa5
commit 3b7350f853
1 file changed
+1
+1
View File
@@ -6,6 +6,7 @@ class Menubar {
static func initialize() {
statusItem = NSStatusBar.system.statusItem(withLength: NSStatusItem.squareLength)
statusItem.menu = NSMenu()
statusItem.menu!.title = App.name // perf: prevent going through expensive code-path within appkit
statusItem.menu!.addItem(
withTitle: String(format: NSLocalizedString("About %@", comment: "Menubar option. %@ is AltTab"), App.name),
action: #selector(App.app.showAboutTab),