diff options
author | reed <reed@google.com> | 2016-09-12 12:01:44 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-09-12 12:01:44 -0700 |
commit | 42943c8aa9c611c18ad0f1a30a27669f3d82239c (patch) | |
tree | deff0bbc59dd92559191c188d73f97b4f9c580aa /include/codec/SkAndroidCodec.h | |
parent | 09524ae42998ece3a8e7973064ab286646511b31 (diff) |
change SkStreams to work with sk_sp<SkData> instead of SkData*
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2333713002
Review-Url: https://codereview.chromium.org/2333713002
Diffstat (limited to 'include/codec/SkAndroidCodec.h')
-rw-r--r-- | include/codec/SkAndroidCodec.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/include/codec/SkAndroidCodec.h b/include/codec/SkAndroidCodec.h index 7fee5be255..c7587b62e9 100644 --- a/include/codec/SkAndroidCodec.h +++ b/include/codec/SkAndroidCodec.h @@ -37,10 +37,11 @@ public: * * The SkPngChunkReader handles unknown chunks in PNGs. * See SkCodec.h for more details. - * - * Will take a ref if it returns a codec, else will not affect the data. */ - static SkAndroidCodec* NewFromData(SkData*, SkPngChunkReader* = NULL); + static SkAndroidCodec* NewFromData(sk_sp<SkData>, SkPngChunkReader* = NULL); + static SkAndroidCodec* NewFromData(SkData* data, SkPngChunkReader* reader) { + return NewFromData(sk_ref_sp(data), reader); + } virtual ~SkAndroidCodec() {} |