GMS环境下获取泰文版Google法律信息异常

GMS环境下获取泰文版Google法律信息异常

[DESCRIPTION]

GMS环境下,成功连接WIFI,进入设置 -> 关于手机 -> 法律信息 -> Google法律信息 -> 选择泰文,直接退出Google法律信息界面,返回到法律信息界面(选择其他语言都可以成功show出Google法律信息)。

[SOLUTION]

请修改code,修改部分如下 ( //MTK change start 和 //mtk change end 包含的区间):
File:
external/webkit/Source/WebCore/platform/graphics/android/FontAndroid.cpp
Function: TextRunWalker::TextRunWalker
TextRunWalker::TextRunWalker(const TextRun& run, unsigned startingX, const
Font* font)
: m_font(font)
, m_startingX(startingX)
, m_offsetX(m_startingX)
, m_run(getNormalizedTextRun(run, m_normalizedRun, m_normalizedBuffer))
, m_iterateBackwards(m_run.rtl())
, m_wordSpacingAdjustment(0)
, m_padding(0)
, m_padPerWordBreak(0)
, m_padError(0)
, m_letterSpacing(0)
{
// Do not use |run| inside this constructor. Use |m_run| instead.
memset(&m_item, 0, sizeof(m_item));
// We cannot know, ahead of time, how many glyphs a given script run
// will produce. We take a guess that script runs will not produce more
// than twice as many glyphs as there are code points plus a bit of
// padding and fallback if we find that we are wrong.
createGlyphArrays((m_run.length() + 2) * 2);
//mtk change start
m_item.log_clusters = new unsigned short[(m_run.length() + 2) * 2];
//mtk change end
m_item.face = 0;
m_item.font = allocHarfbuzzFont();
m_item.item.bidiLevel = m_run.rtl();
m_item.string = m_run.characters();
m_item.stringLength = m_run.length();
reset();
}


评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值