Chromium Code Reviews| Index: cc/resources/picture.cc |
| diff --git a/cc/resources/picture.cc b/cc/resources/picture.cc |
| index a19fd33f3a0724906b5fad324c0bd7d3a5fc28ee..551d5d175e45b29e9e8193e75a49e1c0362e2037 100644 |
| --- a/cc/resources/picture.cc |
| +++ b/cc/resources/picture.cc |
| @@ -231,15 +231,12 @@ void Picture::CloneForDrawing(int num_threads) { |
| raster_thread_checker_.DetachFromThread(); |
| if (num_threads > 1) { |
| - scoped_ptr<SkPicture[]> clones(new SkPicture[num_threads - 1]); |
| - picture_->clone(&clones[0], num_threads - 1); |
| - |
| for (int i = 0; i < num_threads - 1; i++) { |
| - scoped_refptr<Picture> clone = make_scoped_refptr( |
| - new Picture(skia::AdoptRef(new SkPicture(clones[i])), |
| - layer_rect_, |
| - opaque_rect_, |
| - pixel_refs_)); |
| + scoped_refptr<Picture> clone = |
| + make_scoped_refptr(new Picture(skia::AdoptRef(picture_->clone()), |
|
danakj
2014/07/11 15:30:40
nit: FWIW make_scoped_refptr is redundant, that co
robertphillips
2014/07/11 15:59:42
Done.
|
| + layer_rect_, |
| + opaque_rect_, |
| + pixel_refs_)); |
| clones_.push_back(clone); |
| clone->EmitTraceSnapshotAlias(this); |