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 407 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
418 // This needs to be called early so that we don't clamp with incorrect max | 418 // This needs to be called early so that we don't clamp with incorrect max |
419 // offsets when UpdateViewportContainerSizes is called from e.g. | 419 // offsets when UpdateViewportContainerSizes is called from e.g. |
420 // PushTopControls | 420 // PushTopControls |
421 target_tree->UpdatePropertyTreesForBoundsDelta(); | 421 target_tree->UpdatePropertyTreesForBoundsDelta(); |
422 | 422 |
423 if (next_activation_forces_redraw_) { | 423 if (next_activation_forces_redraw_) { |
424 target_tree->ForceRedrawNextActivation(); | 424 target_tree->ForceRedrawNextActivation(); |
425 next_activation_forces_redraw_ = false; | 425 next_activation_forces_redraw_ = false; |
426 } | 426 } |
427 | 427 |
428 target_tree->PassSwapPromises(std::move(swap_promise_list_)); | 428 { |
| 429 std::vector<std::unique_ptr<SwapPromise>> to_pass; |
| 430 swap_promise_list_.swap(to_pass); |
| 431 target_tree->PassSwapPromises(std::move(to_pass)); |
| 432 } |
429 | 433 |
430 target_tree->set_top_controls_shrink_blink_size( | 434 target_tree->set_top_controls_shrink_blink_size( |
431 top_controls_shrink_blink_size_); | 435 top_controls_shrink_blink_size_); |
432 target_tree->set_top_controls_height(top_controls_height_); | 436 target_tree->set_top_controls_height(top_controls_height_); |
433 target_tree->PushTopControls(nullptr); | 437 target_tree->PushTopControls(nullptr); |
434 | 438 |
435 // Active tree already shares the page_scale_factor object with pending | 439 // Active tree already shares the page_scale_factor object with pending |
436 // tree so only the limits need to be provided. | 440 // tree so only the limits need to be provided. |
437 target_tree->PushPageScaleFactorAndLimits(nullptr, min_page_scale_factor(), | 441 target_tree->PushPageScaleFactorAndLimits(nullptr, min_page_scale_factor(), |
438 max_page_scale_factor()); | 442 max_page_scale_factor()); |
(...skipping 1626 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2065 | 2069 |
2066 void LayerTreeImpl::ResetAllChangeTracking() { | 2070 void LayerTreeImpl::ResetAllChangeTracking() { |
2067 layers_that_should_push_properties_.clear(); | 2071 layers_that_should_push_properties_.clear(); |
2068 // Iterate over all layers, including masks and replicas. | 2072 // Iterate over all layers, including masks and replicas. |
2069 for (auto& layer : *layers_) | 2073 for (auto& layer : *layers_) |
2070 layer->ResetChangeTracking(); | 2074 layer->ResetChangeTracking(); |
2071 property_trees_.ResetAllChangeTracking(); | 2075 property_trees_.ResetAllChangeTracking(); |
2072 } | 2076 } |
2073 | 2077 |
2074 } // namespace cc | 2078 } // namespace cc |
OLD | NEW |