Open EfremovAV opened 5 years ago
You can create a custom layout and attach it to the dialog by using setFooterView
Hope it helps
LayoutInflater inflater = this.getLayoutInflater();
final View footer = inflater.inflate(R.layout.dialog_alert_footer_layout, null);
footer.findViewById(R.id.yesButton).setOnClickListener(v -> {
//
});
footer.findViewById(R.id.noButton).setOnClickListener(v -> {
//
});
CFAlertDialog.Builder builder = new CFAlertDialog.Builder(this)
.setDialogStyle(CFAlertDialog.CFAlertStyle.ALERT)
.setTitle(title)
.setMessage(message)
.setCancelable(false)
.setTextGravity(Gravity.CENTER_HORIZONTAL)
.setHeaderView(header)
.setFooterView(footer)
I can't place several buttons in one row. How can I do that?