Recreating a DialogBox class to separate the work.