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

Unified Diff: ash/test/test_shelf_delegate.cc

Issue 2171813004: mash: Fold ShelfItemDelegateManager into ShelfModel (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: cleanup Created 4 years, 5 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: ash/test/test_shelf_delegate.cc
diff --git a/ash/test/test_shelf_delegate.cc b/ash/test/test_shelf_delegate.cc
index 2605eb1148af3ee05849ee6d2b206bdac01ce757..14a509d278c09dc72bc83d844247d6c8fdff5867 100644
--- a/ash/test/test_shelf_delegate.cc
+++ b/ash/test/test_shelf_delegate.cc
@@ -6,10 +6,9 @@
#include <utility>
-#include "ash/common/shelf/shelf_item_delegate_manager.h"
#include "ash/common/shelf/shelf_model.h"
+#include "ash/common/wm_shell.h"
msw 2016/07/21 21:30:54 nit: remove; not needed.
James Cook 2016/07/22 01:20:08 Done.
#include "ash/shelf/shelf_util.h"
-#include "ash/shell.h"
#include "ash/test/test_shelf_item_delegate.h"
#include "base/strings/string_util.h"
#include "base/strings/utf_string_conversions.h"
@@ -51,12 +50,9 @@ void TestShelfDelegate::AddShelfItem(aura::Window* window,
model_->Add(item);
window->AddObserver(this);
- ShelfItemDelegateManager* manager =
- Shell::GetInstance()->shelf_item_delegate_manager();
- // |manager| owns TestShelfItemDelegate.
std::unique_ptr<ShelfItemDelegate> delegate(
new TestShelfItemDelegate(window));
- manager->SetShelfItemDelegate(id, std::move(delegate));
+ model_->SetShelfItemDelegate(id, std::move(delegate));
SetShelfIDForWindow(id, window);
}

Powered by Google App Engine
This is Rietveld 408576698