Index: ash/display/screen_ash.cc |
diff --git a/ash/display/screen_ash.cc b/ash/display/screen_ash.cc |
index 0348cbe26ace11d2ad7a4bb5466bf813bf1ac94a..607784dd8fc6088e878414a5ba4a213c7ec09c68 100644 |
--- a/ash/display/screen_ash.cc |
+++ b/ash/display/screen_ash.cc |
@@ -235,12 +235,11 @@ gfx::Display ScreenAsh::GetDisplayNearestWindow(gfx::NativeView window) const { |
if (!root_window) |
return GetPrimaryDisplay(); |
const RootWindowSettings* rws = GetRootWindowSettings(root_window); |
- if (rws->shutdown) |
- return GetPrimaryDisplay(); |
- |
int64 id = rws->display_id; |
// if id is |kInvaildDisplayID|, it's being deleted. |
DCHECK(id != gfx::Display::kInvalidDisplayID); |
+ if (id == gfx::Display::kInvalidDisplayID) |
+ return GetPrimaryDisplay(); |
DisplayManager* display_manager = GetDisplayManager(); |
// RootWindow needs Display to determine its device scale factor |