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

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

Issue 2582823002: WIP: Surface Synchronization System
Patch Set: Only create ClientSurfaceEmbedder if window is visible. Trash it otherwise. Created 3 years, 11 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 e93c88023faa98ee3d0add72f88614e52ad67e22..369308b18d7540196131db4faec221890a24d7ba 100644
--- a/services/ui/ws/display.cc
+++ b/services/ui/ws/display.cc
@@ -254,9 +254,9 @@ void Display::CreateRootWindow(const gfx::Size& size) {
DCHECK(!root_);
root_.reset(window_server_->CreateServerWindow(
- display_manager()->GetAndAdvanceNextRootId(),
- ServerWindow::Properties()));
- root_->SetBounds(gfx::Rect(size));
+ display_manager()->GetAndAdvanceNextRootId(), ServerWindow::Properties(),
+ allocator_.GenerateId()));
+ root_->SetBounds(gfx::Rect(size), allocator_.GenerateId());
root_->SetVisible(true);
focus_controller_ = base::MakeUnique<FocusController>(this, root_.get());
focus_controller_->AddObserver(this);
@@ -301,9 +301,9 @@ void Display::OnViewportMetricsChanged(
return;
gfx::Rect new_bounds(metrics.pixel_size);
- root_->SetBounds(new_bounds);
+ root_->SetBounds(new_bounds, allocator_.GenerateId());
for (auto& pair : window_manager_display_root_map_)
- pair.second->root()->SetBounds(new_bounds);
+ pair.second->root()->SetBounds(new_bounds, allocator_.GenerateId());
}
ServerWindow* Display::GetActiveRootWindow() {

Powered by Google App Engine
This is Rietveld 408576698