Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(149)

Side by Side Diff: cc/trees/layer_tree_impl.cc

Issue 2621403003: cc: Don't create SyncedPropety instances on the main thread. (Closed)
Patch Set: win test Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « cc/trees/layer_tree_impl.h ('k') | cc/trees/property_tree.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 408 matching lines...) Expand 10 before | Expand all | Expand 10 after
419 inner_scroll->bounds_delta()); 419 inner_scroll->bounds_delta());
420 } 420 }
421 421
422 void LayerTreeImpl::PushPropertiesTo(LayerTreeImpl* target_tree) { 422 void LayerTreeImpl::PushPropertiesTo(LayerTreeImpl* target_tree) {
423 // The request queue should have been processed and does not require a push. 423 // The request queue should have been processed and does not require a push.
424 DCHECK_EQ(ui_resource_request_queue_.size(), 0u); 424 DCHECK_EQ(ui_resource_request_queue_.size(), 0u);
425 425
426 LayerImpl* layer = target_tree->CurrentlyScrollingLayer(); 426 LayerImpl* layer = target_tree->CurrentlyScrollingLayer();
427 target_tree->SetPropertyTrees(&property_trees_); 427 target_tree->SetPropertyTrees(&property_trees_);
428 target_tree->SetCurrentlyScrollingLayer(layer); 428 target_tree->SetCurrentlyScrollingLayer(layer);
429 target_tree->UpdatePropertyTreeScrollOffset(&property_trees_); 429 target_tree->property_trees()->scroll_tree.PushScrollUpdatesFromPendingTree(
430 &property_trees_, target_tree);
430 431
431 // This needs to be called early so that we don't clamp with incorrect max 432 // This needs to be called early so that we don't clamp with incorrect max
432 // offsets when UpdateViewportContainerSizes is called from e.g. 433 // offsets when UpdateViewportContainerSizes is called from e.g.
433 // PushBrowserControls 434 // PushBrowserControls
434 target_tree->UpdatePropertyTreesForBoundsDelta(); 435 target_tree->UpdatePropertyTreesForBoundsDelta();
435 436
436 if (next_activation_forces_redraw_) { 437 if (next_activation_forces_redraw_) {
437 target_tree->ForceRedrawNextActivation(); 438 target_tree->ForceRedrawNextActivation();
438 next_activation_forces_redraw_ = false; 439 next_activation_forces_redraw_ = false;
439 } 440 }
(...skipping 1644 matching lines...) Expand 10 before | Expand all | Expand 10 after
2084 2085
2085 void LayerTreeImpl::ResetAllChangeTracking() { 2086 void LayerTreeImpl::ResetAllChangeTracking() {
2086 layers_that_should_push_properties_.clear(); 2087 layers_that_should_push_properties_.clear();
2087 // Iterate over all layers, including masks. 2088 // Iterate over all layers, including masks.
2088 for (auto& layer : *layers_) 2089 for (auto& layer : *layers_)
2089 layer->ResetChangeTracking(); 2090 layer->ResetChangeTracking();
2090 property_trees_.ResetAllChangeTracking(); 2091 property_trees_.ResetAllChangeTracking();
2091 } 2092 }
2092 2093
2093 } // namespace cc 2094 } // namespace cc
OLDNEW
« no previous file with comments | « cc/trees/layer_tree_impl.h ('k') | cc/trees/property_tree.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698