Move view logic into View.cpp