Skip to content
Snippets Groups Projects
Commit a4760b71 authored by Oswald Buddenhagen's avatar Oswald Buddenhagen
Browse files

centralize message box handling in adapters

parent 30745d04
No related branches found
No related tags found
No related merge requests found
......@@ -99,6 +99,8 @@ protected:
{ m_engine->debugMessage(msg); }
void showStatusMessage(const QString &msg) const
{ m_engine->showStatusMessage(msg); }
void showMessageBox(int icon, const QString &title, const QString &text) const
{ m_engine->showMessageBox(icon, title, text); }
GdbEngine * const m_engine;
};
......
......@@ -119,7 +119,7 @@ void RemoteGdbAdapter::uploadProcError(QProcess::ProcessError error)
}
m_engine->showStatusMessage(msg);
QMessageBox::critical(m_engine->mainWindow(), tr("Error"), msg);
showMessageBox(QMessageBox::Critical, tr("Error"), msg);
}
void RemoteGdbAdapter::readUploadStandardOutput()
......
......@@ -147,7 +147,7 @@ void TermGdbAdapter::shutdown()
void TermGdbAdapter::stubError(const QString &msg)
{
QMessageBox::critical(m_engine->mainWindow(), tr("Debugger Error"), msg);
showMessageBox(QMessageBox::Critical, tr("Debugger Error"), msg);
}
void TermGdbAdapter::stubExited()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment