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

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

Issue 2791803002: mash: Move LauncherItemController to ash, rename ShelfItemDelegate. (Closed)
Patch Set: Move shelf_item_delegate to ash/public/cpp, cleanup. Created 3 years, 9 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/app_shortcut_launcher_item_controller.h
diff --git a/chrome/browser/ui/ash/launcher/app_shortcut_launcher_item_controller.h b/chrome/browser/ui/ash/launcher/app_shortcut_launcher_item_controller.h
index 6471578a3e35a1cc3482f64042e50dffac8f11d0..9ce8b1f93c3c0ec3e4e93a789da22edc4a39812b 100644
--- a/chrome/browser/ui/ash/launcher/app_shortcut_launcher_item_controller.h
+++ b/chrome/browser/ui/ash/launcher/app_shortcut_launcher_item_controller.h
@@ -8,9 +8,9 @@
#include <string>
#include <vector>
+#include "ash/public/cpp/shelf_item_delegate.h"
#include "base/macros.h"
#include "base/time/time.h"
-#include "chrome/browser/ui/ash/launcher/launcher_item_controller.h"
#include "url/gurl.h"
class Browser;
@@ -28,23 +28,22 @@ class ChromeLauncherController;
// Item controller for an app shortcut. Shortcuts track app and launcher ids,
// but do not have any associated windows (opening a shortcut will replace the
-// item with the appropriate LauncherItemController type).
-class AppShortcutLauncherItemController : public LauncherItemController {
+// item with the appropriate ash::ShelfItemDelegate type).
+class AppShortcutLauncherItemController : public ash::ShelfItemDelegate {
public:
~AppShortcutLauncherItemController() override;
static AppShortcutLauncherItemController* Create(
- const ash::AppLaunchId& app_launch_id,
- ChromeLauncherController* controller);
+ const ash::AppLaunchId& app_launch_id);
std::vector<content::WebContents*> GetRunningApplications();
- // LauncherItemController overrides:
+ // ash::ShelfItemDelegate overrides:
void ItemSelected(std::unique_ptr<ui::Event> event,
int64_t display_id,
ash::ShelfLaunchSource source,
const ItemSelectedCallback& callback) override;
- MenuItemList GetAppMenuItems(int event_flags) override;
+ ash::MenuItemList GetAppMenuItems(int event_flags) override;
void ExecuteCommand(uint32_t command_id, int32_t event_flags) override;
void Close() override;
@@ -57,8 +56,8 @@ class AppShortcutLauncherItemController : public LauncherItemController {
ChromeLauncherController* controller() { return chrome_launcher_controller_; }
protected:
- AppShortcutLauncherItemController(const ash::AppLaunchId& app_launch_id,
- ChromeLauncherController* controller);
+ explicit AppShortcutLauncherItemController(
+ const ash::AppLaunchId& app_launch_id);
private:
// Get the last running application.

Powered by Google App Engine
This is Rietveld 408576698