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

Unified Diff: tools/Resources.cpp

Issue 1933393002: Move SkTypeface to sk_sp. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Restore deleted Android code. Created 4 years, 7 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 | « tools/Resources.h ('k') | tools/debugger/SkDrawCommand.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/Resources.cpp
diff --git a/tools/Resources.cpp b/tools/Resources.cpp
index 0117404ac27fda9c7933a085ad405fe8e99ed6fe..6d3054ab3346689ac6e7373ced96e2e072add9bb 100644
--- a/tools/Resources.cpp
+++ b/tools/Resources.cpp
@@ -49,10 +49,10 @@ SkStreamAsset* GetResourceAsStream(const char* resource) {
}
}
-SkTypeface* GetResourceAsTypeface(const char* resource) {
+sk_sp<SkTypeface> MakeResourceAsTypeface(const char* resource) {
SkAutoTDelete<SkStreamAsset> stream(GetResourceAsStream(resource));
if (!stream) {
return nullptr;
}
- return SkTypeface::CreateFromStream(stream.release());
+ return SkTypeface::MakeFromStream(stream.release());
}
« no previous file with comments | « tools/Resources.h ('k') | tools/debugger/SkDrawCommand.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698