package ru.dbotthepony.mc.otm.client.screen.panels.button

import net.minecraft.client.gui.screens.Screen
import ru.dbotthepony.mc.otm.client.render.*
import ru.dbotthepony.mc.otm.client.screen.panels.EditablePanel
import ru.dbotthepony.mc.otm.core.GetterSetter

open class SmallBooleanRectangleButtonPanel<out S : Screen>(
	screen: S,
	parent: EditablePanel<*>?,
	x: Float = 0f,
	y: Float = 0f,
	width: Float = SIZE,
	height: Float = SIZE,
	prop: GetterSetter<Boolean>,
	skinElementActive: AbstractMatterySprite? = null,
	skinElementInactive: AbstractMatterySprite? = null,
	onChange: ((newValue: Boolean) -> Unit)? = null,
) : BooleanRectangleButtonPanel<S>(screen, parent, x, y, width, height, prop, skinElementActive, skinElementInactive, onChange) {
	final override val IDLE = Widgets8.BUTTON_IDLE
	final override val HOVERED = Widgets8.BUTTON_HOVERED
	final override val PRESSED = Widgets8.BUTTON_PRESSED
	final override val DISABLED = Widgets8.BUTTON_DISABLED

	companion object {
		const val SIZE = 8f
	}
}
