| OLD | NEW |
| (Empty) |
| 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 | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef UI_OZONE_PLATFORM_DRI_TEST_MOCK_SURFACE_GENERATOR_H_ | |
| 6 #define UI_OZONE_PLATFORM_DRI_TEST_MOCK_SURFACE_GENERATOR_H_ | |
| 7 | |
| 8 #include <vector> | |
| 9 | |
| 10 #include "ui/ozone/platform/dri/dri_surface.h" | |
| 11 | |
| 12 namespace gfx { | |
| 13 class Size; | |
| 14 } | |
| 15 | |
| 16 namespace ui { | |
| 17 | |
| 18 class DriWrapper; | |
| 19 | |
| 20 class MockSurfaceGenerator : public ScanoutSurfaceGenerator { | |
| 21 public: | |
| 22 MockSurfaceGenerator(DriWrapper* dri); | |
| 23 virtual ~MockSurfaceGenerator(); | |
| 24 | |
| 25 std::vector<DriSurface*> surfaces() const { return surfaces_; } | |
| 26 | |
| 27 // ScanoutSurfaceGenerator: | |
| 28 virtual ScanoutSurface* Create(const gfx::Size& size) OVERRIDE; | |
| 29 | |
| 30 private: | |
| 31 DriWrapper* dri_; // Not owned. | |
| 32 | |
| 33 std::vector<DriSurface*> surfaces_; | |
| 34 | |
| 35 DISALLOW_COPY_AND_ASSIGN(MockSurfaceGenerator); | |
| 36 }; | |
| 37 | |
| 38 } // namespace ui | |
| 39 | |
| 40 #endif // UI_OZONE_PLATFORM_DRI_TEST_MOCK_SURFACE_GENERATOR_H_ | |
| OLD | NEW |