Skip to content

fix(menubar): activate before creating the status item, policy pinned (#868) - #955

Merged
iamtoruk merged 2 commits into
mainfrom
fix/868-activate-only
Aug 10, 2026
Merged

fix(menubar): activate before creating the status item, policy pinned (#868)#955
iamtoruk merged 2 commits into
mainfrom
fix/868-activate-only

Conversation

@iamtoruk

Copy link
Copy Markdown
Member

Ships @ozymandiashh's activate-only fix for #868 (cherry-picked from experiment/868-activate-only, authorship preserved), so the next release carries the best available fix for the never-rendering status item on macOS 26.5.x instead of waiting on the test loop.

The analysis on the issue: 85b5728/db99319's real behavioral change was deleting #147's NSApp.activate call (the policy-setting half was already dead code, since packaged builds ship LSUIElement=true and start at .accessory before main() — measured with a probe bundle). That left the app creating its status item without ever registering with the window server, which is exactly the #146 state. This restores only the activation half, keeping the policy pinned so the .regular -> .accessory transition that plausibly caused the ghost item (the bug 85b5728 fixed) never happens. Second commit corrects the now-disproven comment at the applicationWillFinishLaunching policy call.

Honest framing: neither the analysis author nor this machine reproduces the black icon (renders fine on 26.5.0 and 26.5.2 with 0.9.19), so this is the well-argued middle path that flips neither historical bug, not an evidence-confirmed fix. It is falsifiable by the reporter on the release build either way, and the issue stays open until 25F80 confirms.

Verified: swift build clean, swift test 156/156 green; the healthy-machine case keeps rendering (the activate call is additive for accessory apps, no policy transition occurs).

ozymandiashh and others added 2 commits August 10, 2026 06:20
…ition

Test build for #868. Keeps the activation policy pinned at .accessory
(LSUIElement makes the :92-96 call a no-op in packaged builds anyway) and
restores only the NSApp.activate(ignoringOtherApps: true) half of the
#147 fix, immediately before the status item is created.
@iamtoruk
iamtoruk merged commit d302846 into main Aug 10, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants