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

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

Issue 2166423002: ui::ContextFactory should not create SurfaceIdAllocators (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed Dana's nit Created 4 years, 5 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 | « services/ui/surfaces/display_compositor.cc ('k') | ui/compositor/compositor.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: services/ui/ws/server_window_surface.cc
diff --git a/services/ui/ws/server_window_surface.cc b/services/ui/ws/server_window_surface.cc
index 6f8f5254ce5a0a0b96e56ecda151df4a40eae1eb..fd7be5e71d2a2b1767c143c0a0023ee48318d212 100644
--- a/services/ui/ws/server_window_surface.cc
+++ b/services/ui/ws/server_window_surface.cc
@@ -27,7 +27,7 @@ ServerWindowSurface::ServerWindowSurface(
client_(std::move(client)),
binding_(this, std::move(request)) {
cc::SurfaceManager* surface_manager = manager_->GetSurfaceManager();
- surface_id_allocator_.RegisterSurfaceClientId(surface_manager);
+ surface_manager->RegisterSurfaceClientId(surface_id_allocator_.client_id());
surface_manager->RegisterSurfaceFactoryClient(
surface_id_allocator_.client_id(), this);
}
@@ -40,6 +40,7 @@ ServerWindowSurface::~ServerWindowSurface() {
cc::SurfaceManager* surface_manager = manager_->GetSurfaceManager();
surface_manager->UnregisterSurfaceFactoryClient(
surface_id_allocator_.client_id());
+ surface_manager->InvalidateSurfaceClientId(surface_id_allocator_.client_id());
}
void ServerWindowSurface::SubmitCompositorFrame(
« no previous file with comments | « services/ui/surfaces/display_compositor.cc ('k') | ui/compositor/compositor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698