Class UI
java.lang.Object
megalodonte.base.UI
Helper for running code on the JavaFX Application Thread.
Wraps
Platform.runLater(Runnable) for use from virtual threads or background work.-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
UI
public UI()
-
-
Method Details
-
runOnUi
Executestaskon the JavaFX Application Thread. If already on the FX thread, runs immediately; otherwise schedules it.- Parameters:
task- the runnable to execute on the FX thread
-