Jan*_*man 5 fonts android emoji google-fonts huawei-mobile-services
I would like to support emojis for Huawei devices in my app. For all other vendors I use code like this to init EmojiCompat:
val fontRequest = FontRequest(
"com.google.android.gms.fonts",
"com.google.android.gms",
"Noto Color Emoji Compat",
R.array.com_google_android_gms_fonts_certs
)
val config = FontRequestEmojiCompatConfig(context, fontRequest)
EmojiCompat.init(config)
Run Code Online (Sandbox Code Playgroud)
But for Huawei devices, for they do not have access to google resources (my guess), it does not work, and EmojiCompat doesn't get initialized. I know that BundledEmojiCompatConfig could be used, but I would prefer always to fetch the newest font.
Is there any alternative to Google's providerAuthority/Package for Huawei devices?
EmojiCompat 是 Android 的一部分,并非 Google 移动服务独有。我测试了下面的演示应用程序,它具有与您相同的代码片段,并且它在我的华为 Mate 30 Pro 上运行良好。
| 归档时间: |
|
| 查看次数: |
749 次 |
| 最近记录: |