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

Unified Diff: cc/trees/layer_tree_host_impl.cc

Issue 812543002: Update from https://crrev.com/308331 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/trees/layer_tree_host_client.h ('k') | cc/trees/layer_tree_host_impl_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/trees/layer_tree_host_impl.cc
diff --git a/cc/trees/layer_tree_host_impl.cc b/cc/trees/layer_tree_host_impl.cc
index dd485ba6b759e709edb3ac1f02311cbdbf6012a8..ea8a29f46560dbaf88d13c08f9247dd7c3da857a 100644
--- a/cc/trees/layer_tree_host_impl.cc
+++ b/cc/trees/layer_tree_host_impl.cc
@@ -1589,11 +1589,13 @@ void LayerTreeHostImpl::SetUseGpuRasterization(bool use_gpu) {
if (use_gpu == use_gpu_rasterization_)
return;
+ // Note that this must happen first, in case the rest of the calls want to
+ // query the new state of |use_gpu_rasterization_|.
use_gpu_rasterization_ = use_gpu;
- ReleaseTreeResources();
- // Replace existing tile manager with another one that uses appropriate
- // rasterizer.
+ // Clean up and replace existing tile manager with another one that uses
+ // appropriate rasterizer.
+ ReleaseTreeResources();
if (tile_manager_) {
DestroyTileManager();
CreateAndSetTileManager();
@@ -1964,8 +1966,7 @@ void LayerTreeHostImpl::CreateAndSetTileManager() {
: settings_.scheduled_raster_task_limit;
tile_manager_ = TileManager::Create(
this, task_runner, resource_pool_.get(),
- tile_task_worker_pool_->AsTileTaskRunner(),
- rendering_stats_instrumentation_, scheduled_raster_task_limit);
+ tile_task_worker_pool_->AsTileTaskRunner(), scheduled_raster_task_limit);
UpdateTileManagerMemoryPolicy(ActualManagedMemoryPolicy());
}
« no previous file with comments | « cc/trees/layer_tree_host_client.h ('k') | cc/trees/layer_tree_host_impl_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698