| OLD | NEW |
| 1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 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/single_thread_proxy.h" | 5 #include "cc/trees/single_thread_proxy.h" |
| 6 | 6 |
| 7 #include "base/auto_reset.h" | 7 #include "base/auto_reset.h" |
| 8 #include "base/profiler/scoped_tracker.h" | 8 #include "base/profiler/scoped_tracker.h" |
| 9 #include "base/trace_event/trace_event.h" | 9 #include "base/trace_event/trace_event.h" |
| 10 #include "cc/debug/benchmark_instrumentation.h" | 10 #include "cc/debug/benchmark_instrumentation.h" |
| (...skipping 336 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 347 DebugScopedSetImplThread impl(this); | 347 DebugScopedSetImplThread impl(this); |
| 348 | 348 |
| 349 BlockingTaskRunner::CapturePostTasks blocked( | 349 BlockingTaskRunner::CapturePostTasks blocked( |
| 350 blocking_main_thread_task_runner()); | 350 blocking_main_thread_task_runner()); |
| 351 scheduler_on_impl_thread_ = nullptr; | 351 scheduler_on_impl_thread_ = nullptr; |
| 352 layer_tree_host_impl_ = nullptr; | 352 layer_tree_host_impl_ = nullptr; |
| 353 } | 353 } |
| 354 layer_tree_host_ = NULL; | 354 layer_tree_host_ = NULL; |
| 355 } | 355 } |
| 356 | 356 |
| 357 void SingleThreadProxy::OnResourcelessSoftareDrawStateChanged( |
| 358 bool resourceless_draw) { |
| 359 NOTREACHED(); |
| 360 } |
| 361 |
| 357 void SingleThreadProxy::OnCanDrawStateChanged(bool can_draw) { | 362 void SingleThreadProxy::OnCanDrawStateChanged(bool can_draw) { |
| 358 TRACE_EVENT1( | 363 TRACE_EVENT1( |
| 359 "cc", "SingleThreadProxy::OnCanDrawStateChanged", "can_draw", can_draw); | 364 "cc", "SingleThreadProxy::OnCanDrawStateChanged", "can_draw", can_draw); |
| 360 DCHECK(Proxy::IsImplThread()); | 365 DCHECK(Proxy::IsImplThread()); |
| 361 if (scheduler_on_impl_thread_) | 366 if (scheduler_on_impl_thread_) |
| 362 scheduler_on_impl_thread_->SetCanDraw(can_draw); | 367 scheduler_on_impl_thread_->SetCanDraw(can_draw); |
| 363 } | 368 } |
| 364 | 369 |
| 365 void SingleThreadProxy::NotifyReadyToActivate() { | 370 void SingleThreadProxy::NotifyReadyToActivate() { |
| 366 TRACE_EVENT0("cc", "SingleThreadProxy::NotifyReadyToActivate"); | 371 TRACE_EVENT0("cc", "SingleThreadProxy::NotifyReadyToActivate"); |
| (...skipping 526 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 893 << "DidFinishImplFrame called while not inside an impl frame!"; | 898 << "DidFinishImplFrame called while not inside an impl frame!"; |
| 894 inside_impl_frame_ = false; | 899 inside_impl_frame_ = false; |
| 895 #endif | 900 #endif |
| 896 } | 901 } |
| 897 | 902 |
| 898 void SingleThreadProxy::SendBeginFramesToChildren(const BeginFrameArgs& args) { | 903 void SingleThreadProxy::SendBeginFramesToChildren(const BeginFrameArgs& args) { |
| 899 layer_tree_host_->SendBeginFramesToChildren(args); | 904 layer_tree_host_->SendBeginFramesToChildren(args); |
| 900 } | 905 } |
| 901 | 906 |
| 902 } // namespace cc | 907 } // namespace cc |
| OLD | NEW |