Improve the touch event of MainActivity.