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

Unified Diff: ash/wm/window_mirror_view.cc

Issue 2234233002: Enable ash window cycle UI by default. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: sky review Created 4 years, 4 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
« no previous file with comments | « ash/wm/window_cycle_controller_unittest.cc ('k') | chrome/app/generated_resources.grd » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/wm/window_mirror_view.cc
diff --git a/ash/wm/window_mirror_view.cc b/ash/wm/window_mirror_view.cc
index 58c89e1a705f55265d8db2f502798b82983c7b04..374207c1c61cc35bec7ca4d259119404fcc4ffd2 100644
--- a/ash/wm/window_mirror_view.cc
+++ b/ash/wm/window_mirror_view.cc
@@ -104,6 +104,9 @@ ui::Layer* WindowMirrorView::GetMirrorLayer() {
}
gfx::Rect WindowMirrorView::GetClientAreaBounds() const {
+ // The target window may not have a widget in unit tests.
+ if (!target_->GetInternalWidget())
+ return gfx::Rect();
views::View* client_view = target_->GetInternalWidget()->client_view();
return client_view->ConvertRectToWidget(client_view->GetLocalBounds());
}
« no previous file with comments | « ash/wm/window_cycle_controller_unittest.cc ('k') | chrome/app/generated_resources.grd » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698