Add alternate SkPicture::clone
authorrobertphillips <robertphillips@google.com>
Thu, 10 Jul 2014 21:10:58 +0000 (14:10 -0700)
committerCommit bot <commit-bot@chromium.org>
Thu, 10 Jul 2014 21:10:58 +0000 (14:10 -0700)
commite372e78223a8ce916d276d6e0420d552fb0267e9
tree3c99478ae4c10a5de482c0ffa07ff6b65a7b2bca
parent53d435990bdb4d14df78013da45a9364d0287ebe
Add alternate SkPicture::clone

This adds an alternate version of SkPicture::clone for two reasons:

1) Chromium uses the SkPicture copy constructor to unpack the pictures from the old-style clone interface (and I would like to remove the copy ctor)

2) This is part of the long term plan to wean Chrome off of cloning. Once pictures are thread safe we will switch the new SkPicture::clone call to just return 'this'. From there it is a small step to removing clone entirely.

Note that the two versions of clone() is temporary. Once this is landed (and rolled) I will land a Chrome-side patch to remove their use of the old interface (Use new SkPicture::clone interface - https://codereview.chromium.org/380323002/)

R=mtklein@google.com, reed@google.com

Author: robertphillips@google.com

Review URL: https://codereview.chromium.org/381193002
include/core/SkPicture.h
src/core/SkPicture.cpp