Improving the ui controller