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

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

Issue 2489003002: Convert mustash use surface references. (Closed)
Patch Set: Created 4 years, 1 month 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
« services/ui/ws/frame_generator.cc ('K') | « services/ui/ws/test_utils.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: services/ui/ws/window_server.cc
diff --git a/services/ui/ws/window_server.cc b/services/ui/ws/window_server.cc
index e3da19d96ba8648de7e6b528c02776089600df95..6ea115f48bb1dfb0b6c0333d5fe9e676a02fd20f 100644
--- a/services/ui/ws/window_server.cc
+++ b/services/ui/ws/window_server.cc
@@ -781,6 +781,13 @@ void WindowServer::OnSurfaceCreated(const cc::SurfaceId& surface_id,
window->GetOrCreateCompositorFrameSinkManager()->SetLatestSurfaceInfo(
compositor_frame_sink_type, surface_id, frame_size);
+ // FrameGenerator will add an appropriate reference for the new surface.
+ DCHECK(display_manager_->GetDisplayContaining(window));
+ display_manager_->GetDisplayContaining(window)
+ ->platform_display()
+ ->GetFrameGenerator()
+ ->AddSurfaceReference(surface_id, window);
+
// This is only used for testing to observe that a window has a
// CompositorFrame.
if (!window_paint_callback_.is_null())
« services/ui/ws/frame_generator.cc ('K') | « services/ui/ws/test_utils.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698