Closed #4 - Move view code to view layer