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_common.h" | 5 #include "cc/trees/layer_tree_host_common.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include <algorithm> | 9 #include <algorithm> |
10 | 10 |
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
133 | 133 |
134 LayerTreeHostCommon::CalcDrawPropsImplInputsForTesting:: | 134 LayerTreeHostCommon::CalcDrawPropsImplInputsForTesting:: |
135 CalcDrawPropsImplInputsForTesting(LayerImpl* root_layer, | 135 CalcDrawPropsImplInputsForTesting(LayerImpl* root_layer, |
136 const gfx::Size& device_viewport_size, | 136 const gfx::Size& device_viewport_size, |
137 LayerImplList* render_surface_layer_list) | 137 LayerImplList* render_surface_layer_list) |
138 : CalcDrawPropsImplInputsForTesting(root_layer, | 138 : CalcDrawPropsImplInputsForTesting(root_layer, |
139 device_viewport_size, | 139 device_viewport_size, |
140 gfx::Transform(), | 140 gfx::Transform(), |
141 render_surface_layer_list) {} | 141 render_surface_layer_list) {} |
142 | 142 |
| 143 LayerTreeHostCommon::ScrollUpdateInfo::ScrollUpdateInfo() |
| 144 : layer_id(Layer::INVALID_ID) {} |
| 145 |
143 bool LayerTreeHostCommon::ScrollUpdateInfo::operator==( | 146 bool LayerTreeHostCommon::ScrollUpdateInfo::operator==( |
144 const LayerTreeHostCommon::ScrollUpdateInfo& other) const { | 147 const LayerTreeHostCommon::ScrollUpdateInfo& other) const { |
145 return layer_id == other.layer_id && scroll_delta == other.scroll_delta; | 148 return layer_id == other.layer_id && scroll_delta == other.scroll_delta; |
146 } | 149 } |
147 | 150 |
148 void LayerTreeHostCommon::ScrollUpdateInfo::ToProtobuf( | 151 void LayerTreeHostCommon::ScrollUpdateInfo::ToProtobuf( |
149 proto::ScrollUpdateInfo* proto) const { | 152 proto::ScrollUpdateInfo* proto) const { |
150 proto->set_layer_id(layer_id); | 153 proto->set_layer_id(layer_id); |
151 Vector2dToProto(scroll_delta, proto->mutable_scroll_delta()); | 154 Vector2dToProto(scroll_delta, proto->mutable_scroll_delta()); |
152 } | 155 } |
(...skipping 536 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
689 | 692 |
690 PropertyTrees* GetPropertyTrees(Layer* layer) { | 693 PropertyTrees* GetPropertyTrees(Layer* layer) { |
691 return layer->layer_tree_host()->property_trees(); | 694 return layer->layer_tree_host()->property_trees(); |
692 } | 695 } |
693 | 696 |
694 PropertyTrees* GetPropertyTrees(LayerImpl* layer) { | 697 PropertyTrees* GetPropertyTrees(LayerImpl* layer) { |
695 return layer->layer_tree_impl()->property_trees(); | 698 return layer->layer_tree_impl()->property_trees(); |
696 } | 699 } |
697 | 700 |
698 } // namespace cc | 701 } // namespace cc |
OLD | NEW |