| 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.h" | 5 #include "cc/trees/layer_tree_host.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 1214 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1225 ElementListType list_type, | 1225 ElementListType list_type, |
| 1226 Layer* layer) { | 1226 Layer* layer) { |
| 1227 mutator_host_->UnregisterElement(element_id, list_type); | 1227 mutator_host_->UnregisterElement(element_id, list_type); |
| 1228 | 1228 |
| 1229 if (layer->element_id()) { | 1229 if (layer->element_id()) { |
| 1230 element_layers_map_.erase(layer->element_id()); | 1230 element_layers_map_.erase(layer->element_id()); |
| 1231 } | 1231 } |
| 1232 } | 1232 } |
| 1233 | 1233 |
| 1234 static void SetElementIdForTesting(Layer* layer) { | 1234 static void SetElementIdForTesting(Layer* layer) { |
| 1235 layer->SetElementId(LayerIdToElementIdForTesting(layer->id())); | 1235 layer->SetElementId(layer->id()); |
| 1236 } | 1236 } |
| 1237 | 1237 |
| 1238 void LayerTreeHost::SetElementIdsForTesting() { | 1238 void LayerTreeHost::SetElementIdsForTesting() { |
| 1239 LayerTreeHostCommon::CallFunctionForEveryLayer(this, SetElementIdForTesting); | 1239 LayerTreeHostCommon::CallFunctionForEveryLayer(this, SetElementIdForTesting); |
| 1240 } | 1240 } |
| 1241 | 1241 |
| 1242 void LayerTreeHost::BuildPropertyTreesForTesting() { | 1242 void LayerTreeHost::BuildPropertyTreesForTesting() { |
| 1243 gfx::Transform identity_transform; | 1243 gfx::Transform identity_transform; |
| 1244 PropertyTreeBuilder::BuildPropertyTrees( | 1244 PropertyTreeBuilder::BuildPropertyTrees( |
| 1245 root_layer(), page_scale_layer(), inner_viewport_scroll_layer(), | 1245 root_layer(), page_scale_layer(), inner_viewport_scroll_layer(), |
| (...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1439 void LayerTreeHost::SetNeedsDisplayOnAllLayers() { | 1439 void LayerTreeHost::SetNeedsDisplayOnAllLayers() { |
| 1440 for (auto* layer : *this) | 1440 for (auto* layer : *this) |
| 1441 layer->SetNeedsDisplay(); | 1441 layer->SetNeedsDisplay(); |
| 1442 } | 1442 } |
| 1443 | 1443 |
| 1444 void LayerTreeHost::SetHasCopyRequest(bool has_copy_request) { | 1444 void LayerTreeHost::SetHasCopyRequest(bool has_copy_request) { |
| 1445 has_copy_request_ = has_copy_request; | 1445 has_copy_request_ = has_copy_request; |
| 1446 } | 1446 } |
| 1447 | 1447 |
| 1448 } // namespace cc | 1448 } // namespace cc |
| OLD | NEW |