Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: tray icon not highlighting on empty menu #34205

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 3 additions & 3 deletions shell/browser/ui/tray_icon_cocoa.mm
Expand Up @@ -193,9 +193,9 @@ - (void)mouseDown:(NSEvent*)event {
gfx::ScreenPointFromNSPoint([event locationInWindow]),
ui::EventFlagsFromModifiers([event modifierFlags]));

// Pass click to superclass to show menu. Custom mouseUp handler won't be
// invoked.
if (menuController_) {
// Pass click to superclass to show menu if one exists and has a non-zero
// number of items. Custom mouseUp handler won't be invoked in this case.
if (menuController_ && [[menuController_ menu] numberOfItems] > 0) {
[self handleClickNotifications:event];
[super mouseDown:event];
} else {
Expand Down