InputButton fix

This commit is contained in:
Milos Kozak 2022-05-19 12:55:40 +02:00
parent 73fa9f5814
commit 0835a487c0

View file

@ -16,10 +16,10 @@ class InputButton() : Element() {
override fun addToLayout(root: LinearLayout) { override fun addToLayout(root: LinearLayout) {
root.addView( root.addView(
Button(root.context).apply { Button(root.context).also {
text = text it.text = text
setOnClickListener { runnable?.run() } it.setOnClickListener { runnable?.run() }
gravity = Gravity.CENTER_HORIZONTAL it.gravity = Gravity.CENTER_HORIZONTAL
}) })
} }
} }