diff options
author | commit-bot@chromium.org <commit-bot@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2014-05-29 15:57:11 +0000 |
---|---|---|
committer | commit-bot@chromium.org <commit-bot@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2014-05-29 15:57:11 +0000 |
commit | 2246e325b8710389d8f718843356e410f683dd25 (patch) | |
tree | 24149dedd8b1fb5775c9c339c5b05753e51685b7 | |
parent | 8de5b7b8b7aa93ce875fca8c6de11a842d7d563a (diff) |
Make SkPictureRecorder::partialReplay const
This will make it easier to integrate this into Android's use case.
R=reed@google.com
Author: robertphillips@google.com
Review URL: https://codereview.chromium.org/307693003
git-svn-id: http://skia.googlecode.com/svn/trunk@14957 2bbb7eff-a529-9590-31e7-b0007b416f81
-rw-r--r-- | include/core/SkPictureRecorder.h | 2 | ||||
-rw-r--r-- | src/core/SkPictureRecorder.cpp | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/include/core/SkPictureRecorder.h b/include/core/SkPictureRecorder.h index 8284c7d906..d619561dd2 100644 --- a/include/core/SkPictureRecorder.h +++ b/include/core/SkPictureRecorder.h @@ -105,7 +105,7 @@ private: */ friend class AndroidPicture; friend class SkPictureRecorderReplayTester; // for unit testing - void partialReplay(SkCanvas* canvas); + void partialReplay(SkCanvas* canvas) const; #endif SkAutoTUnref<SkPicture> fPicture; diff --git a/src/core/SkPictureRecorder.cpp b/src/core/SkPictureRecorder.cpp index 6fa9a06067..1589ec0536 100644 --- a/src/core/SkPictureRecorder.cpp +++ b/src/core/SkPictureRecorder.cpp @@ -20,7 +20,7 @@ SkCanvas* SkPictureRecorder::beginRecording(int width, int height, } #ifdef SK_BUILD_FOR_ANDROID -void SkPictureRecorder::partialReplay(SkCanvas* canvas) { +void SkPictureRecorder::partialReplay(SkCanvas* canvas) const { if (NULL == fPicture.get() || NULL == canvas) { // Not recording or nothing to replay into return; @@ -28,7 +28,7 @@ void SkPictureRecorder::partialReplay(SkCanvas* canvas) { SkASSERT(NULL != fPicture->fRecord); - SkAutoTDelete<SkPicturePlayback> playback(SkPicture::FakeEndRecording(fPicture, + SkAutoTDelete<SkPicturePlayback> playback(SkPicture::FakeEndRecording(fPicture.get(), *fPicture->fRecord, false)); playback->draw(*canvas, NULL); |