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

Unified Diff: chrome/browser/ui/ash/app_list/app_list_controller_ash.cc

Issue 2833173002: mash: Support ShelfModel access in Chrome. (Closed)
Patch Set: Refine init pattern; add AppList item in ShelfModel ctor. Created 3 years, 7 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/app_list/app_list_controller_ash.cc
diff --git a/chrome/browser/ui/ash/app_list/app_list_controller_ash.cc b/chrome/browser/ui/ash/app_list/app_list_controller_ash.cc
index 4a0807d4035df3b51568f6d12c78d763c6c18530..71e31b1856e02c9c10c5e2c583ef15321de8f461 100644
--- a/chrome/browser/ui/ash/app_list/app_list_controller_ash.cc
+++ b/chrome/browser/ui/ash/app_list/app_list_controller_ash.cc
@@ -5,7 +5,6 @@
#include "chrome/browser/ui/ash/app_list/app_list_controller_ash.h"
#include "ash/shelf/shelf_model.h"
James Cook 2017/05/30 22:47:48 still needed?
msw 2017/05/31 16:55:21 Done.
-#include "ash/shell.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/ui/ash/launcher/chrome_launcher_controller.h"
#include "chrome/browser/ui/ash/launcher/chrome_launcher_controller_util.h"
@@ -39,7 +38,7 @@ gfx::Rect AppListControllerDelegateAsh::GetAppListBounds() {
}
bool AppListControllerDelegateAsh::IsAppPinned(const std::string& app_id) {
- return ash::Shell::Get()->shelf_model()->IsAppPinned(app_id);
+ return ChromeLauncherController::instance()->IsAppPinned(app_id);
}
bool AppListControllerDelegateAsh::IsAppOpen(const std::string& app_id) const {
@@ -47,11 +46,11 @@ bool AppListControllerDelegateAsh::IsAppOpen(const std::string& app_id) const {
}
void AppListControllerDelegateAsh::PinApp(const std::string& app_id) {
- ash::Shell::Get()->shelf_model()->PinAppWithID(app_id);
+ ChromeLauncherController::instance()->PinAppWithID(app_id);
}
void AppListControllerDelegateAsh::UnpinApp(const std::string& app_id) {
- ash::Shell::Get()->shelf_model()->UnpinAppWithID(app_id);
+ ChromeLauncherController::instance()->UnpinAppWithID(app_id);
}
AppListControllerDelegate::Pinnable AppListControllerDelegateAsh::GetPinnable(

Powered by Google App Engine
This is Rietveld 408576698