| 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/layer_tree_host_impl.h" | 5 #include "cc/trees/layer_tree_host_impl.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <limits> | 8 #include <limits> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 3234 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3245 picture_layers_.push_back(layer); | 3245 picture_layers_.push_back(layer); |
| 3246 } | 3246 } |
| 3247 | 3247 |
| 3248 void LayerTreeHostImpl::UnregisterPictureLayerImpl(PictureLayerImpl* layer) { | 3248 void LayerTreeHostImpl::UnregisterPictureLayerImpl(PictureLayerImpl* layer) { |
| 3249 std::vector<PictureLayerImpl*>::iterator it = | 3249 std::vector<PictureLayerImpl*>::iterator it = |
| 3250 std::find(picture_layers_.begin(), picture_layers_.end(), layer); | 3250 std::find(picture_layers_.begin(), picture_layers_.end(), layer); |
| 3251 DCHECK(it != picture_layers_.end()); | 3251 DCHECK(it != picture_layers_.end()); |
| 3252 picture_layers_.erase(it); | 3252 picture_layers_.erase(it); |
| 3253 } | 3253 } |
| 3254 | 3254 |
| 3255 void LayerTreeHostImpl::AddBeginMainFrameToCommitDurationEstimate( |
| 3256 base::TimeDelta duration, |
| 3257 base::TimeDelta estimate) { |
| 3258 rendering_stats_instrumentation_->AddBeginMainFrameToCommitDuration(duration, |
| 3259 estimate); |
| 3260 } |
| 3261 |
| 3262 void LayerTreeHostImpl::AddCommitToActivateDurationEstimate( |
| 3263 base::TimeDelta duration, |
| 3264 base::TimeDelta estimate) { |
| 3265 rendering_stats_instrumentation_->AddCommitToActivateDuration(duration, |
| 3266 estimate); |
| 3267 } |
| 3268 |
| 3269 void LayerTreeHostImpl::AddDrawDurationEstimate(base::TimeDelta duration, |
| 3270 base::TimeDelta estimate) { |
| 3271 rendering_stats_instrumentation_->AddDrawDuration(duration, estimate); |
| 3272 } |
| 3273 |
| 3255 } // namespace cc | 3274 } // namespace cc |
| OLD | NEW |