<@UBZ7B215K> Unfortunately, after trying the propo...
# tornadofx
a
@seiv Unfortunately, after trying the proposed solution, it doesn't work as I need 🤔. Overriding
stop()
method doesn't prevent me from closing the current view, so I used the following solution
Copy code
override fun onDock() {
        super.onDock()
        currentStage?.setOnCloseRequest { event ->
            if (patchStatus.running.value) {
                alert(Alert.AlertType.WARNING, "Wait!", "Still working....")
                event.consume()
            }
        }

    }