| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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 "cc/test/fake_proxy.h" | 5 #include "cc/test/fake_proxy.h" |
| 6 | 6 |
| 7 namespace cc { | 7 namespace cc { |
| 8 | 8 |
| 9 void FakeProxy::SetLayerTreeHost(LayerTreeHost* host) { | 9 void FakeProxy::SetLayerTreeHost(LayerTreeHost* host) { |
| 10 layer_tree_host_ = host; | 10 layer_tree_host_ = host; |
| 11 } | 11 } |
| 12 | 12 |
| 13 bool FakeProxy::CompositeAndReadback(void* pixels, const gfx::Rect& rect) { | |
| 14 return true; | |
| 15 } | |
| 16 | |
| 17 bool FakeProxy::IsStarted() const { return true; } | 13 bool FakeProxy::IsStarted() const { return true; } |
| 18 | 14 |
| 19 void FakeProxy::CreateAndInitializeOutputSurface() { | 15 void FakeProxy::CreateAndInitializeOutputSurface() { |
| 20 DCHECK(layer_tree_host_); | 16 DCHECK(layer_tree_host_); |
| 21 layer_tree_host_->OnCreateAndInitializeOutputSurfaceAttempted(true); | 17 layer_tree_host_->OnCreateAndInitializeOutputSurfaceAttempted(true); |
| 22 } | 18 } |
| 23 | 19 |
| 24 const RendererCapabilities& FakeProxy::GetRendererCapabilities() const { | 20 const RendererCapabilities& FakeProxy::GetRendererCapabilities() const { |
| 25 return capabilities_; | 21 return capabilities_; |
| 26 } | 22 } |
| (...skipping 15 matching lines...) Expand all Loading... |
| 42 } | 38 } |
| 43 | 39 |
| 44 bool FakeProxy::CommitPendingForTesting() { return false; } | 40 bool FakeProxy::CommitPendingForTesting() { return false; } |
| 45 | 41 |
| 46 scoped_ptr<base::Value> FakeProxy::AsValue() const { | 42 scoped_ptr<base::Value> FakeProxy::AsValue() const { |
| 47 scoped_ptr<base::DictionaryValue> state(new base::DictionaryValue()); | 43 scoped_ptr<base::DictionaryValue> state(new base::DictionaryValue()); |
| 48 return state.PassAs<base::Value>(); | 44 return state.PassAs<base::Value>(); |
| 49 } | 45 } |
| 50 | 46 |
| 51 } // namespace cc | 47 } // namespace cc |
| OLD | NEW |