added in controller and some gui changes