Revert "Revert "Update MainActivity.java""

This reverts commit e517b78923556d359efdff12e50ce8295e768f9a.