Skip to content

fix: menu state in macOS dock menus#49574

Merged
jkleinsc merged 1 commit intomainfrom
fix-dock-menus
Feb 2, 2026
Merged

fix: menu state in macOS dock menus#49574
jkleinsc merged 1 commit intomainfrom
fix-dock-menus

Conversation

@codebytere
Copy link
Copy Markdown
Member

Description of Change

Closes #49573

Fixes dock menu not properly supporting enabled, checked, and icon MenuItem properties. The issue was that menuWillOpen: isn't called by macOS for dock menus before they are displayed. The enabled, checked, and hidden states were only being applied in refreshMenuTree, which is called from menuWillOpen:. Since that delegate method doesn't fire for dock menus, the state was never applied.

This PR explicitly calls refreshMenuTree in applicationDockMenu: before returning the menu to macOS, ensuring the current model state is applied.

cc @Kilian

Checklist

Release Notes

Notes: Fixed dock menu items not respecting enabled and checked properties on macOS.

@codebytere codebytere added semver/patch backwards-compatible bug fixes target/38-x-y PR should also be added to the "38-x-y" branch. target/39-x-y PR should also be added to the "39-x-y" branch. target/40-x-y PR should also be added to the "40-x-y" branch. target/41-x-y PR should also be added to the "41-x-y" branch. labels Jan 29, 2026
@electron-cation electron-cation bot added the new-pr 🌱 PR opened recently label Jan 29, 2026
@electron-cation electron-cation bot removed the new-pr 🌱 PR opened recently label Jan 30, 2026
@jkleinsc jkleinsc merged commit 3776731 into main Feb 2, 2026
62 checks passed
@release-clerk
Copy link
Copy Markdown

release-clerk bot commented Feb 2, 2026

Release Notes Persisted

Fixed dock menu items not respecting enabled and checked properties on macOS.

@trop
Copy link
Copy Markdown
Contributor

trop bot commented Feb 2, 2026

I have automatically backported this PR to "40-x-y", please check out #49624

@trop trop bot added the in-flight/40-x-y label Feb 2, 2026
@trop
Copy link
Copy Markdown
Contributor

trop bot commented Feb 2, 2026

I have automatically backported this PR to "41-x-y", please check out #49625

@trop trop bot removed the target/40-x-y PR should also be added to the "40-x-y" branch. label Feb 2, 2026
@trop
Copy link
Copy Markdown
Contributor

trop bot commented Feb 2, 2026

I have automatically backported this PR to "39-x-y", please check out #49626

@trop
Copy link
Copy Markdown
Contributor

trop bot commented Feb 2, 2026

I have automatically backported this PR to "38-x-y", please check out #49627

@trop trop bot added merged/41-x-y PR was merged to the "41-x-y" branch. merged/40-x-y PR was merged to the "40-x-y" branch. merged/38-x-y PR was merged to the "38-x-y" branch. merged/39-x-y PR was merged to the "39-x-y" branch. and removed target/41-x-y PR should also be added to the "41-x-y" branch. target/39-x-y PR should also be added to the "39-x-y" branch. target/38-x-y PR should also be added to the "38-x-y" branch. in-flight/41-x-y in-flight/40-x-y in-flight/38-x-y in-flight/39-x-y labels Feb 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

merged/38-x-y PR was merged to the "38-x-y" branch. merged/39-x-y PR was merged to the "39-x-y" branch. merged/40-x-y PR was merged to the "40-x-y" branch. merged/41-x-y PR was merged to the "41-x-y" branch. semver/patch backwards-compatible bug fixes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

mac dock does not support enabled, icon and checked MenuItem properties

2 participants