| OLD | NEW | 
|     1 // Copyright 2014 The Chromium Authors. All rights reserved. |     1 // Copyright 2014 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/draw_property_utils.h" |     5 #include "cc/trees/draw_property_utils.h" | 
|     6  |     6  | 
|     7 #include <stddef.h> |     7 #include <stddef.h> | 
|     8  |     8  | 
|     9 #include <vector> |     9 #include <vector> | 
|    10  |    10  | 
| (...skipping 833 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|   844   const EffectTree& effect_tree = property_trees->effect_tree; |   844   const EffectTree& effect_tree = property_trees->effect_tree; | 
|   845  |   845  | 
|   846   for (auto* layer_impl : *layer_tree_impl) { |   846   for (auto* layer_impl : *layer_tree_impl) { | 
|   847     DCHECK(layer_impl); |   847     DCHECK(layer_impl); | 
|   848     DCHECK(layer_impl->layer_tree_impl()); |   848     DCHECK(layer_impl->layer_tree_impl()); | 
|   849     // TODO(crbug.com/726423) : This is a workaround for crbug.com/725851 to |   849     // TODO(crbug.com/726423) : This is a workaround for crbug.com/725851 to | 
|   850     // avoid crashing when layer_impl is nullptr. This workaround should be |   850     // avoid crashing when layer_impl is nullptr. This workaround should be | 
|   851     // removed as layer_impl should not be nullptr here. |   851     // removed as layer_impl should not be nullptr here. | 
|   852     if (!layer_impl || !layer_impl->HasValidPropertyTreeIndices()) |   852     if (!layer_impl || !layer_impl->HasValidPropertyTreeIndices()) | 
|   853       continue; |   853       continue; | 
 |   854  | 
|   854     if (!IsRootLayer(layer_impl) && |   855     if (!IsRootLayer(layer_impl) && | 
|   855         LayerShouldBeSkippedForDrawPropertiesComputation( |   856         LayerShouldBeSkippedForDrawPropertiesComputation( | 
|   856             layer_impl, transform_tree, effect_tree)) |   857             layer_impl, transform_tree, effect_tree)) | 
|   857       continue; |   858       continue; | 
|   858  |   859  | 
|   859     bool layer_is_drawn = |   860     bool layer_is_drawn = | 
|   860         effect_tree.Node(layer_impl->effect_tree_index())->is_drawn; |   861         effect_tree.Node(layer_impl->effect_tree_index())->is_drawn; | 
|   861  |   862  | 
|   862     if (LayerNeedsUpdate(layer_impl, layer_is_drawn, property_trees)) |   863     if (LayerNeedsUpdate(layer_impl, layer_is_drawn, property_trees)) | 
|   863       visible_layer_list->push_back(layer_impl); |   864       visible_layer_list->push_back(layer_impl); | 
| (...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|  1078 void UpdateElasticOverscroll(PropertyTrees* property_trees, |  1079 void UpdateElasticOverscroll(PropertyTrees* property_trees, | 
|  1079                              const Layer* overscroll_elasticity_layer, |  1080                              const Layer* overscroll_elasticity_layer, | 
|  1080                              const gfx::Vector2dF& elastic_overscroll) { |  1081                              const gfx::Vector2dF& elastic_overscroll) { | 
|  1081   UpdateElasticOverscrollInternal(property_trees, overscroll_elasticity_layer, |  1082   UpdateElasticOverscrollInternal(property_trees, overscroll_elasticity_layer, | 
|  1082                                   elastic_overscroll); |  1083                                   elastic_overscroll); | 
|  1083 } |  1084 } | 
|  1084  |  1085  | 
|  1085 }  // namespace draw_property_utils |  1086 }  // namespace draw_property_utils | 
|  1086  |  1087  | 
|  1087 }  // namespace cc |  1088 }  // namespace cc | 
| OLD | NEW |