OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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/trees/remote_channel_main.h" | 5 #include "cc/trees/remote_channel_main.h" |
6 | 6 |
7 #include <memory> | 7 #include <memory> |
8 | 8 |
9 #include "base/memory/ptr_util.h" | 9 #include "base/memory/ptr_util.h" |
10 #include "cc/proto/base_conversions.h" | 10 #include "cc/proto/base_conversions.h" |
(...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
212 // LayerTreeHostClient::DidCommit and stay consistent with the | 212 // LayerTreeHostClient::DidCommit and stay consistent with the |
213 // behaviour in the threaded compositor. | 213 // behaviour in the threaded compositor. |
214 MainThreadTaskRunner()->PostTask( | 214 MainThreadTaskRunner()->PostTask( |
215 FROM_HERE, base::Bind(&RemoteChannelMain::DidCommitAndDrawFrame, | 215 FROM_HERE, base::Bind(&RemoteChannelMain::DidCommitAndDrawFrame, |
216 weak_factory_.GetWeakPtr())); | 216 weak_factory_.GetWeakPtr())); |
217 | 217 |
218 completion->Signal(); | 218 completion->Signal(); |
219 } | 219 } |
220 | 220 |
221 void RemoteChannelMain::SynchronouslyInitializeImpl( | 221 void RemoteChannelMain::SynchronouslyInitializeImpl( |
222 LayerTreeHostInProcess* layer_tree_host, | 222 LayerTreeHostInProcess* layer_tree_host) { |
223 std::unique_ptr<BeginFrameSource> external_begin_frame_source) { | |
224 TRACE_EVENT0("cc.remote", "RemoteChannelMain::SynchronouslyInitializeImpl"); | 223 TRACE_EVENT0("cc.remote", "RemoteChannelMain::SynchronouslyInitializeImpl"); |
225 DCHECK(!initialized_); | 224 DCHECK(!initialized_); |
226 | 225 |
227 initialized_ = true; | 226 initialized_ = true; |
228 } | 227 } |
229 | 228 |
230 void RemoteChannelMain::SynchronouslyCloseImpl() { | 229 void RemoteChannelMain::SynchronouslyCloseImpl() { |
231 TRACE_EVENT0("cc.remote", "RemoteChannelMain::SynchronouslyCloseImpl"); | 230 TRACE_EVENT0("cc.remote", "RemoteChannelMain::SynchronouslyCloseImpl"); |
232 DCHECK(initialized_); | 231 DCHECK(initialized_); |
233 | 232 |
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
270 | 269 |
271 void RemoteChannelMain::DidCompleteSwapBuffers() { | 270 void RemoteChannelMain::DidCompleteSwapBuffers() { |
272 proxy_main_->DidCompleteSwapBuffers(); | 271 proxy_main_->DidCompleteSwapBuffers(); |
273 } | 272 } |
274 | 273 |
275 base::SingleThreadTaskRunner* RemoteChannelMain::MainThreadTaskRunner() const { | 274 base::SingleThreadTaskRunner* RemoteChannelMain::MainThreadTaskRunner() const { |
276 return task_runner_provider_->MainThreadTaskRunner(); | 275 return task_runner_provider_->MainThreadTaskRunner(); |
277 } | 276 } |
278 | 277 |
279 } // namespace cc | 278 } // namespace cc |
OLD | NEW |