| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2015 Google Inc. | 2 * Copyright 2015 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 #include "SkTypes.h" | 7 #include "SkTypes.h" |
| 8 #if defined(SK_BUILD_FOR_ANDROID) | 8 #if defined(SK_BUILD_FOR_ANDROID) |
| 9 | 9 |
| 10 #include "SkFontMgr.h" | 10 #include "SkFontMgr.h" |
| (...skipping 18 matching lines...) Expand all Loading... |
| 29 } | 29 } |
| 30 | 30 |
| 31 SkFontMgr* SkFontMgr::Factory() { | 31 SkFontMgr* SkFontMgr::Factory() { |
| 32 // These globals exist so that Chromium can override the environment. | 32 // These globals exist so that Chromium can override the environment. |
| 33 // TODO: these globals need to be removed, and Chromium use SkFontMgr_New_An
droid instead. | 33 // TODO: these globals need to be removed, and Chromium use SkFontMgr_New_An
droid instead. |
| 34 if ((gTestFontsXml || gTestFallbackFontsXml) && gTestBasePath) { | 34 if ((gTestFontsXml || gTestFallbackFontsXml) && gTestBasePath) { |
| 35 SkFontMgr_Android_CustomFonts custom = { | 35 SkFontMgr_Android_CustomFonts custom = { |
| 36 SkFontMgr_Android_CustomFonts::kOnlyCustom, | 36 SkFontMgr_Android_CustomFonts::kOnlyCustom, |
| 37 gTestBasePath, | 37 gTestBasePath, |
| 38 gTestFontsXml, | 38 gTestFontsXml, |
| 39 gTestFallbackFontsXml | 39 gTestFallbackFontsXml, |
| 40 false /* fIsolated */ |
| 40 }; | 41 }; |
| 41 return SkFontMgr_New_Android(&custom); | 42 return SkFontMgr_New_Android(&custom); |
| 42 } | 43 } |
| 43 | 44 |
| 44 return SkFontMgr_New_Android(nullptr); | 45 return SkFontMgr_New_Android(nullptr); |
| 45 } | 46 } |
| 46 | 47 |
| 47 #endif//defined(SK_BUILD_FOR_ANDROID) | 48 #endif//defined(SK_BUILD_FOR_ANDROID) |
| OLD | NEW |