Chromium Code Reviews| Index: components/exo/pointer.cc |
| diff --git a/components/exo/pointer.cc b/components/exo/pointer.cc |
| index 1697f5c34dc76a475f96b2b80b43cf9872e52acc..71c59f7812330b73576ec64d11bad93744718824 100644 |
| --- a/components/exo/pointer.cc |
| +++ b/components/exo/pointer.cc |
| @@ -89,9 +89,8 @@ void Pointer::SetCursor(Surface* surface, const gfx::Point& hotspot) { |
| } |
| if (surface_) { |
| surface_->window()->SetTransform(gfx::Transform()); |
| - WMHelper::GetInstance() |
| - ->GetContainer(ash::kShellWindowId_MouseCursorContainer) |
| - ->RemoveChild(surface_->window()); |
| + if (surface_->window()->parent()) |
|
reveman
2017/04/27 15:55:04
How can surface_->window()->parent() be null? Can
Dominik Laskowski
2017/04/27 17:02:05
If the primary display is removed.
|
| + surface_->window()->parent()->RemoveChild(surface_->window()); |
| surface_->SetSurfaceDelegate(nullptr); |
| surface_->RemoveSurfaceObserver(this); |
| } |