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

Unified Diff: cc/test/fake_output_surface.h

Issue 12674030: cc: Hook vsync time source to output surface (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Created 7 years, 9 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/test/fake_output_surface.h
diff --git a/cc/test/fake_output_surface.h b/cc/test/fake_output_surface.h
index 64c99aefdbf2bed51772a09e9dedb48ab6b63a02..c7fc55d4371d7306fbf224c3f1c1a942b50b888e 100644
--- a/cc/test/fake_output_surface.h
+++ b/cc/test/fake_output_surface.h
@@ -11,6 +11,10 @@
#include "cc/test/test_web_graphics_context_3d.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebGraphicsContext3D.h"
+namespace base {
+class TimeTicks;
jamesr 2013/03/23 00:35:29 Just include base/time.h
Sami 2013/03/25 13:58:33 Done.
+}
+
namespace cc {
class FakeOutputSurface : public OutputSurface {
@@ -61,6 +65,12 @@ class FakeOutputSurface : public OutputSurface {
CompositorFrame& last_sent_frame() { return last_sent_frame_; }
size_t num_sent_frames() { return num_sent_frames_; }
+ virtual void EnableVSyncNotification(bool enable) OVERRIDE;
+ bool vsync_notification_enabled() const {
+ return vsync_notification_enabled_;
+ }
+ void DidVSync(base::TimeTicks frame_time);
+
private:
FakeOutputSurface(
scoped_ptr<WebKit::WebGraphicsContext3D> context3d,
@@ -72,6 +82,7 @@ class FakeOutputSurface : public OutputSurface {
CompositorFrame last_sent_frame_;
size_t num_sent_frames_;
+ bool vsync_notification_enabled_;
};
static inline scoped_ptr<cc::OutputSurface> CreateFakeOutputSurface() {

Powered by Google App Engine
This is Rietveld 408576698