Skip to content

Commit

Permalink
Always use image template because of dark mode prevalence these days
Browse files Browse the repository at this point in the history
  • Loading branch information
caseymrm committed Jan 28, 2020
1 parent 29d83d5 commit df384d5
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 4 deletions.
Binary file modified cmd/catalog/Catalog.app/Contents/MacOS/catalog
Binary file not shown.
5 changes: 1 addition & 4 deletions menuet.m
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,6 @@ - (void)populate:(NSArray *)items {
// called once per tracking session.
- (void)menuWillOpen:(MenuetMenu *)menu {
if (self.root) {
_statusItem.button.image.template = true;
// For the root menu, we generate a new unique every time it's opened. Go
// handles all other unique generation.
self.unique = [[[[NSProcessInfo processInfo] globallyUniqueString]
Expand Down Expand Up @@ -158,9 +157,6 @@ - (void)menuWillOpen:(MenuetMenu *)menu {
}

- (void)menuDidClose:(MenuetMenu *)menu {
if (self.root) {
_statusItem.button.image.template = false;
}
self.open = NO;
menuClosed(self.unique.UTF8String);
}
Expand Down Expand Up @@ -197,6 +193,7 @@ void setState(const char *jsonString) {
NSString *imageName = state[@"Image"];
NSImage *image = [NSImage imageFromName:imageName withHeight:22];
_statusItem.button.image = image;
_statusItem.button.image.template = true;
_statusItem.button.imagePosition = NSImageLeft;
});
}
Expand Down

0 comments on commit df384d5

Please sign in to comment.