aboutsummaryrefslogtreecommitdiff
path: root/src/main/kotlin/pl/treksoft/kvision
diff options
context:
space:
mode:
authorRobert Jaros <rjaros@finn.pl>2018-05-25 13:37:36 +0200
committerRobert Jaros <rjaros@finn.pl>2018-05-25 13:37:36 +0200
commitf1bb9fa4fca9b49c861b0828a8ba2360417777de (patch)
treee34d11d158a9c332f774f156a8e3777a6ad60014 /src/main/kotlin/pl/treksoft/kvision
parent21331642176b8ab1ddafba254edeca8ed9ad50aa (diff)
downloadkvision-f1bb9fa4fca9b49c861b0828a8ba2360417777de.tar.gz
kvision-f1bb9fa4fca9b49c861b0828a8ba2360417777de.tar.bz2
kvision-f1bb9fa4fca9b49c861b0828a8ba2360417777de.zip
Small fixes.
Diffstat (limited to 'src/main/kotlin/pl/treksoft/kvision')
-rw-r--r--src/main/kotlin/pl/treksoft/kvision/panel/Root.kt5
-rw-r--r--src/main/kotlin/pl/treksoft/kvision/panel/SplitPanel.kt2
2 files changed, 6 insertions, 1 deletions
diff --git a/src/main/kotlin/pl/treksoft/kvision/panel/Root.kt b/src/main/kotlin/pl/treksoft/kvision/panel/Root.kt
index 7ab68fdd..667559b7 100644
--- a/src/main/kotlin/pl/treksoft/kvision/panel/Root.kt
+++ b/src/main/kotlin/pl/treksoft/kvision/panel/Root.kt
@@ -110,6 +110,11 @@ class Root(id: String, private val fixed: Boolean = false, init: (Root.() -> Uni
return this
}
+ override fun dispose() {
+ super.dispose()
+ roots.remove(this)
+ }
+
companion object {
private val roots: MutableList<Root> = mutableListOf()
diff --git a/src/main/kotlin/pl/treksoft/kvision/panel/SplitPanel.kt b/src/main/kotlin/pl/treksoft/kvision/panel/SplitPanel.kt
index 5ac9c6e7..f3625e97 100644
--- a/src/main/kotlin/pl/treksoft/kvision/panel/SplitPanel.kt
+++ b/src/main/kotlin/pl/treksoft/kvision/panel/SplitPanel.kt
@@ -69,7 +69,7 @@ open class SplitPanel(
val horizontal = direction == Direction.HORIZONTAL
val px = UNIT.px
val self = this
- children[0].getElementJQueryD().resizable(obj {
+ children[0].getElementJQueryD()?.resizable(obj {
handleSelector = "#" + splitter.id
resizeWidth = !horizontal
resizeHeight = horizontal