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

Unified Diff: cc/test/fake_surface_observer.h

Issue 2938833002: Add SurfaceWillDraw notification (Closed)
Patch Set: add unit test to verify that OnSurfaceWillDraw is called only for surfaces added to the CompositorF… 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/surfaces/surface_observer.h ('k') | cc/test/fake_surface_observer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/test/fake_surface_observer.h
diff --git a/cc/test/fake_surface_observer.h b/cc/test/fake_surface_observer.h
index ab0bab5d09202280189b19c3c82c11dc11d9bdcf..0ce2c23d4e2334b3b6df9223af66329b0699c582 100644
--- a/cc/test/fake_surface_observer.h
+++ b/cc/test/fake_surface_observer.h
@@ -24,6 +24,8 @@ class FakeSurfaceObserver : public SurfaceObserver {
bool IsSurfaceDamaged(const SurfaceId& surface_id) const;
+ bool SurfaceWillDrawCalled(const SurfaceId& surface_id) const;
+
const SurfaceId& last_created_surface_id() const {
return last_created_surface_id_;
}
@@ -41,10 +43,12 @@ class FakeSurfaceObserver : public SurfaceObserver {
void OnSurfaceDestroyed(const SurfaceId& surface_id) override {}
void OnSurfaceDamageExpected(const SurfaceId& surface_id,
const BeginFrameArgs& args) override {}
+ void OnSurfaceWillDraw(const SurfaceId& surface_id) override;
bool damage_display_;
BeginFrameAck last_ack_;
base::flat_set<SurfaceId> damaged_surfaces_;
+ base::flat_set<SurfaceId> will_draw_surfaces_;
SurfaceId last_created_surface_id_;
SurfaceInfo last_surface_info_;
};
« no previous file with comments | « cc/surfaces/surface_observer.h ('k') | cc/test/fake_surface_observer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698