| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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/layers/delegated_renderer_layer.h" | 5 #include "cc/layers/delegated_renderer_layer.h" |
| 6 | 6 |
| 7 #include "cc/layers/delegated_renderer_layer_impl.h" | 7 #include "cc/layers/delegated_renderer_layer_impl.h" |
| 8 #include "cc/output/delegated_frame_data.h" | 8 #include "cc/output/delegated_frame_data.h" |
| 9 #include "cc/quads/render_pass_draw_quad.h" | 9 #include "cc/quads/render_pass_draw_quad.h" |
| 10 #include "cc/trees/blocking_task_runner.h" | 10 #include "cc/trees/blocking_task_runner.h" |
| (...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 91 return updated; | 91 return updated; |
| 92 | 92 |
| 93 frame_data_ = | 93 frame_data_ = |
| 94 frame_provider_->GetFrameDataAndRefResources(this, &frame_damage_); | 94 frame_provider_->GetFrameDataAndRefResources(this, &frame_damage_); |
| 95 should_collect_new_frame_ = false; | 95 should_collect_new_frame_ = false; |
| 96 | 96 |
| 97 SetNeedsPushProperties(); | 97 SetNeedsPushProperties(); |
| 98 return true; | 98 return true; |
| 99 } | 99 } |
| 100 | 100 |
| 101 int DelegatedRendererLayer::NumDescendantsThatDrawContent() const { |
| 102 // As per the comment that was originally in |
| 103 // LayerTreeHost::PrecalculateMetaInformation: |
| 104 // Layers with delegated content need to be treated as if they have as |
| 105 // many children as the number of layers they own delegated quads for. |
| 106 // Since we don't know this number right now, we choose one that acts like |
| 107 // infinity for our purposes. |
| 108 return Layer::NumDescendantsThatDrawContent() + 1000; |
| 109 } |
| 110 |
| 101 } // namespace cc | 111 } // namespace cc |
| OLD | NEW |