Added comments to the MainActivity methods.