summaryrefslogtreecommitdiffstats
path: root/cc/trees/layer_tree_host_common.cc
diff options
context:
space:
mode:
authorsunxd <sunxd@chromium.org>2016-01-11 13:01:02 -0800
committerCommit bot <commit-bot@chromium.org>2016-01-11 21:02:26 +0000
commited58688e7629fa3c56470a241bc758fb5fabf081 (patch)
treef6ff71f020fca9532faa6c66548894fa126cd900 /cc/trees/layer_tree_host_common.cc
parent41a523c0dbdf29bf1353036e35004cb35c345b17 (diff)
downloadchromium_src-ed58688e7629fa3c56470a241bc758fb5fabf081.zip
chromium_src-ed58688e7629fa3c56470a241bc758fb5fabf081.tar.gz
chromium_src-ed58688e7629fa3c56470a241bc758fb5fabf081.tar.bz2
cc: Use effect tree to track the number of copy requests
Move num_layer_or_descendants_with_copy_requestfrom layer_tree to effect_tree. This update introduces false positives to the variable: if a layer owns no effect node, it returns the value of its nearest ancestor who owns a effect node. BUG=574192 CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel Review URL: https://codereview.chromium.org/1566913004 Cr-Commit-Position: refs/heads/master@{#368664}
Diffstat (limited to 'cc/trees/layer_tree_host_common.cc')
-rw-r--r--cc/trees/layer_tree_host_common.cc6
1 files changed, 1 insertions, 5 deletions
diff --git a/cc/trees/layer_tree_host_common.cc b/cc/trees/layer_tree_host_common.cc
index c1e3d10..8f66145 100644
--- a/cc/trees/layer_tree_host_common.cc
+++ b/cc/trees/layer_tree_host_common.cc
@@ -595,7 +595,7 @@ static inline bool SubtreeShouldBeSkipped(LayerImpl* layer,
// When we need to do a readback/copy of a layer's output, we can not skip
// it or any of its ancestors.
- if (layer->num_layer_or_descendants_with_copy_request() > 0)
+ if (layer->num_copy_requests_in_target_subtree() > 0)
return false;
// We cannot skip the the subtree if a descendant has a wheel or touch handler
@@ -1088,8 +1088,6 @@ static void PreCalculateMetaInformationInternal(
layer->set_num_unclipped_descendants(
recursive_data->num_unclipped_descendants);
- layer->set_num_layer_or_descendant_with_copy_request(
- recursive_data->num_layer_or_descendants_with_copy_request);
if (IsRootLayer(layer))
layer->layer_tree_host()->SetNeedsMetaInfoRecomputation(false);
@@ -1142,8 +1140,6 @@ static void PreCalculateMetaInformationInternal(
(recursive_data->num_layer_or_descendants_with_input_handler != 0));
// TODO(enne): this should be synced from the main thread, so is only
// for tests constructing layers on the compositor thread.
- layer->set_num_layer_or_descendant_with_copy_request(
- recursive_data->num_layer_or_descendants_with_copy_request);
layer->SetNumDescendantsThatDrawContent(
recursive_data->num_descendants_that_draw_content);