diff options
Diffstat (limited to 'Source/Core/DolphinQt/Main.cpp')
| -rw-r--r-- | Source/Core/DolphinQt/Main.cpp | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/Source/Core/DolphinQt/Main.cpp b/Source/Core/DolphinQt/Main.cpp index 038fed9c89..ee30defcf7 100644 --- a/Source/Core/DolphinQt/Main.cpp +++ b/Source/Core/DolphinQt/Main.cpp @@ -35,7 +35,8 @@ #include "UICommon/CommandLineParse.h" #include "UICommon/UICommon.h" -static bool QtMsgAlertHandler(const char* caption, const char* text, bool yes_no, MsgType style) +static bool QtMsgAlertHandler(const char* caption, const char* text, bool yes_no, + Common::MsgType style) { std::optional<bool> r = RunOnObject(QApplication::instance(), [&] { ModalMessageBox message_box(QApplication::activeWindow()); @@ -43,19 +44,19 @@ static bool QtMsgAlertHandler(const char* caption, const char* text, bool yes_no message_box.setText(QString::fromUtf8(text)); message_box.setStandardButtons(yes_no ? QMessageBox::Yes | QMessageBox::No : QMessageBox::Ok); - if (style == MsgType::Warning) + if (style == Common::MsgType::Warning) message_box.addButton(QMessageBox::Ignore)->setText(QObject::tr("Ignore for this session")); message_box.setIcon([&] { switch (style) { - case MsgType::Information: + case Common::MsgType::Information: return QMessageBox::Information; - case MsgType::Question: + case Common::MsgType::Question: return QMessageBox::Question; - case MsgType::Warning: + case Common::MsgType::Warning: return QMessageBox::Warning; - case MsgType::Critical: + case Common::MsgType::Critical: return QMessageBox::Critical; } // appease MSVC @@ -67,7 +68,7 @@ static bool QtMsgAlertHandler(const char* caption, const char* text, bool yes_no return true; if (button == QMessageBox::Ignore) - SetEnableAlert(false); + Common::SetEnableAlert(false); return false; }); @@ -137,7 +138,7 @@ int main(int argc, char* argv[]) Settings::Instance().SetBatchModeEnabled(options.is_set("batch")); // Hook up alerts from core - RegisterMsgAlertHandler(QtMsgAlertHandler); + Common::RegisterMsgAlertHandler(QtMsgAlertHandler); // Hook up translations Translation::Initialize(); |
