| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 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 #include "content/test/fake_compositor_dependencies.h" | 5 #include "content/test/fake_compositor_dependencies.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include "base/memory/ptr_util.h" | 9 #include "base/memory/ptr_util.h" |
| 10 #include "base/single_thread_task_runner.h" | 10 #include "base/single_thread_task_runner.h" |
| (...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 78 gpu::GpuMemoryBufferManager* | 78 gpu::GpuMemoryBufferManager* |
| 79 FakeCompositorDependencies::GetGpuMemoryBufferManager() { | 79 FakeCompositorDependencies::GetGpuMemoryBufferManager() { |
| 80 return &gpu_memory_buffer_manager_; | 80 return &gpu_memory_buffer_manager_; |
| 81 } | 81 } |
| 82 | 82 |
| 83 scheduler::RendererScheduler* | 83 scheduler::RendererScheduler* |
| 84 FakeCompositorDependencies::GetRendererScheduler() { | 84 FakeCompositorDependencies::GetRendererScheduler() { |
| 85 return &renderer_scheduler_; | 85 return &renderer_scheduler_; |
| 86 } | 86 } |
| 87 | 87 |
| 88 cc::ContextProvider* | |
| 89 FakeCompositorDependencies::GetSharedMainThreadContextProvider() { | |
| 90 NOTREACHED(); | |
| 91 return nullptr; | |
| 92 } | |
| 93 | |
| 94 std::unique_ptr<cc::BeginFrameSource> | 88 std::unique_ptr<cc::BeginFrameSource> |
| 95 FakeCompositorDependencies::CreateExternalBeginFrameSource(int routing_id) { | 89 FakeCompositorDependencies::CreateExternalBeginFrameSource(int routing_id) { |
| 96 double refresh_rate = 200.0; | 90 double refresh_rate = 200.0; |
| 97 return base::WrapUnique(new cc::FakeExternalBeginFrameSource(refresh_rate)); | 91 return base::WrapUnique(new cc::FakeExternalBeginFrameSource(refresh_rate)); |
| 98 } | 92 } |
| 99 | 93 |
| 100 cc::ImageSerializationProcessor* | 94 cc::ImageSerializationProcessor* |
| 101 FakeCompositorDependencies::GetImageSerializationProcessor() { | 95 FakeCompositorDependencies::GetImageSerializationProcessor() { |
| 102 return nullptr; | 96 return nullptr; |
| 103 } | 97 } |
| 104 | 98 |
| 105 cc::TaskGraphRunner* FakeCompositorDependencies::GetTaskGraphRunner() { | 99 cc::TaskGraphRunner* FakeCompositorDependencies::GetTaskGraphRunner() { |
| 106 return &task_graph_runner_; | 100 return &task_graph_runner_; |
| 107 } | 101 } |
| 108 | 102 |
| 109 bool FakeCompositorDependencies::AreImageDecodeTasksEnabled() { | 103 bool FakeCompositorDependencies::AreImageDecodeTasksEnabled() { |
| 110 return false; | 104 return false; |
| 111 } | 105 } |
| 112 | 106 |
| 113 bool FakeCompositorDependencies::IsThreadedAnimationEnabled() { | 107 bool FakeCompositorDependencies::IsThreadedAnimationEnabled() { |
| 114 return true; | 108 return true; |
| 115 } | 109 } |
| 116 | 110 |
| 117 } // namespace content | 111 } // namespace content |
| OLD | NEW |