aboutsummaryrefslogtreecommitdiff
path: root/src/main/kotlin/pl/treksoft/kvision/html
diff options
context:
space:
mode:
authorRobert Jaros <rjaros@finn.pl>2017-11-03 15:15:32 +0100
committerRobert Jaros <rjaros@finn.pl>2017-11-03 15:15:32 +0100
commitd4d9ea0afaf76778f3bb588e501749867053ca5f (patch)
treef56fb614778ca074393bb5647244ba35be388dc9 /src/main/kotlin/pl/treksoft/kvision/html
parent0bc8ff5a2d4b63d184d4289351d93195d8ef66bd (diff)
downloadkvision-d4d9ea0afaf76778f3bb588e501749867053ca5f.tar.gz
kvision-d4d9ea0afaf76778f3bb588e501749867053ca5f.tar.bz2
kvision-d4d9ea0afaf76778f3bb588e501749867053ca5f.zip
Refactoring - simplified constructors
Diffstat (limited to 'src/main/kotlin/pl/treksoft/kvision/html')
-rw-r--r--src/main/kotlin/pl/treksoft/kvision/html/Button.kt6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/main/kotlin/pl/treksoft/kvision/html/Button.kt b/src/main/kotlin/pl/treksoft/kvision/html/Button.kt
index f0cb91f7..d14ce66e 100644
--- a/src/main/kotlin/pl/treksoft/kvision/html/Button.kt
+++ b/src/main/kotlin/pl/treksoft/kvision/html/Button.kt
@@ -23,8 +23,7 @@ enum class BUTTONSIZE(val className: String) {
}
open class Button(text: String, icon: String? = null, style: BUTTONSTYLE = BUTTONSTYLE.DEFAULT,
- disabled: Boolean = false, image: ResString? = null,
- classes: Set<String> = setOf()) : Widget(classes) {
+ disabled: Boolean = false, classes: Set<String> = setOf()) : Widget(classes) {
var text = text
set(value) {
field = value
@@ -45,12 +44,11 @@ open class Button(text: String, icon: String? = null, style: BUTTONSTYLE = BUTTO
field = value
refresh()
}
- var image = image
+ var image: ResString? = null
set(value) {
field = value
refresh()
}
-
var size: BUTTONSIZE? = null
set(value) {
field = value