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 <stddef.h> | 7 #include <stddef.h> |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <algorithm> | 10 #include <algorithm> |
(...skipping 466 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
477 // frame. | 477 // frame. |
478 SetNeedsRedraw(); | 478 SetNeedsRedraw(); |
479 } | 479 } |
480 } | 480 } |
481 } | 481 } |
482 | 482 |
483 bool LayerTreeHostImpl::Mutate(base::TimeTicks monotonic_time) { | 483 bool LayerTreeHostImpl::Mutate(base::TimeTicks monotonic_time) { |
484 if (!mutator_) | 484 if (!mutator_) |
485 return false; | 485 return false; |
486 TRACE_EVENT0("compositor-worker", "LayerTreeHostImpl::Mutate"); | 486 TRACE_EVENT0("compositor-worker", "LayerTreeHostImpl::Mutate"); |
487 if (mutator_->Mutate(monotonic_time)) | 487 if (mutator_->Mutate(monotonic_time, active_tree())) |
488 client_->SetNeedsOneBeginImplFrameOnImplThread(); | 488 client_->SetNeedsOneBeginImplFrameOnImplThread(); |
489 return true; | 489 return true; |
490 } | 490 } |
491 | 491 |
492 void LayerTreeHostImpl::SetNeedsMutate() { | 492 void LayerTreeHostImpl::SetNeedsMutate() { |
493 TRACE_EVENT0("compositor-worker", "LayerTreeHostImpl::SetNeedsMutate"); | 493 TRACE_EVENT0("compositor-worker", "LayerTreeHostImpl::SetNeedsMutate"); |
494 client_->SetNeedsOneBeginImplFrameOnImplThread(); | 494 client_->SetNeedsOneBeginImplFrameOnImplThread(); |
495 } | 495 } |
496 | 496 |
497 bool LayerTreeHostImpl::PrepareTiles() { | 497 bool LayerTreeHostImpl::PrepareTiles() { |
(...skipping 3531 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4029 const { | 4029 const { |
4030 return fixed_raster_scale_attempted_scale_change_history_.count() >= | 4030 return fixed_raster_scale_attempted_scale_change_history_.count() >= |
4031 kFixedRasterScaleAttemptedScaleChangeThreshold; | 4031 kFixedRasterScaleAttemptedScaleChangeThreshold; |
4032 } | 4032 } |
4033 | 4033 |
4034 void LayerTreeHostImpl::SetFixedRasterScaleAttemptedToChangeScale() { | 4034 void LayerTreeHostImpl::SetFixedRasterScaleAttemptedToChangeScale() { |
4035 fixed_raster_scale_attempted_scale_change_history_.set(0); | 4035 fixed_raster_scale_attempted_scale_change_history_.set(0); |
4036 } | 4036 } |
4037 | 4037 |
4038 } // namespace cc | 4038 } // namespace cc |
OLD | NEW |