I have the following slot:
void MainWindow::showCriticalMessage(const QString& title, const QString& message)
{
QMessageBox msgBox(this);
msgBox.setIcon(QMessageBox::Critical);
msgBox.setText(title);
msgBox.setInformativeText(message);
msgBox.setStandardButtons(QMessageBox::Ok);
msgBox.setDefaultButton(QMessageBox::Ok);
msgBox.exec();
}
Will this be a potential problem if this slot is triggered multiple times before the user close the last pop out message box? Since I see many people say, use .show() instead of .exec().