Chromium Code Reviews| Index: cc/picture_layer_impl.cc |
| diff --git a/cc/picture_layer_impl.cc b/cc/picture_layer_impl.cc |
| index 824a320210c8334ba06f197759f1d6f5b753a7a4..d8cbe1dd17bba16f1decdc8c2c2a1f2662b1618c 100644 |
| --- a/cc/picture_layer_impl.cc |
| +++ b/cc/picture_layer_impl.cc |
| @@ -115,8 +115,11 @@ void PictureLayerImpl::appendQuads(QuadSink& quadSink, |
| ++iter) { |
| SkColor color; |
| float width; |
| - if (*iter && iter->GetResourceId()) { |
| - if (iter->priority(ACTIVE_TREE).resolution == HIGH_RESOLUTION) { |
| + if (*iter && iter->is_ready_to_draw()) { |
|
Tom Hudson
2013/02/27 14:49:36
You've changed the condition here; is it just for
|
| + if (iter->is_solid_color() || iter->is_transparent()) { |
| + color = DebugColors::SolidColorTileBorderColor(); |
| + width = DebugColors::SolidColorTileBorderWidth(layerTreeImpl()); |
| + } else if (iter->priority(ACTIVE_TREE).resolution == HIGH_RESOLUTION) { |
| color = DebugColors::HighResTileBorderColor(); |
| width = DebugColors::HighResTileBorderWidth(layerTreeImpl()); |
| } else if (iter->priority(ACTIVE_TREE).resolution == LOW_RESOLUTION) { |
| @@ -159,6 +162,21 @@ void PictureLayerImpl::appendQuads(QuadSink& quadSink, |
| gfx::Rect geometry_rect = iter.geometry_rect(); |
| + if (*iter && iter->is_solid_color()) { |
| + scoped_ptr<SolidColorDrawQuad> quad = SolidColorDrawQuad::Create(); |
| + quad->SetNew(sharedQuadState, |
| + geometry_rect, |
| + iter->get_solid_color()); |
| + |
| + quadSink.append(quad.PassAs<DrawQuad>(), appendQuadsData); |
| + |
| + if (!seen_tilings.size() || seen_tilings.back() != iter.CurrentTiling()) |
| + seen_tilings.push_back(iter.CurrentTiling()); |
| + continue; |
| + } |
| + else if (*iter && iter->is_transparent()) { |
|
Tom Hudson
2013/02/27 14:49:36
nit: else on same line as } ?
|
| + continue; |
| + } |
| if (!resource) { |
| if (drawCheckerboardForMissingTiles()) { |
| // TODO(enne): Figure out how to show debug "invalidated checker" color |
| @@ -525,7 +543,7 @@ bool PictureLayerImpl::areVisibleResourcesReady() const { |
| iter; |
| ++iter) { |
| // A null tile (i.e. no recording) is considered "ready". |
| - if (!*iter || iter->GetResourceId()) |
| + if (!*iter || iter->is_ready_to_draw()) |
| missing_region.Subtract(iter.geometry_rect()); |
| } |
| } |