Commit bfb91472 authored by Kimmo Kinnunen's avatar Kimmo Kinnunen Committed by Commit Bot

Make font_warmup_win.cc link with enable_plugins=false

Make font_warmup_win.cc link with enable_plugins=false.
Fixes content_shell build with enable_plugins=false.

Bug: 807901
Change-Id: Ied8af485013629407720148946d94353b5da1dcd
Reviewed-on: https://chromium-review.googlesource.com/897482Reviewed-by: default avatarKentaro Hara <haraken@chromium.org>
Commit-Queue: Kimmo Kinnunen FI <kkinnunen@nvidia.com>
Cr-Commit-Position: refs/heads/master@{#533620}
parent a5172f79
......@@ -22,12 +22,17 @@
#include "base/trace_event/trace_event.h"
#include "base/win/iat_patch_function.h"
#include "base/win/windows_version.h"
#include "ppapi/shared_impl/proxy_lock.h"
#include "build/build_config.h"
#include "ppapi/features/features.h"
#include "skia/ext/fontmgr_default_win.h"
#include "third_party/skia/include/core/SkRefCnt.h"
#include "third_party/skia/include/ports/SkFontMgr.h"
#include "third_party/skia/include/ports/SkTypeface_win.h"
#if BUILDFLAG(ENABLE_PLUGINS)
#include "ppapi/shared_impl/proxy_lock.h"
#endif // BUILDFLAG(ENABLE_PLUGINS)
namespace content {
namespace {
......@@ -205,7 +210,9 @@ sk_sp<SkTypeface> GetTypefaceFromLOGFONT(const LOGFONTW* log_font) {
: SkFontStyle::kUpright_Slant);
std::string family_name = base::WideToUTF8(log_font->lfFaceName);
#if BUILDFLAG(ENABLE_PLUGINS)
ppapi::ProxyAutoLock lock; // Needed for DirectWrite font proxy.
#endif // BUILDFLAG(ENABLE_PLUGINS)
return sk_sp<SkTypeface>(
g_warmup_fontmgr->matchFamilyStyle(family_name.c_str(), style));
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment