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/thread_proxy.h" | 5 #include "cc/trees/thread_proxy.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/auto_reset.h" | 10 #include "base/auto_reset.h" |
(...skipping 326 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
337 | 337 |
338 void ThreadProxy::SetMaxSwapsPendingOnImplThread(int max) { | 338 void ThreadProxy::SetMaxSwapsPendingOnImplThread(int max) { |
339 impl().scheduler->SetMaxSwapsPending(max); | 339 impl().scheduler->SetMaxSwapsPending(max); |
340 } | 340 } |
341 | 341 |
342 void ThreadProxy::DidSwapBuffersOnImplThread() { | 342 void ThreadProxy::DidSwapBuffersOnImplThread() { |
343 impl().scheduler->DidSwapBuffers(); | 343 impl().scheduler->DidSwapBuffers(); |
344 } | 344 } |
345 | 345 |
346 void ThreadProxy::DidSwapBuffersCompleteOnImplThread() { | 346 void ThreadProxy::DidSwapBuffersCompleteOnImplThread() { |
347 TRACE_EVENT0("cc,benchmark", | 347 TRACE_EVENT0("cc", "ThreadProxy::DidSwapBuffersCompleteOnImplThread"); |
348 "ThreadProxy::DidSwapBuffersCompleteOnImplThread"); | |
349 DCHECK(IsImplThread()); | 348 DCHECK(IsImplThread()); |
350 impl().scheduler->DidSwapBuffersComplete(); | 349 impl().scheduler->DidSwapBuffersComplete(); |
351 Proxy::MainThreadTaskRunner()->PostTask( | 350 Proxy::MainThreadTaskRunner()->PostTask( |
352 FROM_HERE, | 351 FROM_HERE, |
353 base::Bind(&ThreadProxy::DidCompleteSwapBuffers, main_thread_weak_ptr_)); | 352 base::Bind(&ThreadProxy::DidCompleteSwapBuffers, main_thread_weak_ptr_)); |
354 } | 353 } |
355 | 354 |
356 void ThreadProxy::WillBeginImplFrame(const BeginFrameArgs& args) { | 355 void ThreadProxy::WillBeginImplFrame(const BeginFrameArgs& args) { |
357 impl().layer_tree_host_impl->WillBeginImplFrame(args); | 356 impl().layer_tree_host_impl->WillBeginImplFrame(args); |
358 } | 357 } |
(...skipping 989 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1348 | 1347 |
1349 impl().timing_history.DidActivateSyncTree(); | 1348 impl().timing_history.DidActivateSyncTree(); |
1350 } | 1349 } |
1351 | 1350 |
1352 void ThreadProxy::DidPrepareTiles() { | 1351 void ThreadProxy::DidPrepareTiles() { |
1353 DCHECK(IsImplThread()); | 1352 DCHECK(IsImplThread()); |
1354 impl().scheduler->DidPrepareTiles(); | 1353 impl().scheduler->DidPrepareTiles(); |
1355 } | 1354 } |
1356 | 1355 |
1357 } // namespace cc | 1356 } // namespace cc |
OLD | NEW |