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

Unified Diff: gm/mixedtextblobs.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 | « gm/gammatext.cpp ('k') | gm/pdf_never_embed.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gm/mixedtextblobs.cpp
diff --git a/gm/mixedtextblobs.cpp b/gm/mixedtextblobs.cpp
index e66e73caf3f0915e95ad59ed8a5d7cb026cac72e..9a9bded1db097775791cfd9580528e97e71c4a0e 100644
--- a/gm/mixedtextblobs.cpp
+++ b/gm/mixedtextblobs.cpp
@@ -39,9 +39,9 @@ public:
protected:
void onOnceBeforeDraw() override {
- sk_tool_utils::emoji_typeface(&fEmojiTypeface);
+ fEmojiTypeface = sk_tool_utils::emoji_typeface();
fEmojiText = sk_tool_utils::emoji_sample_text();
- fReallyBigATypeface.reset(GetResourceAsTypeface("/fonts/ReallyBigA.ttf"));
+ fReallyBigATypeface = MakeResourceAsTypeface("/fonts/ReallyBigA.ttf");
SkTextBlobBuilder builder;
@@ -150,8 +150,8 @@ protected:
}
private:
- SkAutoTUnref<SkTypeface> fEmojiTypeface;
- SkAutoTUnref<SkTypeface> fReallyBigATypeface;
+ sk_sp<SkTypeface> fEmojiTypeface;
+ sk_sp<SkTypeface> fReallyBigATypeface;
const char* fEmojiText;
SkAutoTUnref<const SkTextBlob> fBlob;
« no previous file with comments | « gm/gammatext.cpp ('k') | gm/pdf_never_embed.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698