diff options
author | bungeman <bungeman@google.com> | 2015-01-27 05:39:10 -0800 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-01-27 05:39:10 -0800 |
commit | 5f213d9627d2eefa7da81cd97f36754f75eb4ae9 (patch) | |
tree | ab4712f955c73a4a8d97a9910176b12902dde642 /src/core/SkFontDescriptor.h | |
parent | dc14fa4ec7739465d9bb9dbf1f0e537c80ad867f (diff) |
SkTypeface to use SkStreamAsset.
SkTypeface already requires typeface streams to support SkStreamAsset
in practice, and in practice all users are already supplying them.
Review URL: https://codereview.chromium.org/869763002
Diffstat (limited to 'src/core/SkFontDescriptor.h')
-rw-r--r-- | src/core/SkFontDescriptor.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/core/SkFontDescriptor.h b/src/core/SkFontDescriptor.h index aafbe84dec..13f9cb7257 100644 --- a/src/core/SkFontDescriptor.h +++ b/src/core/SkFontDescriptor.h @@ -29,7 +29,7 @@ public: const char* getFontFileName() const { return fFontFileName.c_str(); } bool hasFontData() const { return fFontData.get() != NULL; } // Transfers ownership to the caller. - SkStream* transferFontData() { return fFontData.detach(); } + SkStreamAsset* transferFontData() { return fFontData.detach(); } int getFontIndex() const { return fFontIndex; } void setFamilyName(const char* name) { fFamilyName.set(name); } @@ -39,7 +39,7 @@ public: /** Set the font data only if it is necessary for serialization. * This method takes ownership of the stream (both reference and cursor). */ - void setFontData(SkStream* stream) { fFontData.reset(stream); } + void setFontData(SkStreamAsset* stream) { fFontData.reset(stream); } void setFontIndex(int index) { fFontIndex = index; } private: @@ -47,7 +47,7 @@ private: SkString fFullName; SkString fPostscriptName; SkString fFontFileName; - SkAutoTDelete<SkStream> fFontData; + SkAutoTDelete<SkStreamAsset> fFontData; int fFontIndex; SkTypeface::Style fStyle; |