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

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

Issue 68523017: ash: Add GetItemIndexForType() function to ShelfModel. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 7 years, 1 month 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
« no previous file with comments | « ash/shell.cc ('k') | chrome/browser/ui/ash/launcher/chrome_launcher_controller.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/ash/launcher/browser_shortcut_launcher_item_controller.cc
diff --git a/chrome/browser/ui/ash/launcher/browser_shortcut_launcher_item_controller.cc b/chrome/browser/ui/ash/launcher/browser_shortcut_launcher_item_controller.cc
index 5db34beca5daf81df648091da77108371a923009..e402b9de4ab70dd0d03a790e85961a45998e7de0 100644
--- a/chrome/browser/ui/ash/launcher/browser_shortcut_launcher_item_controller.cc
+++ b/chrome/browser/ui/ash/launcher/browser_shortcut_launcher_item_controller.cc
@@ -8,7 +8,6 @@
#include "ash/launcher/launcher.h"
#include "ash/shelf/shelf_model.h"
-#include "ash/shelf/shelf_model_util.h"
#include "ash/shelf/shelf_util.h"
#include "ash/shell.h"
#include "ash/wm/window_util.h"
@@ -61,8 +60,7 @@ void BrowserShortcutLauncherItemController::UpdateBrowserItemState() {
ash::ShelfModel* model = launcher_controller()->model();
// Determine the new browser's active state and change if necessary.
- int browser_index =
- ash::GetShelfItemIndexForType(ash::TYPE_BROWSER_SHORTCUT, *model);
+ int browser_index = model->GetItemIndexForType(ash::TYPE_BROWSER_SHORTCUT);
DCHECK_GE(browser_index, 0);
ash::LauncherItem browser_item = model->items()[browser_index];
ash::LauncherItemStatus browser_status = ash::STATUS_CLOSED;
« no previous file with comments | « ash/shell.cc ('k') | chrome/browser/ui/ash/launcher/chrome_launcher_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698