| Index: cc/debug/debug_rect_history.cc
|
| diff --git a/cc/debug/debug_rect_history.cc b/cc/debug/debug_rect_history.cc
|
| index b972b321d8dbecedffc70f07cd95443b43413731..679beafdbb475f501f01adb4bd8c3cb68f3a5258 100644
|
| --- a/cc/debug/debug_rect_history.cc
|
| +++ b/cc/debug/debug_rect_history.cc
|
| @@ -58,6 +58,9 @@ void DebugRectHistory::SaveDebugRectsForCurrentFrame(
|
|
|
| if (debug_state.show_non_occluding_rects)
|
| SaveNonOccludingRects(non_occluding_screen_space_rects);
|
| +
|
| + if (debug_state.show_layer_animation_bounds_rects)
|
| + SaveLayerAnimationBoundsRects(render_surface_layer_list);
|
| }
|
|
|
| void DebugRectHistory::SavePaintRects(LayerImpl* layer) {
|
| @@ -232,4 +235,28 @@ void DebugRectHistory::SaveNonFastScrollableRectsCallback(LayerImpl* layer) {
|
| }
|
| }
|
|
|
| +void DebugRectHistory::SaveLayerAnimationBoundsRects(
|
| + const LayerImplList& render_surface_layer_list) {
|
| + typedef LayerIterator<LayerImpl,
|
| + LayerImplList,
|
| + RenderSurfaceImpl,
|
| + LayerIteratorActions::FrontToBack> LayerIteratorType;
|
| + LayerIteratorType end = LayerIteratorType::End(&render_surface_layer_list);
|
| + for (LayerIteratorType it =
|
| + LayerIteratorType::Begin(&render_surface_layer_list);
|
| + it != end; ++it) {
|
| + if (!it.represents_itself())
|
| + continue;
|
| + gfx::BoxF inflated_bounds;
|
| + if (!(*it)->GetAnimationBounds(&inflated_bounds))
|
| + continue;
|
| +
|
| + debug_rects_.push_back(DebugRect(ANIMATION_BOUNDS_RECT_TYPE,
|
| + gfx::RectF(inflated_bounds.x(),
|
| + inflated_bounds.y(),
|
| + inflated_bounds.width(),
|
| + inflated_bounds.height())));
|
| + }
|
| +}
|
| +
|
| } // namespace cc
|
|
|