| 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/layers/texture_layer.h" | 5 #include "cc/layers/texture_layer.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 67 } | 67 } |
| 68 | 68 |
| 69 MOCK_METHOD0(SetNeedsCommit, void()); | 69 MOCK_METHOD0(SetNeedsCommit, void()); |
| 70 MOCK_METHOD0(SetNeedsUpdateLayers, void()); | 70 MOCK_METHOD0(SetNeedsUpdateLayers, void()); |
| 71 MOCK_METHOD0(StartRateLimiter, void()); | 71 MOCK_METHOD0(StartRateLimiter, void()); |
| 72 MOCK_METHOD0(StopRateLimiter, void()); | 72 MOCK_METHOD0(StopRateLimiter, void()); |
| 73 | 73 |
| 74 private: | 74 private: |
| 75 MockLayerTreeHost(FakeLayerTreeHostClient* client, | 75 MockLayerTreeHost(FakeLayerTreeHostClient* client, |
| 76 LayerTreeHost::InitParams* params) | 76 LayerTreeHost::InitParams* params) |
| 77 : LayerTreeHost(params) { | 77 : LayerTreeHost(params, CompositorMode::SingleThreaded) { |
| 78 InitializeSingleThreaded(client, base::ThreadTaskRunnerHandle::Get(), | 78 InitializeSingleThreaded(client, base::ThreadTaskRunnerHandle::Get(), |
| 79 nullptr); | 79 nullptr); |
| 80 } | 80 } |
| 81 }; | 81 }; |
| 82 | 82 |
| 83 class FakeTextureLayerClient : public TextureLayerClient { | 83 class FakeTextureLayerClient : public TextureLayerClient { |
| 84 public: | 84 public: |
| 85 FakeTextureLayerClient() : mailbox_changed_(true) {} | 85 FakeTextureLayerClient() : mailbox_changed_(true) {} |
| 86 | 86 |
| 87 bool PrepareTextureMailbox( | 87 bool PrepareTextureMailbox( |
| (...skipping 1383 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1471 int callback_count_; | 1471 int callback_count_; |
| 1472 scoped_refptr<Layer> root_; | 1472 scoped_refptr<Layer> root_; |
| 1473 scoped_refptr<TextureLayer> layer_; | 1473 scoped_refptr<TextureLayer> layer_; |
| 1474 }; | 1474 }; |
| 1475 | 1475 |
| 1476 SINGLE_AND_MULTI_THREAD_DIRECT_RENDERER_TEST_F( | 1476 SINGLE_AND_MULTI_THREAD_DIRECT_RENDERER_TEST_F( |
| 1477 TextureLayerWithMailboxImplThreadDeleted); | 1477 TextureLayerWithMailboxImplThreadDeleted); |
| 1478 | 1478 |
| 1479 } // namespace | 1479 } // namespace |
| 1480 } // namespace cc | 1480 } // namespace cc |
| OLD | NEW |