Javafx Platform.runLater never running
2022-09-05 00:10:18
						我基本上希望能够在我的LWJGL / GLFW线程启动后(和内部)启动一个新的Javafx窗口(阶段)。我基本上是在做:
Thread thread = new Thread(()->Platform.runLater(()->{
    Stage stage = new Stage();
    //Stage setup
    stage.show();
}));
thread.start();
线程是我的游戏线程。但它从未运行过,我尝试过内部检查它从未运行过。System.out.println()Platform.runLater()
为什么它永远不会运行,我该怎么做才能修复它?谢谢。
编辑:只是为了澄清线程肯定已经开始了,如果我这样做:
Thread thread = new Thread(()->{
    System.out.println("Before Platform.runLater()");
    Platform.runLater(()->System.out.println("Inside Platform.runLater()"));
    System.out.println("After Platform.runLater()");
});
它输出:
Before Platform.runLater()
After Platform.runLater()
 
					 
				 
				    		 
				    		 
				    		 
				    		