Chromium Code Reviews| Index: ash/common/shelf/shelf_window_watcher.cc |
| diff --git a/ash/common/shelf/shelf_window_watcher.cc b/ash/common/shelf/shelf_window_watcher.cc |
| index 3288f955e6277d48658f5efad10fb9ee8e0c35a4..5470399e49d0b3f84a6754d5ffe2110379f59ac4 100644 |
| --- a/ash/common/shelf/shelf_window_watcher.cc |
| +++ b/ash/common/shelf/shelf_window_watcher.cc |
| @@ -102,7 +102,8 @@ ShelfWindowWatcher::ShelfWindowWatcher(ShelfModel* model) |
| ShelfWindowWatcher::~ShelfWindowWatcher() { |
| display::Screen::GetScreen()->RemoveObserver(this); |
| - WmShell::Get()->RemoveActivationObserver(this); |
| + if (WmShell::HasInstance()) |
|
James Cook
2016/08/17 03:29:39
Why is this needed? ShelfWindowWatcher is owned by
msw
2016/08/17 17:45:44
Fixed instead by calling WmShell::Shutdown in Wind
|
| + WmShell::Get()->RemoveActivationObserver(this); |
| } |
| void ShelfWindowWatcher::AddShelfItem(WmWindow* window) { |