Since Android 8.1 (android-8.1.0_r1), android.text.formatter.Formatter.formatFileSize()
starts to use the strings from ICU library to format the file size, which contains many some unnessary Chinese translations. It makes us get file size or storage space in 3.12吉字节
instead of 3.12 GB
in Android 8.1+ with zh-hans.
Picture via @sumimakito: https://twitter.com/sumimakito/status/938689794204246016
This module replaces the icu data file to fix this problem.
从 Android 8.1 (android-8.1.0_r1) 开始, android.text.formatter.Formatter.formatFileSize()
开始使用来自 ICU 库的字符串来格式化文件大小, 这个库包含有一些 不必要的翻译, 这使我们在简体中文的 Android 8.1+ 上看到的文件大小、剩余空间之类的东西是 3.12吉字节
而不是 3.12 GB
.
这个模块更换了 ICU 数据文件来解决这个问题。