OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2014 Google Inc. | 2 * Copyright 2014 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 SkFontMgr_indirect_DEFINED | 8 #ifndef SkFontMgr_indirect_DEFINED |
9 #define SkFontMgr_indirect_DEFINED | 9 #define SkFontMgr_indirect_DEFINED |
10 | 10 |
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
88 }; | 88 }; |
89 /** | 89 /** |
90 * This cache is essentially { dataId: { ttcIndex: typeface } } | 90 * This cache is essentially { dataId: { ttcIndex: typeface } } |
91 * For data caching we want a mapping from data id to weak references to | 91 * For data caching we want a mapping from data id to weak references to |
92 * typefaces with that data id. By storing the index next to the typeface, | 92 * typefaces with that data id. By storing the index next to the typeface, |
93 * this data cache also acts as a typeface cache. | 93 * this data cache also acts as a typeface cache. |
94 */ | 94 */ |
95 mutable SkTArray<DataEntry> fDataCache; | 95 mutable SkTArray<DataEntry> fDataCache; |
96 mutable SkMutex fDataCacheMutex; | 96 mutable SkMutex fDataCacheMutex; |
97 | 97 |
98 mutable SkAutoTUnref<SkDataTable> fFamilyNames; | 98 mutable sk_sp<SkDataTable> fFamilyNames; |
99 mutable SkOnce fFamilyNamesInitOnce; | 99 mutable SkOnce fFamilyNamesInitOnce; |
100 static void set_up_family_names(const SkFontMgr_Indirect* self); | 100 static void set_up_family_names(const SkFontMgr_Indirect* self); |
101 | 101 |
102 friend class SkStyleSet_Indirect; | 102 friend class SkStyleSet_Indirect; |
103 }; | 103 }; |
104 | 104 |
105 #endif | 105 #endif |
OLD | NEW |