Chromium Code Reviews| Index: cc/layer_tree_impl.cc |
| diff --git a/cc/layer_tree_impl.cc b/cc/layer_tree_impl.cc |
| index b0d071efd64d7bf84ccca61ad9c15dd0fc246474..c3cb7089b3046d9a90814bf695a5d9dbd15dd423 100644 |
| --- a/cc/layer_tree_impl.cc |
| +++ b/cc/layer_tree_impl.cc |
| @@ -29,6 +29,7 @@ LayerTreeImpl::LayerTreeImpl(LayerTreeHostImpl* layer_tree_host_impl) |
| contents_textures_purged_(false), |
| viewport_size_invalid_(false), |
| needs_update_draw_properties_(true), |
| + needs_update_tile_priorities_(false), |
| needs_full_tree_sync_(true) { |
| } |
| @@ -219,13 +220,17 @@ struct UpdateTilePrioritiesForLayer { |
| void LayerTreeImpl::UpdateDrawProperties(UpdateDrawPropertiesReason reason) { |
| if (!needs_update_draw_properties_) { |
| - if (reason == UPDATE_ACTIVE_TREE_FOR_DRAW && RootLayer()) |
| + if (needs_update_tile_priorities_ && RootLayer()) { |
| + DCHECK_EQ(UPDATE_ACTIVE_TREE_FOR_DRAW, reason); |
|
enne (OOO)
2013/03/04 20:16:39
The change that added this UpdateDrawProperties re
|
| LayerTreeHostCommon::callFunctionForSubtree<UpdateTilePrioritiesForLayer>( |
| RootLayer()); |
| + needs_update_tile_priorities_ = false; |
| + } |
| return; |
| } |
| needs_update_draw_properties_ = false; |
| + needs_update_tile_priorities_ = true; |
| render_surface_layer_list_.clear(); |
| // For maxTextureSize. |
| @@ -255,6 +260,9 @@ void LayerTreeImpl::UpdateDrawProperties(UpdateDrawPropertiesReason reason) { |
| settings().canUseLCDText, |
| render_surface_layer_list_, |
| update_tile_priorities); |
| + |
| + if (update_tile_priorities) |
| + needs_update_tile_priorities_ = false; |
| } |
| DCHECK(!needs_update_draw_properties_) << |