aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/main/kotlin/pl/treksoft/kvision/html/Button.kt13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/main/kotlin/pl/treksoft/kvision/html/Button.kt b/src/main/kotlin/pl/treksoft/kvision/html/Button.kt
index ec1d95f5..44a9a8f3 100644
--- a/src/main/kotlin/pl/treksoft/kvision/html/Button.kt
+++ b/src/main/kotlin/pl/treksoft/kvision/html/Button.kt
@@ -155,6 +155,19 @@ open class Button(
}
return this
}
+ /**
+ * Makes the button focused.
+ */
+ open fun focus() {
+ getElementJQuery()?.focus()
+ }
+
+ /**
+ * Makes the button blur.
+ */
+ open fun blur() {
+ getElementJQuery()?.blur()
+ }
}
/**