| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 GPU_COMMAND_BUFFER_COMMON_COMMAND_BUFFER_MOCK_H_ | 5 #ifndef GPU_COMMAND_BUFFER_COMMON_COMMAND_BUFFER_MOCK_H_ |
| 6 #define GPU_COMMAND_BUFFER_COMMON_COMMAND_BUFFER_MOCK_H_ | 6 #define GPU_COMMAND_BUFFER_COMMON_COMMAND_BUFFER_MOCK_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| 11 #include "base/macros.h" | 11 #include "base/macros.h" |
| 12 #include "gpu/command_buffer/service/command_buffer_service.h" | 12 #include "gpu/command_buffer/service/command_buffer_service.h" |
| 13 #include "testing/gmock/include/gmock/gmock.h" | 13 #include "testing/gmock/include/gmock/gmock.h" |
| 14 | 14 |
| 15 namespace base { | |
| 16 class SharedMemory; | |
| 17 } | |
| 18 | |
| 19 namespace gpu { | 15 namespace gpu { |
| 20 | 16 |
| 21 // An NPObject that implements a shared memory command buffer and a synchronous | 17 // An NPObject that implements a shared memory command buffer and a synchronous |
| 22 // API to manage the put and get pointers. | 18 // API to manage the put and get pointers. |
| 23 class MockCommandBuffer : public CommandBufferServiceBase { | 19 class MockCommandBuffer : public CommandBufferServiceBase { |
| 24 public: | 20 public: |
| 25 MockCommandBuffer(); | 21 MockCommandBuffer(); |
| 26 virtual ~MockCommandBuffer(); | 22 virtual ~MockCommandBuffer(); |
| 27 | 23 |
| 28 MOCK_METHOD0(GetLastState, State()); | 24 MOCK_METHOD0(GetLastState, State()); |
| (...skipping 15 matching lines...) Expand all Loading... |
| 44 MOCK_METHOD0(InsertSyncPoint, uint32_t()); | 40 MOCK_METHOD0(InsertSyncPoint, uint32_t()); |
| 45 MOCK_METHOD0(GetPutOffset, int32_t()); | 41 MOCK_METHOD0(GetPutOffset, int32_t()); |
| 46 | 42 |
| 47 private: | 43 private: |
| 48 DISALLOW_COPY_AND_ASSIGN(MockCommandBuffer); | 44 DISALLOW_COPY_AND_ASSIGN(MockCommandBuffer); |
| 49 }; | 45 }; |
| 50 | 46 |
| 51 } // namespace gpu | 47 } // namespace gpu |
| 52 | 48 |
| 53 #endif // GPU_COMMAND_BUFFER_COMMON_COMMAND_BUFFER_MOCK_H_ | 49 #endif // GPU_COMMAND_BUFFER_COMMON_COMMAND_BUFFER_MOCK_H_ |
| OLD | NEW |