Chromium Code Reviews| Index: content/renderer/renderer_main_platform_delegate_win.cc |
| diff --git a/content/renderer/renderer_main_platform_delegate_win.cc b/content/renderer/renderer_main_platform_delegate_win.cc |
| index 694a5c796f3b671e5a45f26427c8295e7fe055c6..9a2ba3170408c60d9420faba348183c51ba4fb96 100644 |
| --- a/content/renderer/renderer_main_platform_delegate_win.cc |
| +++ b/content/renderer/renderer_main_platform_delegate_win.cc |
| @@ -24,6 +24,7 @@ |
| #include "third_party/icu/source/i18n/unicode/timezone.h" |
| #include "third_party/skia/include/ports/SkFontMgr.h" |
| #include "third_party/skia/include/ports/SkTypeface_win.h" |
| +#include "ui/gfx/hud_font.h" |
| #include "ui/gfx/win/direct_write.h" |
| #include "ui/gfx/win/dpi.h" |
| @@ -55,10 +56,16 @@ void SkiaPreCacheFontCharacters(const LOGFONT& logfont, |
| void WarmupDirectWrite() { |
| // The objects used here are intentionally not freed as we want the Skia |
| // code to use these objects after warmup. |
| + SetDefaultSkiaFactory(GetPreSandboxWarmupFontMgr()); |
| SkTypeface* typeface = |
| GetPreSandboxWarmupFontMgr()->legacyCreateTypeface("Times New Roman", 0); |
| DoPreSandboxWarmupForTypeface(typeface); |
| - SetDefaultSkiaFactory(GetPreSandboxWarmupFontMgr()); |
| + |
| + // The CC HUD needs a debug font, we warm that up here and pass it down. |
| + typeface = GetPreSandboxWarmupFontMgr()->legacyCreateTypeface( |
| + "Consolas", SkTypeface::kBold); |
| + DoPreSandboxWarmupForTypeface(typeface); |
| + ui::SetHudTypeface(skia::AdoptRef(typeface)); |
|
danakj
2015/02/05 23:43:40
Thanks, that looks good. Still curious how doing t
scottmg
2015/02/05 23:47:55
Oh, sorry, you mean at line 65? My brain is slow t
|
| } |
| } // namespace |