Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(316)

Unified Diff: ash/shell/window_type_launcher.cc

Issue 2790773002: Cleanup MenuRunner API (Closed)
Patch Set: Rebase Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ash/shelf/shelf_view.cc ('k') | ash/shell_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/shell/window_type_launcher.cc
diff --git a/ash/shell/window_type_launcher.cc b/ash/shell/window_type_launcher.cc
index 564d0d118e60ef2b35cde597d8b4da0dfe8b8834..ab73191f85b8de910085f4fa0d92e32012d9d05b 100644
--- a/ash/shell/window_type_launcher.cc
+++ b/ash/shell/window_type_launcher.cc
@@ -328,14 +328,10 @@ void WindowTypeLauncher::ShowContextMenuForView(
base::ASCIIToUTF16("Toggle FullScreen"),
MenuItemView::NORMAL);
// MenuRunner takes ownership of root.
- menu_runner_.reset(new MenuRunner(root, MenuRunner::HAS_MNEMONICS |
- views::MenuRunner::CONTEXT_MENU |
- views::MenuRunner::ASYNC));
- if (menu_runner_->RunMenuAt(GetWidget(), NULL, gfx::Rect(point, gfx::Size()),
- views::MENU_ANCHOR_TOPLEFT,
- source_type) == MenuRunner::MENU_DELETED) {
- return;
- }
+ menu_runner_.reset(new MenuRunner(
+ root, MenuRunner::HAS_MNEMONICS | views::MenuRunner::CONTEXT_MENU));
+ menu_runner_->RunMenuAt(GetWidget(), NULL, gfx::Rect(point, gfx::Size()),
+ views::MENU_ANCHOR_TOPLEFT, source_type);
}
} // namespace shell
« no previous file with comments | « ash/shelf/shelf_view.cc ('k') | ash/shell_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698