[Mac] Fix menu closing immediately after opening with keyboard shortcuts [chromium/src : main]

0 views
Skip to first unread message

gwsq (Gerrit)

unread,
Jan 11, 2026, 9:49:02 PM (6 days ago) Jan 11
to liang zeng, Chromium UI Views Reviews, Robert Liao, Chromium LUCI CQ, Yuanjun Zhu, AyeAye, chromium...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
Attention needed from Robert Liao and Yuanjun Zhu

Message from gwsq

Reviewer source(s):
rob...@chromium.org is from context(googleclient/chrome/chromium_gwsq/ui/views/config.gwsq)

Open in Gerrit

Related details

Attention is currently required from:
  • Robert Liao
  • Yuanjun Zhu
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement is not satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
  • requirement is not satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: Ic8b7f673ad0c8351d170d1b68b75f301bc2436e3
Gerrit-Change-Number: 7408739
Gerrit-PatchSet: 1
Gerrit-Owner: liang zeng <lian...@microsoft.com>
Gerrit-Reviewer: Robert Liao <rob...@chromium.org>
Gerrit-Reviewer: Yuanjun Zhu <yuanj...@microsoft.com>
Gerrit-Reviewer: liang zeng <lian...@microsoft.com>
Gerrit-CC: Chromium UI Views Reviews <chromium-ui-...@google.com>
Gerrit-CC: gwsq
Gerrit-Attention: Robert Liao <rob...@chromium.org>
Gerrit-Attention: Yuanjun Zhu <yuanj...@microsoft.com>
Gerrit-Comment-Date: Mon, 12 Jan 2026 02:48:28 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: No
satisfied_requirement
unsatisfied_requirement
open
diffy

Robert Liao (Gerrit)

unread,
Jan 12, 2026, 5:40:08 PM (5 days ago) Jan 12
to liang zeng, Chromium UI Views Reviews, Chromium LUCI CQ, Yuanjun Zhu, AyeAye, chromium...@chromium.org, mmen...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
Attention needed from Yuanjun Zhu and liang zeng

Robert Liao added 6 comments

Patchset-level comments
File-level comment, Patchset 1 (Latest):
Robert Liao . resolved

Adding mmentovai for a Mac question.

File ui/views/controls/menu/menu_controller.cc
Line 107, Patchset 1 (Latest): // Only trigger menu cancellation on key press, not on key release.
// This prevents menus from closing when users release modifier keys after
// opening the menu with a keyboard shortcut (e.g., Cmd+Ctrl+Comma).
if (accelerator.key_state() == ui::Accelerator::KeyState::RELEASED) {
return false;
}
Robert Liao . unresolved

@mmen...@chromium.org - Do you know if any Mac menus will break if this is introduced? (I can't think of any on my cursory check).

File ui/views/controls/menu/menu_controller_unittest.cc
Line 3389, Patchset 1 (Latest):// menu. This prevents the menu from flashing open and immediately closing when
// users release keys after opening a menu with a keyboard shortcut (e.g.,
// Cmd+Ctrl+Comma).
Robert Liao . unresolved

I don't believe Chromium has this behavior, so you'll want to use a different scenario to illustrate the point.

Line 3396, Patchset 1 (Latest): EXPECT_TRUE(showing());
Robert Liao . unresolved

Change to `ASSERT_TRUE`. If this check fails, there's no need to continue the test.

Line 3400, Patchset 1 (Latest): // Cmd+Ctrl+Comma. This should NOT cancel the menu.
Robert Liao . unresolved

Chromium doesn't use this key combo, so it's not clear what this is testing. Recommend choosing a different key combination.

Line 3420, Patchset 1 (Latest): // Verify that pressing a new accelerator still closes the menu.
// Press Cmd+T (New Tab) - this SHOULD close the menu.
ui::KeyEvent press_t(ui::EventType::kKeyPressed, ui::VKEY_T,
ui::EF_COMMAND_DOWN);
menu_controller()->OnWillDispatchKeyEvent(&press_t);
EXPECT_FALSE(showing());
Robert Liao . unresolved

Move this into a separate test as it's testing something different.

Open in Gerrit

Related details

Attention is currently required from:
  • Yuanjun Zhu
  • liang zeng
Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: Ic8b7f673ad0c8351d170d1b68b75f301bc2436e3
    Gerrit-Change-Number: 7408739
    Gerrit-PatchSet: 1
    Gerrit-Owner: liang zeng <lian...@microsoft.com>
    Gerrit-Reviewer: Robert Liao <rob...@chromium.org>
    Gerrit-Reviewer: Yuanjun Zhu <yuanj...@microsoft.com>
    Gerrit-Reviewer: liang zeng <lian...@microsoft.com>
    Gerrit-CC: Chromium UI Views Reviews <chromium-ui-...@google.com>
    Gerrit-CC: gwsq
    Gerrit-Attention: liang zeng <lian...@microsoft.com>
    Gerrit-Attention: Yuanjun Zhu <yuanj...@microsoft.com>
    Gerrit-Comment-Date: Mon, 12 Jan 2026 22:39:58 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    liang zeng (Gerrit)

    unread,
    Jan 12, 2026, 7:56:36 PM (5 days ago) Jan 12
    to Chromium UI Views Reviews, Robert Liao, Chromium LUCI CQ, Yuanjun Zhu, AyeAye, chromium...@chromium.org, mmen...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
    Attention needed from Robert Liao and Yuanjun Zhu

    liang zeng added 1 comment

    File ui/views/controls/menu/menu_controller_unittest.cc
    Line 3420, Patchset 1 (Latest): // Verify that pressing a new accelerator still closes the menu.
    // Press Cmd+T (New Tab) - this SHOULD close the menu.
    ui::KeyEvent press_t(ui::EventType::kKeyPressed, ui::VKEY_T,
    ui::EF_COMMAND_DOWN);
    menu_controller()->OnWillDispatchKeyEvent(&press_t);
    EXPECT_FALSE(showing());
    Robert Liao . resolved

    Move this into a separate test as it's testing something different.

    liang zeng

    This is necessary because we need to confirm that pressing other shortcut keys (such as "Cmd+T") will close the menu correctly.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Robert Liao
    • Yuanjun Zhu
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: Ic8b7f673ad0c8351d170d1b68b75f301bc2436e3
    Gerrit-Change-Number: 7408739
    Gerrit-PatchSet: 1
    Gerrit-Owner: liang zeng <lian...@microsoft.com>
    Gerrit-Reviewer: Robert Liao <rob...@chromium.org>
    Gerrit-Reviewer: Yuanjun Zhu <yuanj...@microsoft.com>
    Gerrit-Reviewer: liang zeng <lian...@microsoft.com>
    Gerrit-CC: Chromium UI Views Reviews <chromium-ui-...@google.com>
    Gerrit-CC: gwsq
    Gerrit-Attention: Robert Liao <rob...@chromium.org>
    Gerrit-Attention: Yuanjun Zhu <yuanj...@microsoft.com>
    Gerrit-Comment-Date: Tue, 13 Jan 2026 00:56:28 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Robert Liao <rob...@chromium.org>
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Robert Liao (Gerrit)

    unread,
    Jan 12, 2026, 7:59:56 PM (5 days ago) Jan 12
    to liang zeng, Mark Mentovai, Chromium UI Views Reviews, Chromium LUCI CQ, Yuanjun Zhu, AyeAye, chromium...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
    Attention needed from Mark Mentovai, Yuanjun Zhu and liang zeng

    Robert Liao added 2 comments

    File ui/views/controls/menu/menu_controller.cc
    Line 107, Patchset 1 (Latest): // Only trigger menu cancellation on key press, not on key release.
    // This prevents menus from closing when users release modifier keys after
    // opening the menu with a keyboard shortcut (e.g., Cmd+Ctrl+Comma).
    if (accelerator.key_state() == ui::Accelerator::KeyState::RELEASED) {
    return false;
    }
    Robert Liao . unresolved

    @mmen...@chromium.org - Do you know if any Mac menus will break if this is introduced? (I can't think of any on my cursory check).

    Robert Liao

    Fixing to @ma...@chromium.org - Do you know if any Mac menus will break if this is introduced? (I can't think of any on my cursory check).

    File ui/views/controls/menu/menu_controller_unittest.cc
    Line 3420, Patchset 1 (Latest): // Verify that pressing a new accelerator still closes the menu.
    // Press Cmd+T (New Tab) - this SHOULD close the menu.
    ui::KeyEvent press_t(ui::EventType::kKeyPressed, ui::VKEY_T,
    ui::EF_COMMAND_DOWN);
    menu_controller()->OnWillDispatchKeyEvent(&press_t);
    EXPECT_FALSE(showing());
    Robert Liao . unresolved

    Move this into a separate test as it's testing something different.

    liang zeng

    This is necessary because we need to confirm that pressing other shortcut keys (such as "Cmd+T") will close the menu correctly.

    Robert Liao

    That's fine. This behavior is independent of the preceding sequence, correct?

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Mark Mentovai
    • Yuanjun Zhu
    • liang zeng
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: Ic8b7f673ad0c8351d170d1b68b75f301bc2436e3
    Gerrit-Change-Number: 7408739
    Gerrit-PatchSet: 1
    Gerrit-Owner: liang zeng <lian...@microsoft.com>
    Gerrit-Reviewer: Mark Mentovai <ma...@chromium.org>
    Gerrit-Reviewer: Robert Liao <rob...@chromium.org>
    Gerrit-Reviewer: Yuanjun Zhu <yuanj...@microsoft.com>
    Gerrit-Reviewer: liang zeng <lian...@microsoft.com>
    Gerrit-CC: Chromium UI Views Reviews <chromium-ui-...@google.com>
    Gerrit-CC: gwsq
    Gerrit-Attention: liang zeng <lian...@microsoft.com>
    Gerrit-Attention: Mark Mentovai <ma...@chromium.org>
    Gerrit-Attention: Yuanjun Zhu <yuanj...@microsoft.com>
    Gerrit-Comment-Date: Tue, 13 Jan 2026 00:59:49 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: liang zeng <lian...@microsoft.com>
    Comment-In-Reply-To: Robert Liao <rob...@chromium.org>
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    liang zeng (Gerrit)

    unread,
    Jan 12, 2026, 10:48:05 PM (5 days ago) Jan 12
    to Mark Mentovai, Chromium UI Views Reviews, Robert Liao, Chromium LUCI CQ, Yuanjun Zhu, AyeAye, chromium...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
    Attention needed from Mark Mentovai, Robert Liao and Yuanjun Zhu

    liang zeng added 1 comment

    File ui/views/controls/menu/menu_controller_unittest.cc
    Line 3389, Patchset 1 (Latest):// menu. This prevents the menu from flashing open and immediately closing when
    // users release keys after opening a menu with a keyboard shortcut (e.g.,
    // Cmd+Ctrl+Comma).
    Robert Liao . unresolved

    I don't believe Chromium has this behavior, so you'll want to use a different scenario to illustrate the point.

    liang zeng

    Yes, I haven't found a corresponding shortcut to bring up the menu in Chromium yet, but using it (for example, in Edge) causes a bug. What do you suggest for the design of this test case? Or should we remove these changes first?

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Mark Mentovai
    • Robert Liao
    • Yuanjun Zhu
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: Ic8b7f673ad0c8351d170d1b68b75f301bc2436e3
    Gerrit-Change-Number: 7408739
    Gerrit-PatchSet: 1
    Gerrit-Owner: liang zeng <lian...@microsoft.com>
    Gerrit-Reviewer: Mark Mentovai <ma...@chromium.org>
    Gerrit-Reviewer: Robert Liao <rob...@chromium.org>
    Gerrit-Reviewer: Yuanjun Zhu <yuanj...@microsoft.com>
    Gerrit-Reviewer: liang zeng <lian...@microsoft.com>
    Gerrit-CC: Chromium UI Views Reviews <chromium-ui-...@google.com>
    Gerrit-CC: gwsq
    Gerrit-Attention: Robert Liao <rob...@chromium.org>
    Gerrit-Attention: Mark Mentovai <ma...@chromium.org>
    Gerrit-Attention: Yuanjun Zhu <yuanj...@microsoft.com>
    Gerrit-Comment-Date: Tue, 13 Jan 2026 03:47:40 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Robert Liao <rob...@chromium.org>
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Robert Liao (Gerrit)

    unread,
    Jan 14, 2026, 7:50:39 PM (3 days ago) Jan 14
    to liang zeng, Yuanjun Zhu, Mark Mentovai, Chromium UI Views Reviews, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
    Attention needed from Mark Mentovai and liang zeng

    Robert Liao added 1 comment

    File ui/views/controls/menu/menu_controller_unittest.cc
    Line 3389, Patchset 1 (Latest):// menu. This prevents the menu from flashing open and immediately closing when
    // users release keys after opening a menu with a keyboard shortcut (e.g.,
    // Cmd+Ctrl+Comma).
    Robert Liao . unresolved

    I don't believe Chromium has this behavior, so you'll want to use a different scenario to illustrate the point.

    liang zeng

    Yes, I haven't found a corresponding shortcut to bring up the menu in Chromium yet, but using it (for example, in Edge) causes a bug. What do you suggest for the design of this test case? Or should we remove these changes first?

    Robert Liao

    I think in this case, you should genericize the test case to an arbitrary key shortcut. The issue still stands that if Chromium were to bring up a menu with a shortcut, it would immediately dismiss.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Mark Mentovai
    • liang zeng
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: Ic8b7f673ad0c8351d170d1b68b75f301bc2436e3
    Gerrit-Change-Number: 7408739
    Gerrit-PatchSet: 1
    Gerrit-Owner: liang zeng <lian...@microsoft.com>
    Gerrit-Reviewer: Mark Mentovai <ma...@chromium.org>
    Gerrit-Reviewer: Robert Liao <rob...@chromium.org>
    Gerrit-Reviewer: liang zeng <lian...@microsoft.com>
    Gerrit-CC: Chromium UI Views Reviews <chromium-ui-...@google.com>
    Gerrit-CC: Yuanjun Zhu <yuanj...@microsoft.com>
    Gerrit-CC: gwsq
    Gerrit-Attention: liang zeng <lian...@microsoft.com>
    Gerrit-Attention: Mark Mentovai <ma...@chromium.org>
    Gerrit-Comment-Date: Thu, 15 Jan 2026 00:50:30 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    liang zeng (Gerrit)

    unread,
    Jan 15, 2026, 10:37:44 PM (2 days ago) Jan 15
    to Yuanjun Zhu, Mark Mentovai, Chromium UI Views Reviews, Robert Liao, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
    Attention needed from Mark Mentovai and Robert Liao

    New activity on the change

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Mark Mentovai
    • Robert Liao
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: Ic8b7f673ad0c8351d170d1b68b75f301bc2436e3
    Gerrit-Change-Number: 7408739
    Gerrit-PatchSet: 2
    Gerrit-Owner: liang zeng <lian...@microsoft.com>
    Gerrit-Reviewer: Mark Mentovai <ma...@chromium.org>
    Gerrit-Reviewer: Robert Liao <rob...@chromium.org>
    Gerrit-Reviewer: liang zeng <lian...@microsoft.com>
    Gerrit-CC: Chromium UI Views Reviews <chromium-ui-...@google.com>
    Gerrit-CC: Yuanjun Zhu <yuanj...@microsoft.com>
    Gerrit-CC: gwsq
    Gerrit-Attention: Robert Liao <rob...@chromium.org>
    Gerrit-Attention: Mark Mentovai <ma...@chromium.org>
    Gerrit-Comment-Date: Fri, 16 Jan 2026 03:37:02 +0000
    Gerrit-HasComments: No
    Gerrit-Has-Labels: No
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    liang zeng (Gerrit)

    unread,
    Jan 15, 2026, 11:08:00 PM (2 days ago) Jan 15
    to Yuanjun Zhu, Mark Mentovai, Chromium UI Views Reviews, Robert Liao, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
    Attention needed from Mark Mentovai and Robert Liao

    liang zeng added 4 comments

    File ui/views/controls/menu/menu_controller_unittest.cc
    Line 3389, Patchset 1:// menu. This prevents the menu from flashing open and immediately closing when

    // users release keys after opening a menu with a keyboard shortcut (e.g.,
    // Cmd+Ctrl+Comma).
    Robert Liao . resolved

    I don't believe Chromium has this behavior, so you'll want to use a different scenario to illustrate the point.

    liang zeng

    Yes, I haven't found a corresponding shortcut to bring up the menu in Chromium yet, but using it (for example, in Edge) causes a bug. What do you suggest for the design of this test case? Or should we remove these changes first?

    Robert Liao

    I think in this case, you should genericize the test case to an arbitrary key shortcut. The issue still stands that if Chromium were to bring up a menu with a shortcut, it would immediately dismiss.

    liang zeng

    Updated the test case and comments.

    Line 3396, Patchset 1: EXPECT_TRUE(showing());
    Robert Liao . resolved

    Change to `ASSERT_TRUE`. If this check fails, there's no need to continue the test.

    liang zeng

    Fixed, thanks.

    Line 3400, Patchset 1: // Cmd+Ctrl+Comma. This should NOT cancel the menu.
    Robert Liao . resolved

    Chromium doesn't use this key combo, so it's not clear what this is testing. Recommend choosing a different key combination.

    liang zeng

    Updated, thanks.

    Line 3420, Patchset 1: // Verify that pressing a new accelerator still closes the menu.

    // Press Cmd+T (New Tab) - this SHOULD close the menu.
    ui::KeyEvent press_t(ui::EventType::kKeyPressed, ui::VKEY_T,
    ui::EF_COMMAND_DOWN);
    menu_controller()->OnWillDispatchKeyEvent(&press_t);
    EXPECT_FALSE(showing());
    Robert Liao . resolved

    Move this into a separate test as it's testing something different.

    liang zeng

    This is necessary because we need to confirm that pressing other shortcut keys (such as "Cmd+T") will close the menu correctly.

    Robert Liao

    That's fine. This behavior is independent of the preceding sequence, correct?

    liang zeng

    Moved this to case `KeyPressWithModifierCancelsMenu`

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Mark Mentovai
    • Robert Liao
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: Ic8b7f673ad0c8351d170d1b68b75f301bc2436e3
    Gerrit-Change-Number: 7408739
    Gerrit-PatchSet: 4
    Gerrit-Owner: liang zeng <lian...@microsoft.com>
    Gerrit-Reviewer: Mark Mentovai <ma...@chromium.org>
    Gerrit-Reviewer: Robert Liao <rob...@chromium.org>
    Gerrit-Reviewer: liang zeng <lian...@microsoft.com>
    Gerrit-CC: Chromium UI Views Reviews <chromium-ui-...@google.com>
    Gerrit-CC: Yuanjun Zhu <yuanj...@microsoft.com>
    Gerrit-CC: gwsq
    Gerrit-Attention: Robert Liao <rob...@chromium.org>
    Gerrit-Attention: Mark Mentovai <ma...@chromium.org>
    Gerrit-Comment-Date: Fri, 16 Jan 2026 04:07:50 +0000
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    liang zeng (Gerrit)

    unread,
    Jan 15, 2026, 11:09:51 PM (2 days ago) Jan 15
    to Yuanjun Zhu, Mark Mentovai, Chromium UI Views Reviews, Robert Liao, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
    Attention needed from Mark Mentovai and Robert Liao

    liang zeng added 1 comment

    File ui/views/controls/menu/menu_controller.cc
    Line 107, Patchset 1: // Only trigger menu cancellation on key press, not on key release.

    // This prevents menus from closing when users release modifier keys after
    // opening the menu with a keyboard shortcut (e.g., Cmd+Ctrl+Comma).
    if (accelerator.key_state() == ui::Accelerator::KeyState::RELEASED) {
    return false;
    }
    Robert Liao . unresolved

    @mmen...@chromium.org - Do you know if any Mac menus will break if this is introduced? (I can't think of any on my cursory check).

    Robert Liao

    Fixing to @ma...@chromium.org - Do you know if any Mac menus will break if this is introduced? (I can't think of any on my cursory check).

    liang zeng

    Hi @ma...@chromium.org could you help to review this change?

    Gerrit-Comment-Date: Fri, 16 Jan 2026 04:09:39 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Robert Liao <rob...@chromium.org>
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    liang zeng (Gerrit)

    unread,
    Jan 16, 2026, 12:15:01 AM (yesterday) Jan 16
    to Avi Drissman, Yuanjun Zhu, Mark Mentovai, Chromium UI Views Reviews, Robert Liao, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
    Attention needed from Avi Drissman, Mark Mentovai and Robert Liao

    liang zeng voted Commit-Queue+1

    Commit-Queue+1
    Open in Gerrit

    Related details

    Attention is currently required from:
    • Avi Drissman
    • Mark Mentovai
    • Robert Liao
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: Ic8b7f673ad0c8351d170d1b68b75f301bc2436e3
    Gerrit-Change-Number: 7408739
    Gerrit-PatchSet: 6
    Gerrit-Owner: liang zeng <lian...@microsoft.com>
    Gerrit-Reviewer: Avi Drissman <a...@chromium.org>
    Gerrit-Reviewer: Mark Mentovai <ma...@chromium.org>
    Gerrit-Reviewer: Robert Liao <rob...@chromium.org>
    Gerrit-Reviewer: liang zeng <lian...@microsoft.com>
    Gerrit-CC: Chromium UI Views Reviews <chromium-ui-...@google.com>
    Gerrit-CC: Yuanjun Zhu <yuanj...@microsoft.com>
    Gerrit-CC: gwsq
    Gerrit-Attention: Robert Liao <rob...@chromium.org>
    Gerrit-Attention: Mark Mentovai <ma...@chromium.org>
    Gerrit-Attention: Avi Drissman <a...@chromium.org>
    Gerrit-Comment-Date: Fri, 16 Jan 2026 05:14:31 +0000
    Gerrit-HasComments: No
    Gerrit-Has-Labels: Yes
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Mark Mentovai (Gerrit)

    unread,
    Jan 16, 2026, 10:50:14 AM (yesterday) Jan 16
    to liang zeng, Avi Drissman, Yuanjun Zhu, Chromium UI Views Reviews, Robert Liao, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
    Attention needed from Avi Drissman, Robert Liao and liang zeng

    Mark Mentovai voted and added 1 comment

    Votes added by Mark Mentovai

    Code-Review+1

    1 comment

    File ui/views/controls/menu/menu_controller.cc
    Line 107, Patchset 1: // Only trigger menu cancellation on key press, not on key release.
    // This prevents menus from closing when users release modifier keys after
    // opening the menu with a keyboard shortcut (e.g., Cmd+Ctrl+Comma).
    if (accelerator.key_state() == ui::Accelerator::KeyState::RELEASED) {
    return false;
    }
    Robert Liao . unresolved

    @mmen...@chromium.org - Do you know if any Mac menus will break if this is introduced? (I can't think of any on my cursory check).

    Robert Liao

    Fixing to @ma...@chromium.org - Do you know if any Mac menus will break if this is introduced? (I can't think of any on my cursory check).

    liang zeng

    Hi @ma...@chromium.org could you help to review this change?

    Mark Mentovai

    I think that this is correct.

    Avi’s listed as a reviewer too, maybe he can brainstorm something?

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Avi Drissman
    • Robert Liao
    • liang zeng
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: Ic8b7f673ad0c8351d170d1b68b75f301bc2436e3
    Gerrit-Change-Number: 7408739
    Gerrit-PatchSet: 7
    Gerrit-Owner: liang zeng <lian...@microsoft.com>
    Gerrit-Reviewer: Avi Drissman <a...@chromium.org>
    Gerrit-Reviewer: Mark Mentovai <ma...@chromium.org>
    Gerrit-Reviewer: Robert Liao <rob...@chromium.org>
    Gerrit-Reviewer: liang zeng <lian...@microsoft.com>
    Gerrit-CC: Chromium UI Views Reviews <chromium-ui-...@google.com>
    Gerrit-CC: Yuanjun Zhu <yuanj...@microsoft.com>
    Gerrit-CC: gwsq
    Gerrit-Attention: liang zeng <lian...@microsoft.com>
    Gerrit-Attention: Robert Liao <rob...@chromium.org>
    Gerrit-Attention: Avi Drissman <a...@chromium.org>
    Gerrit-Comment-Date: Fri, 16 Jan 2026 15:50:06 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: Yes
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Avi Drissman (Gerrit)

    unread,
    Jan 16, 2026, 1:18:42 PM (22 hours ago) Jan 16
    to liang zeng, Avi Drissman, Mark Mentovai, Yuanjun Zhu, Chromium UI Views Reviews, Robert Liao, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
    Attention needed from Robert Liao and liang zeng

    Avi Drissman voted and added 1 comment

    Votes added by Avi Drissman

    Code-Review+1

    1 comment

    File ui/views/controls/menu/menu_controller.cc
    Line 107, Patchset 1: // Only trigger menu cancellation on key press, not on key release.
    // This prevents menus from closing when users release modifier keys after
    // opening the menu with a keyboard shortcut (e.g., Cmd+Ctrl+Comma).
    if (accelerator.key_state() == ui::Accelerator::KeyState::RELEASED) {
    return false;
    }
    Robert Liao . resolved

    @mmen...@chromium.org - Do you know if any Mac menus will break if this is introduced? (I can't think of any on my cursory check).

    Robert Liao

    Fixing to @ma...@chromium.org - Do you know if any Mac menus will break if this is introduced? (I can't think of any on my cursory check).

    liang zeng

    Hi @ma...@chromium.org could you help to review this change?

    Mark Mentovai

    I think that this is correct.

    Avi’s listed as a reviewer too, maybe he can brainstorm something?

    Avi Drissman

    This seems right to me. I’m actually wondering if we shouldn’t go further. Why do purely modifier-only keyup/downs cancel menus? I don’t believe they do so for native menus.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Robert Liao
    • liang zeng
    Submit Requirements:
      • requirement satisfiedCode-Coverage
      • requirement is not satisfiedCode-Owners
      • requirement satisfiedCode-Review
      • requirement satisfiedReview-Enforcement
      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
      Gerrit-MessageType: comment
      Gerrit-Project: chromium/src
      Gerrit-Branch: main
      Gerrit-Change-Id: Ic8b7f673ad0c8351d170d1b68b75f301bc2436e3
      Gerrit-Change-Number: 7408739
      Gerrit-PatchSet: 7
      Gerrit-Owner: liang zeng <lian...@microsoft.com>
      Gerrit-Reviewer: Avi Drissman <a...@chromium.org>
      Gerrit-Reviewer: Mark Mentovai <ma...@chromium.org>
      Gerrit-Reviewer: Robert Liao <rob...@chromium.org>
      Gerrit-Reviewer: liang zeng <lian...@microsoft.com>
      Gerrit-CC: Chromium UI Views Reviews <chromium-ui-...@google.com>
      Gerrit-CC: Yuanjun Zhu <yuanj...@microsoft.com>
      Gerrit-CC: gwsq
      Gerrit-Attention: liang zeng <lian...@microsoft.com>
      Gerrit-Attention: Robert Liao <rob...@chromium.org>
      Gerrit-Comment-Date: Fri, 16 Jan 2026 18:18:34 +0000
      Gerrit-HasComments: Yes
      Gerrit-Has-Labels: Yes
      Comment-In-Reply-To: liang zeng <lian...@microsoft.com>
      Comment-In-Reply-To: Mark Mentovai <ma...@chromium.org>
      Comment-In-Reply-To: Robert Liao <rob...@chromium.org>
      satisfied_requirement
      unsatisfied_requirement
      open
      diffy

      liang zeng (Gerrit)

      unread,
      Jan 16, 2026, 3:01:07 PM (20 hours ago) Jan 16
      to Avi Drissman, Mark Mentovai, Yuanjun Zhu, Chromium UI Views Reviews, Robert Liao, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
      Attention needed from Robert Liao

      liang zeng added 1 comment

      File ui/views/controls/menu/menu_controller.cc
      Line 107, Patchset 1: // Only trigger menu cancellation on key press, not on key release.
      // This prevents menus from closing when users release modifier keys after
      // opening the menu with a keyboard shortcut (e.g., Cmd+Ctrl+Comma).
      if (accelerator.key_state() == ui::Accelerator::KeyState::RELEASED) {
      return false;
      }
      Robert Liao . resolved

      @mmen...@chromium.org - Do you know if any Mac menus will break if this is introduced? (I can't think of any on my cursory check).

      Robert Liao

      Fixing to @ma...@chromium.org - Do you know if any Mac menus will break if this is introduced? (I can't think of any on my cursory check).

      liang zeng

      Hi @ma...@chromium.org could you help to review this change?

      Mark Mentovai

      I think that this is correct.

      Avi’s listed as a reviewer too, maybe he can brainstorm something?

      Avi Drissman

      This seems right to me. I’m actually wondering if we shouldn’t go further. Why do purely modifier-only keyup/downs cancel menus? I don’t believe they do so for native menus.

      liang zeng

      Yes, it only affects view-based menus on Mac.

      Open in Gerrit

      Related details

      Attention is currently required from:
      • Robert Liao
      Submit Requirements:
      • requirement satisfiedCode-Coverage
      • requirement is not satisfiedCode-Owners
      • requirement satisfiedCode-Review
      • requirement satisfiedReview-Enforcement
      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
      Gerrit-MessageType: comment
      Gerrit-Project: chromium/src
      Gerrit-Branch: main
      Gerrit-Change-Id: Ic8b7f673ad0c8351d170d1b68b75f301bc2436e3
      Gerrit-Change-Number: 7408739
      Gerrit-PatchSet: 7
      Gerrit-Owner: liang zeng <lian...@microsoft.com>
      Gerrit-Reviewer: Avi Drissman <a...@chromium.org>
      Gerrit-Reviewer: Mark Mentovai <ma...@chromium.org>
      Gerrit-Reviewer: Robert Liao <rob...@chromium.org>
      Gerrit-Reviewer: liang zeng <lian...@microsoft.com>
      Gerrit-CC: Chromium UI Views Reviews <chromium-ui-...@google.com>
      Gerrit-CC: Yuanjun Zhu <yuanj...@microsoft.com>
      Gerrit-CC: gwsq
      Gerrit-Attention: Robert Liao <rob...@chromium.org>
      Gerrit-Comment-Date: Fri, 16 Jan 2026 20:00:32 +0000
      Gerrit-HasComments: Yes
      Gerrit-Has-Labels: No
      Comment-In-Reply-To: liang zeng <lian...@microsoft.com>
      Comment-In-Reply-To: Mark Mentovai <ma...@chromium.org>
      Comment-In-Reply-To: Robert Liao <rob...@chromium.org>
      Comment-In-Reply-To: Avi Drissman <a...@chromium.org>
      satisfied_requirement
      unsatisfied_requirement
      open
      diffy

      Avi Drissman (Gerrit)

      unread,
      Jan 16, 2026, 3:16:32 PM (20 hours ago) Jan 16
      to liang zeng, Avi Drissman, Mark Mentovai, Yuanjun Zhu, Chromium UI Views Reviews, Robert Liao, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
      Attention needed from Robert Liao and liang zeng

      Avi Drissman added 1 comment

      File ui/views/controls/menu/menu_controller.cc
      Line 107, Patchset 1: // Only trigger menu cancellation on key press, not on key release.
      // This prevents menus from closing when users release modifier keys after
      // opening the menu with a keyboard shortcut (e.g., Cmd+Ctrl+Comma).
      if (accelerator.key_state() == ui::Accelerator::KeyState::RELEASED) {
      return false;
      }
      Robert Liao . resolved

      @mmen...@chromium.org - Do you know if any Mac menus will break if this is introduced? (I can't think of any on my cursory check).

      Robert Liao

      Fixing to @ma...@chromium.org - Do you know if any Mac menus will break if this is introduced? (I can't think of any on my cursory check).

      liang zeng

      Hi @ma...@chromium.org could you help to review this change?

      Mark Mentovai

      I think that this is correct.

      Avi’s listed as a reviewer too, maybe he can brainstorm something?

      Avi Drissman

      This seems right to me. I’m actually wondering if we shouldn’t go further. Why do purely modifier-only keyup/downs cancel menus? I don’t believe they do so for native menus.

      liang zeng

      Yes, it only affects view-based menus on Mac.

      Avi Drissman

      When we built MacViews, we tried to align with native Mac behavior whenever feasible. I appreciate that in this change, you’re trying to make minimal changes, but I’d say that as a future change (not necessarily in this CL) I’d be OK with completely ignoring modifier changes, both key up and key down, on the Mac, assuming it didn’t break anything.

      In any case, happy to see this CL land as-is to unbreak Edge.

      Open in Gerrit

      Related details

      Attention is currently required from:
      • Robert Liao
      • liang zeng
      Submit Requirements:
      • requirement satisfiedCode-Coverage
      • requirement is not satisfiedCode-Owners
      • requirement satisfiedCode-Review
      • requirement satisfiedReview-Enforcement
      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
      Gerrit-MessageType: comment
      Gerrit-Project: chromium/src
      Gerrit-Branch: main
      Gerrit-Change-Id: Ic8b7f673ad0c8351d170d1b68b75f301bc2436e3
      Gerrit-Change-Number: 7408739
      Gerrit-PatchSet: 7
      Gerrit-Owner: liang zeng <lian...@microsoft.com>
      Gerrit-Reviewer: Avi Drissman <a...@chromium.org>
      Gerrit-Reviewer: Mark Mentovai <ma...@chromium.org>
      Gerrit-Reviewer: Robert Liao <rob...@chromium.org>
      Gerrit-Reviewer: liang zeng <lian...@microsoft.com>
      Gerrit-CC: Chromium UI Views Reviews <chromium-ui-...@google.com>
      Gerrit-CC: Yuanjun Zhu <yuanj...@microsoft.com>
      Gerrit-CC: gwsq
      Gerrit-Attention: liang zeng <lian...@microsoft.com>
      Gerrit-Attention: Robert Liao <rob...@chromium.org>
      Gerrit-Comment-Date: Fri, 16 Jan 2026 20:16:25 +0000
      satisfied_requirement
      unsatisfied_requirement
      open
      diffy

      Robert Liao (Gerrit)

      unread,
      Jan 16, 2026, 8:19:40 PM (15 hours ago) Jan 16
      to liang zeng, Avi Drissman, Mark Mentovai, Yuanjun Zhu, Chromium UI Views Reviews, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
      Attention needed from liang zeng

      Robert Liao voted and added 1 comment

      Votes added by Robert Liao

      Code-Review+1

      1 comment

      Patchset-level comments
      File-level comment, Patchset 7 (Latest):
      Robert Liao . resolved

      Thanks for working through the review!

      Open in Gerrit

      Related details

      Attention is currently required from:
      • liang zeng
      Submit Requirements:
      • requirement satisfiedCode-Coverage
      • requirement satisfiedCode-Owners
      • requirement satisfiedCode-Review
      • requirement satisfiedReview-Enforcement
      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
      Gerrit-MessageType: comment
      Gerrit-Project: chromium/src
      Gerrit-Branch: main
      Gerrit-Change-Id: Ic8b7f673ad0c8351d170d1b68b75f301bc2436e3
      Gerrit-Change-Number: 7408739
      Gerrit-PatchSet: 7
      Gerrit-Owner: liang zeng <lian...@microsoft.com>
      Gerrit-Reviewer: Avi Drissman <a...@chromium.org>
      Gerrit-Reviewer: Mark Mentovai <ma...@chromium.org>
      Gerrit-Reviewer: Robert Liao <rob...@chromium.org>
      Gerrit-Reviewer: liang zeng <lian...@microsoft.com>
      Gerrit-CC: Chromium UI Views Reviews <chromium-ui-...@google.com>
      Gerrit-CC: Yuanjun Zhu <yuanj...@microsoft.com>
      Gerrit-CC: gwsq
      Gerrit-Attention: liang zeng <lian...@microsoft.com>
      Gerrit-Comment-Date: Sat, 17 Jan 2026 01:19:31 +0000
      Gerrit-HasComments: Yes
      Gerrit-Has-Labels: Yes
      satisfied_requirement
      open
      diffy

      Robert Liao (Gerrit)

      unread,
      Jan 16, 2026, 8:20:17 PM (15 hours ago) Jan 16
      to liang zeng, Avi Drissman, Mark Mentovai, Yuanjun Zhu, Chromium UI Views Reviews, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, roblia...@chromium.org, sky+...@chromium.org
      Attention needed from liang zeng

      Robert Liao voted Commit-Queue+2

      Commit-Queue+2
      Gerrit-Comment-Date: Sat, 17 Jan 2026 01:20:04 +0000
      Gerrit-HasComments: No
      Gerrit-Has-Labels: Yes
      satisfied_requirement
      open
      diffy

      Chromium LUCI CQ (Gerrit)

      unread,
      Jan 16, 2026, 8:30:24 PM (14 hours ago) Jan 16
      to liang zeng, Robert Liao, Avi Drissman, Mark Mentovai, Yuanjun Zhu, Chromium UI Views Reviews, AyeAye, chromium...@chromium.org, roblia...@chromium.org, sky+...@chromium.org

      Chromium LUCI CQ submitted the change

      Change information

      Commit message:
      [Mac] Fix menu closing immediately after opening with keyboard shortcuts

      When opening menus with keyboard shortcuts containing multiple
      modifiers, the menu would flash open and immediately close when users
      released the keys. This made such shortcuts effectively unusable.

      Root Cause: The AcceleratorShouldCancelMenu() function on macOS was
      treating key release events the same as key press events. When users
      released keys after opening a menu, if any modifier (Cmd/Ctrl/Alt) was
      still held, the function would return true and close the menu.

      Fix: Add a check at the beginning of AcceleratorShouldCancelMenu() to
      only trigger menu cancellation on key press events, not key release
      events. This aligns with the semantic meaning of keyboard shortcuts -
      actions should be triggered on key press, not key release.

      The fix is minimal and targeted:
      - Only affects the menu closing behavior
      - Preserves existing functionality: pressing new shortcuts while a menu
      is open still correctly closes the menu
      - Prevents menus from closing when users simply release keys

      Testing: Added MenuControllerTest.KeyReleaseDoesNotCancelMenu to verify:
      1. Key release events (with modifiers) don't close menus 2. Key press
      events (with modifiers) still correctly close menus
      Bug: 474658713
      Change-Id: Ic8b7f673ad0c8351d170d1b68b75f301bc2436e3
      Reviewed-by: Robert Liao <rob...@chromium.org>
      Commit-Queue: Robert Liao <rob...@chromium.org>
      Reviewed-by: Mark Mentovai <ma...@chromium.org>
      Reviewed-by: Avi Drissman <a...@chromium.org>
      Cr-Commit-Position: refs/heads/main@{#1570709}
      Files:
      • M ui/views/controls/menu/menu_controller.cc
      • M ui/views/controls/menu/menu_controller_unittest.cc
      Change size: M
      Delta: 2 files changed, 57 insertions(+), 0 deletions(-)
      Branch: refs/heads/main
      Submit Requirements:
      • requirement satisfiedCode-Review: +1 by Mark Mentovai, +1 by Avi Drissman, +1 by Robert Liao
      Open in Gerrit
      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
      Gerrit-MessageType: merged
      Gerrit-Project: chromium/src
      Gerrit-Branch: main
      Gerrit-Change-Id: Ic8b7f673ad0c8351d170d1b68b75f301bc2436e3
      Gerrit-Change-Number: 7408739
      Gerrit-PatchSet: 8
      Gerrit-Owner: liang zeng <lian...@microsoft.com>
      Gerrit-Reviewer: Avi Drissman <a...@chromium.org>
      Gerrit-Reviewer: Chromium LUCI CQ <chromiu...@luci-project-accounts.iam.gserviceaccount.com>
      Gerrit-Reviewer: Mark Mentovai <ma...@chromium.org>
      Gerrit-Reviewer: Robert Liao <rob...@chromium.org>
      Gerrit-Reviewer: liang zeng <lian...@microsoft.com>
      open
      diffy
      satisfied_requirement

      liang zeng (Gerrit)

      unread,
      3:11 AM (8 hours ago) 3:11 AM
      to Chromium LUCI CQ, Robert Liao, Avi Drissman, Mark Mentovai, Yuanjun Zhu, Chromium UI Views Reviews, AyeAye, chromium...@chromium.org, roblia...@chromium.org, sky+...@chromium.org

      liang zeng added 1 comment

      File ui/views/controls/menu/menu_controller.cc
      Line 107, Patchset 1: // Only trigger menu cancellation on key press, not on key release.
      // This prevents menus from closing when users release modifier keys after
      // opening the menu with a keyboard shortcut (e.g., Cmd+Ctrl+Comma).
      if (accelerator.key_state() == ui::Accelerator::KeyState::RELEASED) {
      return false;
      }
      Robert Liao . resolved

      @mmen...@chromium.org - Do you know if any Mac menus will break if this is introduced? (I can't think of any on my cursory check).

      Robert Liao

      Fixing to @ma...@chromium.org - Do you know if any Mac menus will break if this is introduced? (I can't think of any on my cursory check).

      liang zeng

      Hi @ma...@chromium.org could you help to review this change?

      Mark Mentovai

      I think that this is correct.

      Avi’s listed as a reviewer too, maybe he can brainstorm something?

      Avi Drissman

      This seems right to me. I’m actually wondering if we shouldn’t go further. Why do purely modifier-only keyup/downs cancel menus? I don’t believe they do so for native menus.

      liang zeng

      Yes, it only affects view-based menus on Mac.

      Avi Drissman

      When we built MacViews, we tried to align with native Mac behavior whenever feasible. I appreciate that in this change, you’re trying to make minimal changes, but I’d say that as a future change (not necessarily in this CL) I’d be OK with completely ignoring modifier changes, both key up and key down, on the Mac, assuming it didn’t break anything.

      In any case, happy to see this CL land as-is to unbreak Edge.

      liang zeng

      Very good suggestion, thank you!

      Open in Gerrit

      Related details

      Attention set is empty
      Submit Requirements:
      • requirement satisfiedCode-Coverage
      • requirement satisfiedCode-Owners
      • requirement satisfiedCode-Review
      • requirement satisfiedReview-Enforcement
      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
      Gerrit-MessageType: comment
      Gerrit-Project: chromium/src
      Gerrit-Branch: main
      Gerrit-Change-Id: Ic8b7f673ad0c8351d170d1b68b75f301bc2436e3
      Gerrit-Change-Number: 7408739
      Gerrit-PatchSet: 8
      Gerrit-Owner: liang zeng <lian...@microsoft.com>
      Gerrit-Reviewer: Avi Drissman <a...@chromium.org>
      Gerrit-Reviewer: Chromium LUCI CQ <chromiu...@luci-project-accounts.iam.gserviceaccount.com>
      Gerrit-Reviewer: Mark Mentovai <ma...@chromium.org>
      Gerrit-Reviewer: Robert Liao <rob...@chromium.org>
      Gerrit-Reviewer: liang zeng <lian...@microsoft.com>
      Gerrit-CC: Chromium UI Views Reviews <chromium-ui-...@google.com>
      Gerrit-CC: Yuanjun Zhu <yuanj...@microsoft.com>
      Gerrit-CC: gwsq
      Gerrit-Comment-Date: Sat, 17 Jan 2026 08:11:32 +0000
      satisfied_requirement
      open
      diffy
      Reply all
      Reply to author
      Forward
      0 new messages