mirror of
https://github.com/AgentSeal/codeburn.git
synced 2026-04-28 06:59:37 +00:00
Merge pull request #125 from getagentseal/fix/menubar-force-redraw
Some checks are pending
CI / semgrep (push) Waiting to run
Some checks are pending
CI / semgrep (push) Waiting to run
fix(menubar): force status bar redraw and lift subprocess QoS
This commit is contained in:
commit
90aa342a34
2 changed files with 10 additions and 0 deletions
|
|
@ -158,6 +158,11 @@ final class AppDelegate: NSObject, NSApplicationDelegate, NSPopoverDelegate {
|
|||
attributes: [.font: font, .foregroundColor: color]
|
||||
))
|
||||
button.attributedTitle = composed
|
||||
// Force immediate redraw. NSStatusItem sometimes defers the status bar paint for an
|
||||
// accessory app that is not foreground, so the label visually freezes until the user
|
||||
// opens the popover (which triggers NSApp.activate + a forced redraw cycle).
|
||||
button.needsDisplay = true
|
||||
button.display()
|
||||
}
|
||||
|
||||
// MARK: - Popover
|
||||
|
|
|
|||
|
|
@ -41,6 +41,11 @@ enum CodeburnCLI {
|
|||
// `env --` treats everything following as argv, not VAR=val pairs -- guards against an
|
||||
// argument accidentally resembling an env assignment.
|
||||
process.arguments = ["--"] + baseArgv() + subcommand
|
||||
// The menubar runs as an accessory app with no foreground window, and macOS
|
||||
// background-throttles accessory apps and their children. Without this lift the
|
||||
// codeburn subprocess parses 5-10x slower than the same command run from a
|
||||
// user-interactive terminal, which starves the 15s refresh cadence on large corpora.
|
||||
process.qualityOfService = .userInitiated
|
||||
return process
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue