Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(84)

Side by Side Diff: cc/test/remote_channel_impl_for_test.cc

Issue 1513643010: cc:: Add remote mode to the compositor (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Use LayerTreeSettings::ToProtobuf, update comments. Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #include "cc/test/remote_channel_impl_for_test.h"
6
7 #include "cc/test/proxy_impl_for_test.h"
8
9 namespace cc {
10
11 scoped_ptr<RemoteChannelImplForTest> RemoteChannelImplForTest::Create(
12 TestHooks* test_hooks,
13 RemoteChannelHost* remote_channel_host,
14 TaskGraphRunner* task_graph_runner,
15 const LayerTreeSettings& settings,
16 scoped_refptr<base::SingleThreadTaskRunner> main_task_runner,
17 scoped_refptr<base::SingleThreadTaskRunner> impl_task_runner) {
18 return make_scoped_ptr(new RemoteChannelImplForTest(
19 test_hooks, remote_channel_host, task_graph_runner, settings,
20 main_task_runner, impl_task_runner));
21 }
22
23 RemoteChannelImplForTest::RemoteChannelImplForTest(
24 TestHooks* test_hooks,
25 RemoteChannelHost* remote_channel_host,
26 TaskGraphRunner* task_graph_runner,
27 const LayerTreeSettings& settings,
28 scoped_refptr<base::SingleThreadTaskRunner> main_task_runner,
29 scoped_refptr<base::SingleThreadTaskRunner> impl_task_runner)
30 : RemoteChannelImpl(remote_channel_host,
31 task_graph_runner,
32 settings,
33 main_task_runner,
34 impl_task_runner),
35 test_hooks_(test_hooks),
36 proxy_impl_for_test_(nullptr) {}
37
38 scoped_ptr<ProxyImpl> RemoteChannelImplForTest::CreateProxyImpl(
39 ChannelImpl* channel_impl,
40 LayerTreeHost* layer_tree_host,
41 TaskRunnerProvider* task_runner_provider,
42 scoped_ptr<BeginFrameSource> external_begin_frame_source) {
43 scoped_ptr<ProxyImplForTest> proxy_impl = ProxyImplForTest::Create(
44 test_hooks_, channel_impl, layer_tree_host, task_runner_provider,
45 std::move(external_begin_frame_source));
46 proxy_impl_for_test_ = proxy_impl.get();
47 return std::move(proxy_impl);
48 }
49
50 } // namespace cc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698