Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2682)

Unified Diff: cc/test/fake_content_layer_client.cc

Issue 14205005: cc: Only consider layer clipped content rect for analysis (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: linker fixes on windows Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/test/fake_content_layer_client.h ('k') | cc/test/fake_picture_pile_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/test/fake_content_layer_client.cc
diff --git a/cc/test/fake_content_layer_client.cc b/cc/test/fake_content_layer_client.cc
index cf82de6b7720c409fa3dd62ad2fe5596e78d7e07..715376646534bbf7c7b9e0d8532848b4f3ac0692 100644
--- a/cc/test/fake_content_layer_client.cc
+++ b/cc/test/fake_content_layer_client.cc
@@ -20,11 +20,15 @@ void FakeContentLayerClient::PaintContents(SkCanvas* canvas,
if (paint_all_opaque_)
*opaque_rect = rect;
- SkPaint paint;
- for (RectVector::const_iterator rect_it = draw_rects_.begin();
- rect_it < draw_rects_.end(); rect_it++) {
- SkRect draw_rect = SkRect::MakeXYWH(rect_it->x(), rect_it->y(),
- rect_it->width(), rect_it->height());
+ for (RectPaintVector::const_iterator it = draw_rects_.begin();
+ it < draw_rects_.end(); ++it) {
+ gfx::Rect rect = it->first;
+ SkPaint paint = it->second;
+ SkRect draw_rect = SkRect::MakeXYWH(
+ rect.x(),
+ rect.y(),
+ rect.width(),
+ rect.height());
canvas->drawRect(draw_rect, paint);
}
}
« no previous file with comments | « cc/test/fake_content_layer_client.h ('k') | cc/test/fake_picture_pile_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698