diff options
Diffstat (limited to 'src/main/kotlin/pl/treksoft/kvision')
-rw-r--r-- | src/main/kotlin/pl/treksoft/kvision/KVManager.kt | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/main/kotlin/pl/treksoft/kvision/KVManager.kt b/src/main/kotlin/pl/treksoft/kvision/KVManager.kt index d3001b1d..4ab7c1d0 100644 --- a/src/main/kotlin/pl/treksoft/kvision/KVManager.kt +++ b/src/main/kotlin/pl/treksoft/kvision/KVManager.kt @@ -143,8 +143,10 @@ internal object KVManager { @Suppress("UnsafeCastFromDynamic") internal fun clearResizeEvent(component: Component) { - component.getElement()?.let { - elementResizeEvent.unbind(it) + if (component.getElement().asDynamic().__resizeTrigger__.contentDocument != null) { + component.getElement()?.let { + elementResizeEvent.unbind(it) + } } } } |