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

Side by Side Diff: cc/surfaces/surface_manager.h

Issue 2908783002: WIP Hittest Component.
Patch Set: improvements from reviewer comments Created 3 years, 6 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CC_SURFACES_SURFACE_MANAGER_H_ 5 #ifndef CC_SURFACES_SURFACE_MANAGER_H_
6 #define CC_SURFACES_SURFACE_MANAGER_H_ 6 #define CC_SURFACES_SURFACE_MANAGER_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <list> 10 #include <list>
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
67 67
68 void RequestSurfaceResolution(Surface* pending_surface); 68 void RequestSurfaceResolution(Surface* pending_surface);
69 69
70 std::unique_ptr<Surface> CreateSurface( 70 std::unique_ptr<Surface> CreateSurface(
71 base::WeakPtr<CompositorFrameSinkSupport> compositor_frame_sink_support, 71 base::WeakPtr<CompositorFrameSinkSupport> compositor_frame_sink_support,
72 const SurfaceInfo& surface_info); 72 const SurfaceInfo& surface_info);
73 73
74 // Destroy the Surface once a set of sequence numbers has been satisfied. 74 // Destroy the Surface once a set of sequence numbers has been satisfied.
75 void DestroySurface(std::unique_ptr<Surface> surface); 75 void DestroySurface(std::unique_ptr<Surface> surface);
76 76
77 void SurfaceWillDraw(const SurfaceId& surface_id);
rjkroege 2017/06/07 20:22:56 Add method comment.
gklassen 2017/06/08 17:09:21 Done.
78
77 Surface* GetSurfaceForId(const SurfaceId& surface_id); 79 Surface* GetSurfaceForId(const SurfaceId& surface_id);
78 80
79 void AddObserver(SurfaceObserver* obs) { observer_list_.AddObserver(obs); } 81 void AddObserver(SurfaceObserver* obs) { observer_list_.AddObserver(obs); }
80 82
81 void RemoveObserver(SurfaceObserver* obs) { 83 void RemoveObserver(SurfaceObserver* obs) {
82 observer_list_.RemoveObserver(obs); 84 observer_list_.RemoveObserver(obs);
83 } 85 }
84 86
85 // Called when a Surface is modified, e.g. when a CompositorFrame is 87 // Called when a Surface is modified, e.g. when a CompositorFrame is
86 // activated, its producer confirms that no CompositorFrame will be submitted 88 // activated, its producer confirms that no CompositorFrame will be submitted
(...skipping 218 matching lines...) Expand 10 before | Expand all | Expand 10 after
305 SurfaceDependencyTracker* dependency_tracker_ = nullptr; 307 SurfaceDependencyTracker* dependency_tracker_ = nullptr;
306 308
307 base::WeakPtrFactory<SurfaceManager> weak_factory_; 309 base::WeakPtrFactory<SurfaceManager> weak_factory_;
308 310
309 DISALLOW_COPY_AND_ASSIGN(SurfaceManager); 311 DISALLOW_COPY_AND_ASSIGN(SurfaceManager);
310 }; 312 };
311 313
312 } // namespace cc 314 } // namespace cc
313 315
314 #endif // CC_SURFACES_SURFACE_MANAGER_H_ 316 #endif // CC_SURFACES_SURFACE_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698