Updating dimensions on javafx, edited by Hank