mirror of
https://gitlab.bixilon.de/bixilon/minosoft.git
synced 2025-09-16 10:55:01 -04:00
build font cache on init (not post init)
This should prevent hud from already using it
This commit is contained in:
parent
81ff9c9f7a
commit
53cab94924
@ -26,6 +26,10 @@ class Font(
|
||||
) : PostInitFontType {
|
||||
private val cache: Array<CodePointRenderer?> = arrayOfNulls(CACHE_SIZE)
|
||||
|
||||
init {
|
||||
buildCache()
|
||||
}
|
||||
|
||||
|
||||
private fun postInitFonts(latch: AbstractLatch) {
|
||||
val fontLatch = ParentLatch(1, latch)
|
||||
@ -49,7 +53,6 @@ class Font(
|
||||
|
||||
override fun postInit(latch: AbstractLatch) {
|
||||
postInitFonts(latch)
|
||||
buildCache()
|
||||
}
|
||||
|
||||
fun forceGet(codePoint: Int): CodePointRenderer? {
|
||||
|
Loading…
x
Reference in New Issue
Block a user