net.silkmc.silk.igui.elements.GuiButton.kt Maven / Gradle / Ivy
package net.silkmc.silk.igui.elements
import net.silkmc.silk.igui.GuiIcon
import net.silkmc.silk.igui.events.GuiClickEvent
open class GuiButton(
icon: GuiIcon,
private val onClick: suspend (GuiClickEvent) -> Unit,
) : GuiPlaceholder(icon) {
override suspend fun onClick(clickEvent: GuiClickEvent) {
onClick.invoke(clickEvent)
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy