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

chore: drop unresponsive suppressor for menus #35498

Merged
merged 3 commits into from Aug 31, 2022
Merged
Show file tree
Hide file tree
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
2 changes: 0 additions & 2 deletions shell/browser/api/electron_api_menu_mac.mm
Expand Up @@ -14,7 +14,6 @@
#include "content/public/browser/browser_thread.h"
#include "content/public/browser/web_contents.h"
#include "shell/browser/native_window.h"
#include "shell/browser/unresponsive_suppressor.h"
#include "shell/common/keyboard_util.h"
#include "shell/common/node_includes.h"

Expand Down Expand Up @@ -156,7 +155,6 @@
base::mac::ScopedSendingEvent sendingEventScoper;

// Don't emit unresponsive event when showing menu.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can be removed too.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See #35507

electron::UnresponsiveSuppressor suppressor;
[menu popUpMenuPositioningItem:item atLocation:position inView:view];
}

Expand Down
4 changes: 0 additions & 4 deletions shell/browser/api/electron_api_menu_views.cc
Expand Up @@ -8,7 +8,6 @@
#include <utility>

#include "shell/browser/native_window_views.h"
#include "shell/browser/unresponsive_suppressor.h"
#include "ui/display/screen.h"

using views::MenuRunner;
Expand Down Expand Up @@ -39,9 +38,6 @@ void MenuViews::PopupAt(BaseWindow* window,

int flags = MenuRunner::CONTEXT_MENU | MenuRunner::HAS_MNEMONICS;

// Don't emit unresponsive event when showing menu.
electron::UnresponsiveSuppressor suppressor;

// Make sure the Menu object would not be garbage-collected until the callback
// has run.
base::OnceClosure callback_with_ref = BindSelfToClosure(std::move(callback));
Expand Down