Skip to content
This repository has been archived by the owner on Sep 28, 2024. It is now read-only.

Application doesn't stop after clicking exit button when view was replaced #1033

Open
bareq opened this issue Jul 23, 2019 · 1 comment
Open

Comments

@bareq
Copy link

bareq commented Jul 23, 2019

TornadoFX 1.17.19
When I use replaceWith() method on my main view to change current displayed window and a new window is closed by hitting close button then it disappear but application is still running and an exception is thrown

java.lang.RuntimeException: Exception in Application stop method
	at com.sun.javafx.application.LauncherImpl.launchApplication1(LauncherImpl.java:922)
	at com.sun.javafx.application.LauncherImpl.lambda$launchApplication$154(LauncherImpl.java:182)
	at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.IllegalStateException: root.scene must not be null
	at tornadofx.UIComponent.unInit(Component.kt:575)
	at tornadofx.App.stop(App.kt:140)
	at com.sun.javafx.application.LauncherImpl.lambda$launchApplication1$162(LauncherImpl.java:882)
	at com.sun.javafx.application.PlatformImpl.lambda$runAndWait$174(PlatformImpl.java:326)
	at com.sun.javafx.application.PlatformImpl.lambda$null$172(PlatformImpl.java:295)
	at java.security.AccessController.doPrivileged(Native Method)
	at com.sun.javafx.application.PlatformImpl.lambda$runLater$173(PlatformImpl.java:294)
	at com.sun.glass.ui.InvokeLaterDispatcher$Future.run(InvokeLaterDispatcher.java:95)

It happens even in login app from samples when you upgrade TornadoFX dependency to 1.17.19 (default 1.17.16). If it changes something, I'm on Mac OS 10.14.5

@monarezio
Copy link

I can confirm this error is valid also for windows

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants