OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "blimp/engine/renderer/blimp_content_renderer_client.h" | 5 #include "blimp/engine/renderer/blimp_content_renderer_client.h" |
6 | 6 |
7 #include "base/memory/ptr_util.h" | 7 #include "base/memory/ptr_util.h" |
8 #include "blimp/engine/mojo/blob_channel.mojom.h" | 8 #include "blimp/engine/mojo/blob_channel.mojom.h" |
| 9 #include "blimp/engine/renderer/blimp_remote_compositor_bridge.h" |
9 #include "blimp/engine/renderer/blob_channel_sender_proxy.h" | 10 #include "blimp/engine/renderer/blob_channel_sender_proxy.h" |
10 #include "blimp/engine/renderer/engine_image_serialization_processor.h" | 11 #include "blimp/engine/renderer/engine_image_serialization_processor.h" |
11 #include "components/web_cache/renderer/web_cache_impl.h" | 12 #include "components/web_cache/renderer/web_cache_impl.h" |
12 | 13 |
13 namespace blimp { | 14 namespace blimp { |
14 namespace engine { | 15 namespace engine { |
15 | 16 |
16 BlimpContentRendererClient::BlimpContentRendererClient() {} | 17 BlimpContentRendererClient::BlimpContentRendererClient() {} |
17 | 18 |
18 BlimpContentRendererClient::~BlimpContentRendererClient() {} | 19 BlimpContentRendererClient::~BlimpContentRendererClient() {} |
19 | 20 |
20 void BlimpContentRendererClient::RenderThreadStarted() { | 21 void BlimpContentRendererClient::RenderThreadStarted() { |
21 web_cache_impl_.reset(new web_cache::WebCacheImpl()); | 22 web_cache_impl_.reset(new web_cache::WebCacheImpl()); |
22 image_serialization_processor_.reset(new EngineImageSerializationProcessor( | 23 image_serialization_processor_.reset(new EngineImageSerializationProcessor( |
23 base::WrapUnique(new BlobChannelSenderProxy))); | 24 base::WrapUnique(new BlobChannelSenderProxy))); |
24 } | 25 } |
25 | 26 |
26 cc::ImageSerializationProcessor* | 27 cc::ImageSerializationProcessor* |
27 BlimpContentRendererClient::GetImageSerializationProcessor() { | 28 BlimpContentRendererClient::GetImageSerializationProcessor() { |
28 return image_serialization_processor_.get(); | 29 return image_serialization_processor_.get(); |
29 } | 30 } |
30 | 31 |
| 32 std::unique_ptr<cc::RemoteCompositorBridge> |
| 33 BlimpContentRendererClient::CreateRemoteCompositorBridge( |
| 34 cc::RemoteProtoChannel* remote_proto_channel, |
| 35 scoped_refptr<base::SingleThreadTaskRunner> compositor_main_task_runner) { |
| 36 return base::MakeUnique<BlimpRemoteCompositorBridge>( |
| 37 remote_proto_channel, std::move(compositor_main_task_runner)); |
| 38 } |
| 39 |
31 } // namespace engine | 40 } // namespace engine |
32 } // namespace blimp | 41 } // namespace blimp |
OLD | NEW |