All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.soywiz.korge.ui.UIPlugin.kt Maven / Gradle / Ivy

There is a newer version: 0.19.2
Show newest version
package com.soywiz.korge.ui

import com.soywiz.korge.plugin.KorgePlugin
import com.soywiz.korge.resources.Path
import com.soywiz.korge.resources.ResourcesRoot
import com.soywiz.korge.resources.VPath
import com.soywiz.korge.resources.getPath
import com.soywiz.korge.view.Views

object UIPlugin : KorgePlugin() {
	suspend override fun register(views: Views) {
		views.injector.mapSingleton { UIFactory() }
		views.injector.mapFactory(UISkin::class) {
			UISkin.Factory(
				getOrNull(Path::class),
				getOrNull(VPath::class),
				get(ResourcesRoot::class),
				get(Views::class)
			)
		}
	}
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy