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

Unified Diff: src/animator/SkAnimator.cpp

Issue 2339273002: SkFontData to use smart pointers. (Closed)
Patch Set: Add trivial bodies to the trivial implementations. Created 4 years, 3 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 | « src/animator/SkAnimateMaker.cpp ('k') | src/core/SkFontDescriptor.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/animator/SkAnimator.cpp
diff --git a/src/animator/SkAnimator.cpp b/src/animator/SkAnimator.cpp
index ee75ab14affa8fc49f49df9e0ba6a200054338d6..c5aabbba4bdc62b7dd2ba81fed10ebf5e20e6262 100644
--- a/src/animator/SkAnimator.cpp
+++ b/src/animator/SkAnimator.cpp
@@ -82,10 +82,10 @@ bool SkAnimator::decodeURI(const char uri[]) {
// SkDebugf("animator decode %s\n", uri);
// SkStream* stream = SkStream::GetURIStream(fMaker->fPrefix.c_str(), uri);
- SkAutoTDelete<SkStream> stream(SkStream::NewFromFile(uri));
- if (stream.get()) {
+ std::unique_ptr<SkStream> stream = SkStream::MakeFromFile(uri);
+ if (stream) {
this->setURIBase(uri);
- return decodeStream(stream);
+ return decodeStream(stream.get());
} else {
return false;
}
« no previous file with comments | « src/animator/SkAnimateMaker.cpp ('k') | src/core/SkFontDescriptor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698