QMessageBox msgBox;
msgBox.setText(tr("包含未确认报警!"));
msgBox.setInformativeText("是否跳过该项?");
QPushButton *skip = msgBox.addButton(tr("跳过"), QMessageBox::ActionRole);
QPushButton *skipAll = msgBox.addButton(tr("全部跳过"), QMessageBox::AcceptRole);
msgBox.addButton(tr("取消"), QMessageBox::RejectRole);
msgBox.setDefaultButton(skip);
msgBox.exec();
if (msgBox.clickedButton() == skip)
{
unConfirmSkip = 0;
continue;
}
else if (msgBox.clickedButton() == skipAll)
{
unConfirmSkip = 1;
continue;
}