diff options
author | Jan Dalheimer <jan@dalheimer.de> | 2014-01-03 21:05:03 +0100 |
---|---|---|
committer | Jan Dalheimer <jan@dalheimer.de> | 2014-01-03 21:05:03 +0100 |
commit | df1186e0212efc99fb0125380f2da0a3ac85fe5a (patch) | |
tree | a95b6609affe5513de68002f7a5e88a248879a1a /gui/MainWindow.cpp | |
parent | 71e1410b9fd785b62ece869f3d5448c14fdcba83 (diff) | |
download | MultiMC-df1186e0212efc99fb0125380f2da0a3ac85fe5a.tar MultiMC-df1186e0212efc99fb0125380f2da0a3ac85fe5a.tar.gz MultiMC-df1186e0212efc99fb0125380f2da0a3ac85fe5a.tar.lz MultiMC-df1186e0212efc99fb0125380f2da0a3ac85fe5a.tar.xz MultiMC-df1186e0212efc99fb0125380f2da0a3ac85fe5a.zip |
Add the option to disable a certain message
Diffstat (limited to 'gui/MainWindow.cpp')
-rw-r--r-- | gui/MainWindow.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/gui/MainWindow.cpp b/gui/MainWindow.cpp index cf34a46b..826cbc04 100644 --- a/gui/MainWindow.cpp +++ b/gui/MainWindow.cpp @@ -543,9 +543,13 @@ void MainWindow::notificationsChanged() break; } - QMessageBox box(icon, tr("Notification"), entry.message, QMessageBox::Ok, this); + QMessageBox box(icon, tr("Notification"), entry.message, QMessageBox::Close, this); + QPushButton *dontShowAgainButton = box.addButton(tr("Don't show again"), QMessageBox::AcceptRole); box.exec(); - shownNotifications.append(entry.id); + if (box.clickedButton() == dontShowAgainButton) + { + shownNotifications.append(entry.id); + } } } MMC->settings()->set("ShownNotifications", intListToString(shownNotifications)); |