mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-04-21 17:29:32 +01:00
committed by
Greyson Parrelli
parent
be92b3cf0a
commit
cafbf48783
@@ -25,7 +25,7 @@ object TextToScript {
|
||||
)
|
||||
|
||||
fun guessScript(text: CharSequence): SupportedScript {
|
||||
val scriptCounts: MutableMap<SupportedScript, Int> = SupportedScript.values().associate { it to 0 }.toMutableMap()
|
||||
val scriptCounts: MutableMap<SupportedScript, Int> = SupportedScript.entries.associate { it to 0 }.toMutableMap()
|
||||
val input = text.toString()
|
||||
|
||||
for (i in 0 until input.codePointCount(0, input.length)) {
|
||||
|
||||
@@ -21,7 +21,7 @@ object TypefaceCache {
|
||||
*/
|
||||
fun warm(context: Context, script: SupportedScript) {
|
||||
val appContext = context.applicationContext
|
||||
TextFont.values().forEach {
|
||||
TextFont.entries.forEach {
|
||||
get(appContext, it, script).subscribe()
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user