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

Side by Side Diff: include/ports/SkFontConfigInterface.h

Issue 2211143002: Move to SkDataTable::MakeXXX and sk_sp. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Use bare pointer for global. Created 4 years, 4 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 unified diff | Download patch
« no previous file with comments | « include/core/SkDataTable.h ('k') | include/ports/SkFontMgr_indirect.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2013 Google Inc. 2 * Copyright 2013 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #ifndef SkFontConfigInterface_DEFINED 8 #ifndef SkFontConfigInterface_DEFINED
9 #define SkFontConfigInterface_DEFINED 9 #define SkFontConfigInterface_DEFINED
10 10
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
104 104
105 /** 105 /**
106 * Return a singleton instance of a direct subclass that calls into 106 * Return a singleton instance of a direct subclass that calls into
107 * libfontconfig. This does not affect the refcnt of the returned instance. 107 * libfontconfig. This does not affect the refcnt of the returned instance.
108 * The mutex may be used to guarantee the singleton is only constructed onc e. 108 * The mutex may be used to guarantee the singleton is only constructed onc e.
109 */ 109 */
110 static SkFontConfigInterface* GetSingletonDirectInterface(); 110 static SkFontConfigInterface* GetSingletonDirectInterface();
111 111
112 // New APIS, which have default impls for now (which do nothing) 112 // New APIS, which have default impls for now (which do nothing)
113 113
114 virtual SkDataTable* getFamilyNames() { return SkDataTable::NewEmpty(); } 114 virtual sk_sp<SkDataTable> getFamilyNames() { return SkDataTable::MakeEmpty( ); }
115 typedef SkRefCnt INHERITED; 115 typedef SkRefCnt INHERITED;
116 }; 116 };
117 117
118 /** Creates a SkFontMgr which wraps a SkFontConfigInterface. */ 118 /** Creates a SkFontMgr which wraps a SkFontConfigInterface. */
119 SK_API SkFontMgr* SkFontMgr_New_FCI(SkFontConfigInterface* fci); 119 SK_API SkFontMgr* SkFontMgr_New_FCI(SkFontConfigInterface* fci);
120 120
121 #endif 121 #endif
OLDNEW
« no previous file with comments | « include/core/SkDataTable.h ('k') | include/ports/SkFontMgr_indirect.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698