Some changes in MainActivity.java