Connected up UI to a controller class.