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

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

Issue 2627533002: Replace ShelfItemDelegate::GetTitle() with ShelfItem::title. (Closed)
Patch Set: Address comments. Created 3 years, 11 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.cc
diff --git a/chrome/browser/ui/ash/launcher/app_shortcut_launcher_item_controller.cc b/chrome/browser/ui/ash/launcher/app_shortcut_launcher_item_controller.cc
index cda8e1d8b64114c39a12438242ca1d16c34b2e05..8788a4506a06e41c4b7e3e6070ed55edf3329361 100644
--- a/chrome/browser/ui/ash/launcher/app_shortcut_launcher_item_controller.cc
+++ b/chrome/browser/ui/ash/launcher/app_shortcut_launcher_item_controller.cc
@@ -156,8 +156,10 @@ ChromeLauncherAppMenuItems
AppShortcutLauncherItemController::GetApplicationList(int event_flags) {
ChromeLauncherAppMenuItems items;
// Add the application name to the menu.
+ base::string16 app_title = LauncherControllerHelper::GetAppTitle(
+ launcher_controller()->profile(), app_id());
items.push_back(
- base::MakeUnique<ChromeLauncherAppMenuItem>(GetTitle(), nullptr, false));
+ base::MakeUnique<ChromeLauncherAppMenuItem>(app_title, nullptr, false));
std::vector<content::WebContents*> content_list = GetRunningApplications();
@@ -216,11 +218,6 @@ AppShortcutLauncherItemController::ItemSelected(const ui::Event& event) {
return Activate(ash::LAUNCH_FROM_UNKNOWN);
}
-base::string16 AppShortcutLauncherItemController::GetTitle() {
- return LauncherControllerHelper::GetAppTitle(launcher_controller()->profile(),
- app_id());
-}
-
ash::ShelfMenuModel* AppShortcutLauncherItemController::CreateApplicationMenu(
int event_flags) {
return new LauncherApplicationMenuItemModel(GetApplicationList(event_flags));

Powered by Google App Engine
This is Rietveld 408576698