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/debug/debug_rect_history.h" | 5 #include "cc/debug/debug_rect_history.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include "base/memory/ptr_util.h" | 9 #include "base/memory/ptr_util.h" |
10 #include "cc/base/math_util.h" | 10 #include "cc/base/math_util.h" |
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
93 LayerImpl* render_surface_layer = render_surface_layer_list[surface_index]; | 93 LayerImpl* render_surface_layer = render_surface_layer_list[surface_index]; |
94 RenderSurfaceImpl* render_surface = render_surface_layer->render_surface(); | 94 RenderSurfaceImpl* render_surface = render_surface_layer->render_surface(); |
95 DCHECK(render_surface); | 95 DCHECK(render_surface); |
96 | 96 |
97 const LayerImplList& layer_list = render_surface->layer_list(); | 97 const LayerImplList& layer_list = render_surface->layer_list(); |
98 for (unsigned layer_index = 0; | 98 for (unsigned layer_index = 0; |
99 layer_index < layer_list.size(); | 99 layer_index < layer_list.size(); |
100 ++layer_index) { | 100 ++layer_index) { |
101 LayerImpl* layer = layer_list[layer_index]; | 101 LayerImpl* layer = layer_list[layer_index]; |
102 | 102 |
103 if (LayerTreeHostCommon::RenderSurfaceContributesToTarget<LayerImpl>( | 103 if (layer->render_surface() && layer->render_surface() != render_surface) |
104 layer, render_surface_layer->id())) | |
105 continue; | 104 continue; |
106 | 105 |
107 if (layer == hud_layer) | 106 if (layer == hud_layer) |
108 continue; | 107 continue; |
109 | 108 |
110 if (!layer->LayerPropertyChanged()) | 109 if (!layer->LayerPropertyChanged()) |
111 continue; | 110 continue; |
112 | 111 |
113 debug_rects_.push_back(DebugRect( | 112 debug_rects_.push_back(DebugRect( |
114 PROPERTY_CHANGED_RECT_TYPE, | 113 PROPERTY_CHANGED_RECT_TYPE, |
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
250 debug_rects_.push_back( | 249 debug_rects_.push_back( |
251 DebugRect(ANIMATION_BOUNDS_RECT_TYPE, | 250 DebugRect(ANIMATION_BOUNDS_RECT_TYPE, |
252 gfx::ToEnclosingRect(gfx::RectF(inflated_bounds.x(), | 251 gfx::ToEnclosingRect(gfx::RectF(inflated_bounds.x(), |
253 inflated_bounds.y(), | 252 inflated_bounds.y(), |
254 inflated_bounds.width(), | 253 inflated_bounds.width(), |
255 inflated_bounds.height())))); | 254 inflated_bounds.height())))); |
256 } | 255 } |
257 } | 256 } |
258 | 257 |
259 } // namespace cc | 258 } // namespace cc |
OLD | NEW |