Index: chrome/browser/ui/ash/launcher/extension_app_window_launcher_controller.cc |
diff --git a/chrome/browser/ui/ash/launcher/extension_app_window_launcher_controller.cc b/chrome/browser/ui/ash/launcher/extension_app_window_launcher_controller.cc |
index 138cec71e67b9313cdfbe6c35c00f69db23076ab..73a24e7ef60340887eda2450632f4596747d9028 100644 |
--- a/chrome/browser/ui/ash/launcher/extension_app_window_launcher_controller.cc |
+++ b/chrome/browser/ui/ash/launcher/extension_app_window_launcher_controller.cc |
@@ -41,6 +41,13 @@ std::string GetLaunchId(AppWindow* app_window) { |
return launch_id; |
} |
+std::string GetTitle(AppWindow* app_window) { |
+ if (app_window->show_in_shelf()) |
+ return app_window->title(); |
+ else |
+ return base::EmptyString(); |
+} |
+ |
std::string GetAppShelfId(AppWindow* app_window) { |
// Set app_shelf_id value to app_id and then append launch_id. |
std::string app_id = app_window->extension_id(); |
@@ -167,9 +174,10 @@ void ExtensionAppWindowLauncherController::RegisterApp(AppWindow* app_window) { |
} else { |
LauncherItemController::Type type = LauncherItemController::TYPE_APP; |
std::string launch_id = GetLaunchId(app_window); |
+ std::string title = GetTitle(app_window); |
ExtensionAppWindowLauncherItemController* controller = |
new ExtensionAppWindowLauncherItemController(type, app_id, launch_id, |
- owner()); |
+ title, owner()); |
controller->AddAppWindow(app_window); |
// If there is already a shelf id mapped to this app_shelf_id (e.g. pinned), |
// use that shelf item. |