| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_TEST_FAKE_OUTPUT_SURFACE_CLIENT_H_ | 5 #ifndef CC_TEST_FAKE_OUTPUT_SURFACE_CLIENT_H_ |
| 6 #define CC_TEST_FAKE_OUTPUT_SURFACE_CLIENT_H_ | 6 #define CC_TEST_FAKE_OUTPUT_SURFACE_CLIENT_H_ |
| 7 | 7 |
| 8 #include "cc/output/managed_memory_policy.h" | 8 #include "cc/output/managed_memory_policy.h" |
| 9 #include "cc/output/output_surface_client.h" | 9 #include "cc/output/output_surface_client.h" |
| 10 | 10 |
| 11 namespace cc { | 11 namespace cc { |
| 12 | 12 |
| 13 class OutputSurface; | 13 class OutputSurface; |
| 14 | 14 |
| 15 class FakeOutputSurfaceClient : public OutputSurfaceClient { | 15 class FakeOutputSurfaceClient : public OutputSurfaceClient { |
| 16 public: | 16 public: |
| 17 FakeOutputSurfaceClient() | 17 FakeOutputSurfaceClient() |
| 18 : swap_count_(0), | 18 : swap_count_(0), |
| 19 did_lose_output_surface_called_(false), | 19 did_lose_output_surface_called_(false), |
| 20 memory_policy_(0) {} | 20 memory_policy_(0) {} |
| 21 | 21 |
| 22 void CommitVSyncParameters(base::TimeTicks timebase, |
| 23 base::TimeDelta interval) override {} |
| 22 void SetBeginFrameSource(BeginFrameSource* source) override {} | 24 void SetBeginFrameSource(BeginFrameSource* source) override {} |
| 23 void SetNeedsRedrawRect(const gfx::Rect& damage_rect) override {} | 25 void SetNeedsRedrawRect(const gfx::Rect& damage_rect) override {} |
| 24 void DidSwapBuffersComplete() override; | 26 void DidSwapBuffersComplete() override; |
| 25 void DidReceiveTextureInUseResponses( | 27 void DidReceiveTextureInUseResponses( |
| 26 const gpu::TextureInUseResponses& responses) override {} | 28 const gpu::TextureInUseResponses& responses) override {} |
| 27 void ReclaimResources(const ReturnedResourceArray& resources) override {} | 29 void ReclaimResources(const ReturnedResourceArray& resources) override {} |
| 28 void DidLoseOutputSurface() override; | 30 void DidLoseOutputSurface() override; |
| 29 void SetExternalTilePriorityConstraints( | 31 void SetExternalTilePriorityConstraints( |
| 30 const gfx::Rect& viewport_rect_for_tile_priority, | 32 const gfx::Rect& viewport_rect_for_tile_priority, |
| 31 const gfx::Transform& transform_for_tile_priority) override {} | 33 const gfx::Transform& transform_for_tile_priority) override {} |
| (...skipping 13 matching lines...) Expand all Loading... |
| 45 | 47 |
| 46 private: | 48 private: |
| 47 int swap_count_; | 49 int swap_count_; |
| 48 bool did_lose_output_surface_called_; | 50 bool did_lose_output_surface_called_; |
| 49 ManagedMemoryPolicy memory_policy_; | 51 ManagedMemoryPolicy memory_policy_; |
| 50 }; | 52 }; |
| 51 | 53 |
| 52 } // namespace cc | 54 } // namespace cc |
| 53 | 55 |
| 54 #endif // CC_TEST_FAKE_OUTPUT_SURFACE_CLIENT_H_ | 56 #endif // CC_TEST_FAKE_OUTPUT_SURFACE_CLIENT_H_ |
| OLD | NEW |