这是代码,我正在添加AlertDialog并在关闭时调用它
new AlertDialog.Builder(this)
.setTitle("Exit")
.setView(mview)
.setMessage("Do you really want to exit?")
.setNegativeButton("No",null)
.setPositiveButton("Yes", new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialogInterface, int i) {
finish();
}
}).show();
当我第二次点回时,应用程序崩溃