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

Unified Diff: cc/surfaces/surface_manager.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: cc/surfaces/surface_manager.cc
diff --git a/cc/surfaces/surface_manager.cc b/cc/surfaces/surface_manager.cc
index 94bdac6aceaf9382966fc5dedcc45262303c0837..bd162498471eea734b040236f8e4ad1548a13317 100644
--- a/cc/surfaces/surface_manager.cc
+++ b/cc/surfaces/surface_manager.cc
@@ -80,6 +80,16 @@ std::string SurfaceManager::SurfaceReferencesToString() {
}
#endif
+void SurfaceManager::SetLockManager(
+ std::unique_ptr<DisplayCompositorLockManager> lock_manager) {
+ lock_manager_ = std::move(lock_manager);
+}
+
+void SurfaceManager::RequestSurfaceResolution(Surface* pending_surface) {
+ if (lock_manager_)
+ lock_manager_->RequestSurfaceResolution(pending_surface);
+}
+
void SurfaceManager::RegisterSurface(Surface* surface) {
DCHECK(thread_checker_.CalledOnValidThread());
DCHECK(surface);
@@ -148,10 +158,10 @@ void SurfaceManager::AddSurfaceReference(const SurfaceId& parent_id,
DLOG(ERROR) << "No surface in map for " << parent_id.ToString();
return;
}
- if (surface_map_.count(child_id) == 0) {
- DLOG(ERROR) << "No surface in map for " << child_id.ToString();
- return;
- }
+ // if (surface_map_.count(child_id) == 0) {
+ // DLOG(ERROR) << "No surface in map for " << child_id.ToString();
+ // return;
+ //}
// There could be a temporary reference to |child_id| which we should now
// remove because a real reference is being added to it. To find out whether

Powered by Google App Engine
This is Rietveld 408576698