我需要使用intent启动内置活动(例如,选择APP访问权限),并在其主屏幕显示对话框中引导用户选中复选框。 我按照
的方式实现了它 protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
dialog1 = new Dialog(MainActivity.this,android.R.style.Theme);
dialog1.requestWindowFeature(Window.FEATURE_NO_TITLE);
dialog1.setContentView(R.layout.popup_window);
dialog1.getWindow().setBackgroundDrawable(new ColorDrawable(0x80827871));
dialog1.show();
Intent intent1 = new Intent("android.settings.ACTION_name");
startActivity(intent1);
但是,对话框会在后台进行。 在此先感谢!!