package bjpkten.permissionrelateddemo;
import android.Manifest;
import android.content.pm.PackageManager;
import android.os.Bundle;
import android.support.annotation.NonNull;
import android.support.v7.app.AppCompatActivity;
import android.util.Log;
import android.widget.TextView;
import android.widget.Toast;
import java.security.Permission;
public class MainActivity extends AppCompatActivity {
private TextView mTextView;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
// setContentView(R.layout.activity_main);
mTextView = (TextView) findViewById(R.id.text);
}
@Override
protected void onResume() {
super.onResume();
mTextView.setText(R.string.app_name);
}
}
报错:
E/AndroidRuntime: FATAL EXCEPTION: main
Process: bjpkten.permissionrelateddemo, P