提交 cfe69e4e 编写于 作者: A Adam Barth 提交者: GitHub

Catch a missing font provider earlier (#3222)

Rather than hitting an assert in platform-independent code, we now trigger an
assert closer to the relevant code when the font provider is missing.
上级 5118d047
......@@ -119,6 +119,11 @@ sk_sp<SkTypeface> FontCache::createTypeface(
[&response](fonts::FontResponsePtr r) { response = std::move(r); });
font_provider.WaitForIncomingResponse();
FTL_DCHECK(response)
<< "Unable to contact the font provider. Did you run "
"Flutter in an environment that has a font manager?\n"
"See <https://fuchsia.googlesource.com/modular/+/master/README.md>.";
if (!response)
return nullptr;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册