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

Unified Diff: mash/wm/root_window_controller.cc

Issue 1907153002: mash/wm: Fix detecting container windows. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix-gn-check Created 4 years, 8 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
Index: mash/wm/root_window_controller.cc
diff --git a/mash/wm/root_window_controller.cc b/mash/wm/root_window_controller.cc
index 53356d480888f6b1c5434e08ca7fab8f9a6e353f..8f7d3f155eb13114d5b972c59a360ed83a976e87 100644
--- a/mash/wm/root_window_controller.cc
+++ b/mash/wm/root_window_controller.cc
@@ -73,7 +73,8 @@ mus::Window* RootWindowController::GetWindowForContainer(
}
bool RootWindowController::WindowIsContainer(const mus::Window* window) const {
- return window && window->parent() == root_;
+ return window && window != root_ &&
+ window->local_id() < ContainerToLocalId(mojom::Container::COUNT);
sky 2016/04/22 15:23:41 The default local_id is -1, should you check for l
sadrul 2016/04/22 16:06:05 Changed to > 0 (to exclude root)
}
mus::WindowManagerClient* RootWindowController::window_manager_client() {
« no previous file with comments | « mash/wm/BUILD.gn ('k') | mash/wm/window_manager.cc » ('j') | mash/wm/window_manager.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698