diff --git a/README.md b/README.md index 54b0443..400f37c 100644 --- a/README.md +++ b/README.md @@ -85,7 +85,7 @@ Scoot includes a menu bar icon (an illustration of a Vespa-inspired scooter). Scoot Menu Bar Icon -* When Scoot is in the foreground, the icon will render with a tint, to make it clearer that Scoot is currently active. (This shouldn't generally be a concern, but it is handy when you're in freestyle mode.) +* When Scoot is in the foreground, the icon will render in an outlined mode, to make it clearer that Scoot is currently active. (This shouldn't generally be a concern, but it is handy when you're in freestyle mode.) * Additional options are exposed when clicking on the menu bar icon, including a _help_ menu item — which currently opens this README in the user's default browser. ### Keybindings diff --git a/Scoot/AppDelegate.swift b/Scoot/AppDelegate.swift index ec3e919..fe53a0d 100644 --- a/Scoot/AppDelegate.swift +++ b/Scoot/AppDelegate.swift @@ -218,24 +218,23 @@ class AppDelegate: NSObject, NSApplicationDelegate { let item = NSStatusBar.system.statusItem( withLength: NSStatusItem.squareLength ) - item.button?.image = menuBarStatusItemDefaultImage - item.button?.image?.size = NSSize(width: 18.0, height: 18.0) - item.menu = menu - self.statusItem = item } lazy var menuBarStatusItemDefaultImage: NSImage? = { let image = NSImage(named: "MenuIcon") + image?.size = NSSize(width: 18.0, height: 18.0) image?.isTemplate = true return image }() - lazy var menuBarStatusItemTintedImage: NSImage? = { - let tintColor = NSColor.systemTeal.withAlphaComponent(0.9) - return menuBarStatusItemDefaultImage?.withTintColor(tintColor) + lazy var menuBarStatusItemOutlinedImage: NSImage? = { + let image = NSImage(named: "MenuIcon-Outlined") + image?.size = NSSize(width: 18.0, height: 18.0) + image?.isTemplate = true + return image }() func updateMenuBarStatusItemForInactiveState() { @@ -243,7 +242,7 @@ class AppDelegate: NSObject, NSApplicationDelegate { } func updateMenuBarStatusItemForActiveState() { - self.statusItem?.button?.image = menuBarStatusItemTintedImage + self.statusItem?.button?.image = menuBarStatusItemOutlinedImage } // MARK: Activation diff --git a/Scoot/Assets.xcassets/MenuIcon-Outlined.imageset/Contents.json b/Scoot/Assets.xcassets/MenuIcon-Outlined.imageset/Contents.json new file mode 100644 index 0000000..e306d5b --- /dev/null +++ b/Scoot/Assets.xcassets/MenuIcon-Outlined.imageset/Contents.json @@ -0,0 +1,12 @@ +{ + "images" : [ + { + "filename" : "Menu Bar Icon - Outlined.pdf", + "idiom" : "universal" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/Scoot/Assets.xcassets/MenuIcon-Outlined.imageset/Menu Bar Icon - Outlined.pdf b/Scoot/Assets.xcassets/MenuIcon-Outlined.imageset/Menu Bar Icon - Outlined.pdf new file mode 100644 index 0000000..78d2b8c Binary files /dev/null and b/Scoot/Assets.xcassets/MenuIcon-Outlined.imageset/Menu Bar Icon - Outlined.pdf differ diff --git a/Scoot/Assets.xcassets/MenuIcon.imageset/Menu Bar Icon.pdf b/Scoot/Assets.xcassets/MenuIcon.imageset/Menu Bar Icon.pdf index 2ee0c3a..eecdf07 100644 Binary files a/Scoot/Assets.xcassets/MenuIcon.imageset/Menu Bar Icon.pdf and b/Scoot/Assets.xcassets/MenuIcon.imageset/Menu Bar Icon.pdf differ