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

Unified Diff: chrome/browser/ui/ash/launcher/launcher_application_menu_item_model.h

Issue 2671923002: mash: Cleanup ash shelf application menu code. (Closed)
Patch Set: Add 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
Index: chrome/browser/ui/ash/launcher/launcher_application_menu_item_model.h
diff --git a/chrome/browser/ui/ash/launcher/launcher_application_menu_item_model.h b/chrome/browser/ui/ash/launcher/launcher_application_menu_item_model.h
deleted file mode 100644
index ccc8c56ea5ddb018992592a76ced2b2c90255830..0000000000000000000000000000000000000000
--- a/chrome/browser/ui/ash/launcher/launcher_application_menu_item_model.h
+++ /dev/null
@@ -1,53 +0,0 @@
-// Copyright (c) 2012 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef CHROME_BROWSER_UI_ASH_LAUNCHER_LAUNCHER_APPLICATION_MENU_ITEM_MODEL_H_
-#define CHROME_BROWSER_UI_ASH_LAUNCHER_LAUNCHER_APPLICATION_MENU_ITEM_MODEL_H_
-
-#include <memory>
-#include <vector>
-
-#include "base/macros.h"
-#include "ui/base/models/simple_menu_model.h"
-
-class ChromeLauncherAppMenuItem;
-class LauncherApplicationMenuItemModelTestAPI;
-
-// A list of the elements which makes up a simple menu description.
-using ChromeLauncherAppMenuItems =
- std::vector<std::unique_ptr<ChromeLauncherAppMenuItem>>;
-
-// A menu model that builds the contents of a menu for a launcher item
-// containing a list of running applications.
-class LauncherApplicationMenuItemModel : public ui::SimpleMenuModel,
- public ui::SimpleMenuModel::Delegate {
- public:
- explicit LauncherApplicationMenuItemModel(
- ChromeLauncherAppMenuItems item_list);
- ~LauncherApplicationMenuItemModel() override;
-
- // Overridden from ui::SimpleMenuModel::Delegate:
- bool IsCommandIdChecked(int command_id) const override;
- bool IsCommandIdEnabled(int command_id) const override;
- void ExecuteCommand(int command_id, int event_flags) override;
-
- private:
- friend class LauncherApplicationMenuItemModelTestAPI;
-
- void Build();
-
- // Returns the number of menu items that are enabled.
- int GetNumMenuItemsEnabled() const;
-
- // Records UMA metrics when a menu item is selected.
- void RecordMenuItemSelectedMetrics(int command_id,
- int num_menu_items_enabled);
-
- // The list of menu items as returned from the launcher controller.
- ChromeLauncherAppMenuItems launcher_items_;
-
- DISALLOW_COPY_AND_ASSIGN(LauncherApplicationMenuItemModel);
-};
-
-#endif // CHROME_BROWSER_UI_ASH_LAUNCHER_LAUNCHER_APPLICATION_MENU_ITEM_MODEL_H_

Powered by Google App Engine
This is Rietveld 408576698