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

Unified Diff: services/ui/ws/display.cc

Issue 2712203002: c++ / mojo changes for 'external window mode'
Patch Set: . Created 3 years, 10 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: services/ui/ws/display.cc
diff --git a/services/ui/ws/display.cc b/services/ui/ws/display.cc
index b3981b86032061140d6c25279a890a940e863eab..e2d76095f96b673a79ae7095fa42b07400e532b7 100644
--- a/services/ui/ws/display.cc
+++ b/services/ui/ws/display.cc
@@ -213,7 +213,15 @@ void Display::InitWindowManagerDisplayRoots() {
// id works.
window_manager_display_root_map_[service_manager::mojom::kRootUserID] =
display_root_ptr.get();
- WindowTree* window_tree = binding_->CreateWindowTree(display_root->root());
+
+ DCHECK(window_server_->window_tree_host_factory());
+ WindowTree* window_tree =
+ window_server_->window_tree_host_factory()->window_tree();
+ window_tree->AddRoot(display_root->root());
+ window_tree->DoOnEmbed(nullptr /*mojom::WindowTreePtr*/,
fwang 2017/02/28 08:23:53 Is commenting nullptr parameter something common i
+ display_root->root());
+
+ window_tree->ConfigureWindowManager();
display_root->window_manager_state_ = window_tree->window_manager_state();
window_tree->window_manager_state()->AddWindowManagerDisplayRoot(
std::move(display_root_ptr));

Powered by Google App Engine
This is Rietveld 408576698