Removes some threading calls for JavaFX