| 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 3729 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3740 return; | 3740 return; |
| 3741 input_handler_client_->UpdateRootLayerStateForSynchronousInputHandler( | 3741 input_handler_client_->UpdateRootLayerStateForSynchronousInputHandler( |
| 3742 active_tree_->TotalScrollOffset(), active_tree_->TotalMaxScrollOffset(), | 3742 active_tree_->TotalScrollOffset(), active_tree_->TotalMaxScrollOffset(), |
| 3743 active_tree_->ScrollableSize(), active_tree_->current_page_scale_factor(), | 3743 active_tree_->ScrollableSize(), active_tree_->current_page_scale_factor(), |
| 3744 active_tree_->min_page_scale_factor(), | 3744 active_tree_->min_page_scale_factor(), |
| 3745 active_tree_->max_page_scale_factor()); | 3745 active_tree_->max_page_scale_factor()); |
| 3746 } | 3746 } |
| 3747 | 3747 |
| 3748 void LayerTreeHostImpl::ScrollAnimationAbort(LayerImpl* layer_impl) { | 3748 void LayerTreeHostImpl::ScrollAnimationAbort(LayerImpl* layer_impl) { |
| 3749 if (animation_host_) | 3749 if (animation_host_) |
| 3750 return animation_host_->ScrollAnimationAbort(); | 3750 return animation_host_->ScrollAnimationAbort(false /* needs_completion */); |
| 3751 | 3751 |
| 3752 layer_impl->layer_animation_controller()->AbortAnimations( | 3752 layer_impl->layer_animation_controller()->AbortAnimations( |
| 3753 TargetProperty::SCROLL_OFFSET); | 3753 TargetProperty::SCROLL_OFFSET); |
| 3754 } | 3754 } |
| 3755 | 3755 |
| 3756 void LayerTreeHostImpl::ScrollAnimationCreate( | 3756 void LayerTreeHostImpl::ScrollAnimationCreate( |
| 3757 ScrollNode* scroll_node, | 3757 ScrollNode* scroll_node, |
| 3758 const gfx::ScrollOffset& target_offset, | 3758 const gfx::ScrollOffset& target_offset, |
| 3759 const gfx::ScrollOffset& current_offset) { | 3759 const gfx::ScrollOffset& current_offset) { |
| 3760 if (animation_host_) | 3760 if (animation_host_) |
| (...skipping 219 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3980 return task_runner_provider_->HasImplThread(); | 3980 return task_runner_provider_->HasImplThread(); |
| 3981 } | 3981 } |
| 3982 | 3982 |
| 3983 bool LayerTreeHostImpl::CommitToActiveTree() const { | 3983 bool LayerTreeHostImpl::CommitToActiveTree() const { |
| 3984 // In single threaded mode we skip the pending tree and commit directly to the | 3984 // In single threaded mode we skip the pending tree and commit directly to the |
| 3985 // active tree. | 3985 // active tree. |
| 3986 return !task_runner_provider_->HasImplThread(); | 3986 return !task_runner_provider_->HasImplThread(); |
| 3987 } | 3987 } |
| 3988 | 3988 |
| 3989 } // namespace cc | 3989 } // namespace cc |
| OLD | NEW |