| 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_impl.h" | 5 #include "cc/trees/layer_tree_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 1176 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1187 return true; | 1187 return true; |
| 1188 } | 1188 } |
| 1189 | 1189 |
| 1190 void LayerTreeImpl::BuildLayerListAndPropertyTreesForTesting() { | 1190 void LayerTreeImpl::BuildLayerListAndPropertyTreesForTesting() { |
| 1191 BuildLayerListForTesting(); | 1191 BuildLayerListForTesting(); |
| 1192 BuildPropertyTreesForTesting(); | 1192 BuildPropertyTreesForTesting(); |
| 1193 } | 1193 } |
| 1194 | 1194 |
| 1195 void LayerTreeImpl::BuildPropertyTreesForTesting() { | 1195 void LayerTreeImpl::BuildPropertyTreesForTesting() { |
| 1196 SetElementIdsForTesting(); | 1196 SetElementIdsForTesting(); |
| 1197 PropertyTreeBuilder::PreCalculateMetaInformationForTesting(layer_list_[0]); | |
| 1198 property_trees_.needs_rebuild = true; | 1197 property_trees_.needs_rebuild = true; |
| 1199 property_trees_.transform_tree.set_source_to_parent_updates_allowed(true); | 1198 property_trees_.transform_tree.set_source_to_parent_updates_allowed(true); |
| 1200 PropertyTreeBuilder::BuildPropertyTrees( | 1199 PropertyTreeBuilder::BuildPropertyTrees( |
| 1201 layer_list_[0], PageScaleLayer(), InnerViewportScrollLayer(), | 1200 layer_list_[0], PageScaleLayer(), InnerViewportScrollLayer(), |
| 1202 OuterViewportScrollLayer(), OverscrollElasticityLayer(), | 1201 OuterViewportScrollLayer(), OverscrollElasticityLayer(), |
| 1203 elastic_overscroll()->Current(IsActiveTree()), | 1202 elastic_overscroll()->Current(IsActiveTree()), |
| 1204 current_page_scale_factor(), device_scale_factor(), | 1203 current_page_scale_factor(), device_scale_factor(), |
| 1205 gfx::Rect(DrawViewportSize()), layer_tree_host_impl_->DrawTransform(), | 1204 gfx::Rect(DrawViewportSize()), layer_tree_host_impl_->DrawTransform(), |
| 1206 &property_trees_); | 1205 &property_trees_); |
| 1207 property_trees_.transform_tree.set_source_to_parent_updates_allowed(false); | 1206 property_trees_.transform_tree.set_source_to_parent_updates_allowed(false); |
| (...skipping 949 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2157 | 2156 |
| 2158 void LayerTreeImpl::ResetAllChangeTracking() { | 2157 void LayerTreeImpl::ResetAllChangeTracking() { |
| 2159 layers_that_should_push_properties_.clear(); | 2158 layers_that_should_push_properties_.clear(); |
| 2160 // Iterate over all layers, including masks. | 2159 // Iterate over all layers, including masks. |
| 2161 for (auto& layer : *layers_) | 2160 for (auto& layer : *layers_) |
| 2162 layer->ResetChangeTracking(); | 2161 layer->ResetChangeTracking(); |
| 2163 property_trees_.ResetAllChangeTracking(); | 2162 property_trees_.ResetAllChangeTracking(); |
| 2164 } | 2163 } |
| 2165 | 2164 |
| 2166 } // namespace cc | 2165 } // namespace cc |
| OLD | NEW |