Modernize Xclean menu bar behavior - #6
Conversation
macmade
left a comment
There was a problem hiding this comment.
Thanks for your interest in the project.
Unfortunately, after reviewing the changes, I don't really think this PR adds anything useful to the project, especially considering the number of issues it introduces.
There was a problem hiding this comment.
Please do not include a manual changelog file just for your own changes in a PR.
Changes should be described in commits - that's GIT's job.
There was a problem hiding this comment.
Please do not alter or duplicate build settings without a valid reason.
They are already set via xcconfig files.
There was a problem hiding this comment.
I don't think ignoring OS_ACTIVITY_MODE is useful or needed.
| self.name = FileManager.default.displayName( atPath: workspace ) | ||
| self.size = 0 | ||
| self.icon = NSWorkspace.shared.icon( forFileType: ( workspace as NSString ).pathExtension ) | ||
| self.icon = Self.icon( forFilenameExtension: ( workspace as NSString ).pathExtension ) |
There was a problem hiding this comment.
This results in broken icons for project files.
Please test your changes.
| self.popover?.contentViewController = controller | ||
| self.popover?.behavior = .applicationDefined | ||
| let popover = NSPopover() | ||
| popover.contentViewController = controller |
There was a problem hiding this comment.
Please keep the alignment consistent.
| return | ||
| } | ||
|
|
||
| if let imageURL = Bundle.main.url( forResource: "StatusIconTemplate", withExtension: "pdf" ), |
There was a problem hiding this comment.
Why are you using Bundle instead of NSImage here?
| if let imageURL = Bundle.main.url( forResource: "StatusIconTemplate", withExtension: "pdf" ), | ||
| let image = NSImage( contentsOf: imageURL ) | ||
| { | ||
| image.isTemplate = true |
| image.isTemplate = true | ||
| image.size = NSSize( width: 18, height: 18 ) | ||
| button.image = image | ||
| button.title = "" |
| } | ||
| else | ||
| { | ||
| button.image = nil |
| else | ||
| { | ||
| button.image = nil | ||
| button.title = "X" |
There was a problem hiding this comment.
If you really want an alternative, consider using SF Symbols instead.
Summary
Scope
This PR intentionally does not change
.gitmodulesorSubmodules/GitHubUpdates. The earlier GitHubUpdates skip-option work is excluded so this can merge cleanly into the original Xclean repository.Validation
326Y53CJMD, and the untouched GitHubUpdates submodule target still declares macOS deployment target 10.12, which is unsupported by the installed Xcode version.Author: Luis Hernandez luisrh@mac.com