| Index: cc/debug/frame_timing_cost_tracker.cc
|
| diff --git a/cc/debug/frame_timing_cost_tracker.cc b/cc/debug/frame_timing_cost_tracker.cc
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..08fbd9ecf932bea6ead9cf4079509b8f1dccdde5
|
| --- /dev/null
|
| +++ b/cc/debug/frame_timing_cost_tracker.cc
|
| @@ -0,0 +1,35 @@
|
| +// Copyright 2014 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#include "cc/debug/frame_timing_cost_tracker.h"
|
| +
|
| +namespace cc {
|
| +
|
| +FrameTimingCostTracker::FrameTimingCostTracker() {
|
| +}
|
| +
|
| +FrameTimingCostTracker::~FrameTimingCostTracker() {
|
| +}
|
| +
|
| +void FrameTimingCostTracker::Start(int source_frame_number) {
|
| + worker_thread_cost_tracker_.set_source_frame_to_track(source_frame_number);
|
| +}
|
| +
|
| +void FrameTimingCostTracker::Stop() {
|
| + worker_thread_cost_tracker_.set_source_frame_to_track(0);
|
| +}
|
| +
|
| +base::TimeDelta FrameTimingCostTracker::GetTotalCost() {
|
| + return worker_thread_cost_tracker_.get_cost();
|
| +}
|
| +
|
| +void FrameTimingCostTracker::ResetCost() {
|
| + worker_thread_cost_tracker_.reset_cost();
|
| +}
|
| +
|
| +WorkerThreadCostTracker* FrameTimingCostTracker::GetWorkerThreadCostTracker() {
|
| + return &worker_thread_cost_tracker_;
|
| +}
|
| +
|
| +} // namespace cc
|
|
|