change MainActivity to ViewActivity