My code is here:
public static boolean showConfirmationDialog(Context context, String title, String dialogContent) {
AlertDialog.Builder builder = new AlertDialog.Builder(context);
builder.setIcon(android.R.drawable.ic_dialog_alert);
builder.setTitle(title);
builder.setMessage(dialogContent);
builder.setPositiveButton("Confirm", new OnClickListener() {
@Override
public void onClick(DialogInterface dialog, int which) {
// what to do ?
}
});
right now, I want to return true after I clicked the "confirm" button. so how do I return "true" from a inner class - OnClickListener for the method.
Need some help, thanks.