Chromium Code Reviews| 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 1394 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1405 Proxy::MainThreadTaskRunner()->PostTask( | 1405 Proxy::MainThreadTaskRunner()->PostTask( |
| 1406 FROM_HERE, base::Bind(&ThreadProxy::DidCompletePageScaleAnimation, | 1406 FROM_HERE, base::Bind(&ThreadProxy::DidCompletePageScaleAnimation, |
| 1407 main_thread_weak_ptr_)); | 1407 main_thread_weak_ptr_)); |
| 1408 } | 1408 } |
| 1409 | 1409 |
| 1410 void ThreadProxy::OnDrawForOutputSurface() { | 1410 void ThreadProxy::OnDrawForOutputSurface() { |
| 1411 DCHECK(IsImplThread()); | 1411 DCHECK(IsImplThread()); |
| 1412 impl().scheduler->OnDrawForOutputSurface(); | 1412 impl().scheduler->OnDrawForOutputSurface(); |
| 1413 } | 1413 } |
| 1414 | 1414 |
| 1415 void ThreadProxy::PostFrameTimingEventsOnImplThread( | |
| 1416 scoped_ptr<FrameTimingTracker::CompositeTimingSet> composite_events, | |
| 1417 scoped_ptr<FrameTimingTracker::MainFrameTimingSet> main_frame_events) { | |
| 1418 DCHECK(IsImplThread()); | |
| 1419 Proxy::MainThreadTaskRunner()->PostTask( | |
| 1420 FROM_HERE, | |
| 1421 base::Bind(&ThreadProxy::PostFrameTimingEvents, main_thread_weak_ptr_, | |
| 1422 base::Passed(composite_events.Pass()), | |
| 1423 base::Passed(main_frame_events.Pass()))); | |
| 1424 } | |
| 1425 | |
| 1426 void ThreadProxy::PostFrameTimingEvents( | |
|
enne (OOO)
2015/06/02 18:13:38
DCHECK(IsMainThread()) here?
MikeB
2015/06/02 21:59:36
Good catch!
| |
| 1427 scoped_ptr<FrameTimingTracker::CompositeTimingSet> composite_events, | |
| 1428 scoped_ptr<FrameTimingTracker::MainFrameTimingSet> main_frame_events) { | |
| 1429 layer_tree_host()->RecordFrameTimingEvents(composite_events.Pass(), | |
| 1430 main_frame_events.Pass()); | |
| 1431 } | |
| 1432 | |
| 1415 } // namespace cc | 1433 } // namespace cc |
| OLD | NEW |