Index: ash/shell/window_watcher.cc |
diff --git a/ash/shell/window_watcher.cc b/ash/shell/window_watcher.cc |
index 5254210b7501974dfb480d5eacadc75741cc32e0..64f1bc93bbae7b240d830c71a1e87aab4734e1f2 100644 |
--- a/ash/shell/window_watcher.cc |
+++ b/ash/shell/window_watcher.cc |
@@ -9,6 +9,7 @@ |
#include "ash/common/shelf/shelf_item_delegate_manager.h" |
#include "ash/common/shelf/shelf_model.h" |
#include "ash/common/shell_window_ids.h" |
+#include "ash/common/wm_shell.h" |
#include "ash/display/window_tree_host_manager.h" |
#include "ash/shelf/shelf.h" |
#include "ash/shelf/shelf_util.h" |
@@ -96,7 +97,7 @@ void WindowWatcher::OnWindowAdded(aura::Window* new_window) { |
return; |
static int image_count = 0; |
- ShelfModel* model = Shell::GetInstance()->shelf_model(); |
+ ShelfModel* model = WmShell::Get()->shelf_model(); |
ShelfItem item; |
item.type = new_window->type() == ui::wm::WINDOW_TYPE_PANEL |
? ash::TYPE_APP_PANEL |
@@ -125,7 +126,7 @@ void WindowWatcher::OnWillRemoveWindow(aura::Window* window) { |
for (IDToWindow::iterator i = id_to_window_.begin(); i != id_to_window_.end(); |
++i) { |
if (i->second == window) { |
- ShelfModel* model = Shell::GetInstance()->shelf_model(); |
+ ShelfModel* model = WmShell::Get()->shelf_model(); |
int index = model->ItemIndexByID(i->first); |
DCHECK_NE(-1, index); |
model->RemoveItemAt(index); |