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

Unified Diff: ash/common/shelf/shelf_controller.cc

Issue 2716403005: mash: Remove shelf app menu item objects. (Closed)
Patch Set: Address comments. Created 3 years, 10 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/common/shelf/shelf_application_menu_model_unittest.cc ('k') | ash/common/shelf/shelf_item_delegate.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/common/shelf/shelf_controller.cc
diff --git a/ash/common/shelf/shelf_controller.cc b/ash/common/shelf/shelf_controller.cc
index 4e836733547918329d161f98472c4fde6acf87c8..5e5fc6e1dce2e23404cab8a1158b620b66ae2b2e 100644
--- a/ash/common/shelf/shelf_controller.cc
+++ b/ash/common/shelf/shelf_controller.cc
@@ -71,12 +71,13 @@ class ShelfItemDelegateMus : public ShelfItemDelegate {
}
ShelfAppMenuItemList GetAppMenuItems(int event_flags) override {
- ShelfAppMenuItemList items;
- for (const auto& window : window_id_to_title_) {
- items.push_back(
- base::MakeUnique<ShelfApplicationMenuItem>(window.second));
- }
- return items;
+ // Return an empty item list to avoid showing an application menu.
+ return ShelfAppMenuItemList();
+ }
+
+ void ExecuteCommand(uint32_t command_id, int event_flags) override {
+ // This delegate does not support showing an application menu.
+ NOTIMPLEMENTED();
}
void Close() override { NOTIMPLEMENTED(); }
« no previous file with comments | « ash/common/shelf/shelf_application_menu_model_unittest.cc ('k') | ash/common/shelf/shelf_item_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698